Page 1 of 2 12 LastLast
Results 1 to 10 of 32

Thread: Planet texture generation code

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Junior Member
    Join Date
    Mar 2012
    Location
    London, UK
    Posts
    27
    You mention heightmaps, from which I gather it's not a planetary view? So am I correct in assuming that you are actually generating a terrain map rather than a planet map? Something for close up view where you only ever see a very small portion of the terrain at any given time?

  2. #2
    My wish is to have both, but for the moment I concentrate more on planetary view.
    Also after doing some research I see that perlin noise can come in handy in other fields aswell, even for things that I wasn't even planing before.

  3. #3
    Junior Member
    Join Date
    Mar 2012
    Location
    London, UK
    Posts
    27
    Quote Originally Posted by SilverWarior View Post
    for the moment I concentrate more on planetary view.
    http://mygimptutorial.com/the-ultima...lanet-tutorial

    That works pretty good for a spite type view. If you're looking for a cylindrical projection to wrap around a sphere, maybe try Gimp and the phfluuh plugin. But I haven't tried that myself yet.

  4. #4
    Lets me get something clear. I wan't to have planet texture generation capability inside my game so that I can generate necessary texture when I need them. For instance before entering star system for the first time. This is posible becouse traveling from one star system to another do takes some time.
    I did manage do make my own implementation of Perlin noise but unfortunatly my implementation is too slow. So if anybody of you guys have decent Perlin noise code I would apretiate if you could share it.

  5. #5
    Good news I found a bug in my code wich was making it runs so damn slow. So now my implementation of perlin noise like algorithm works with decent speed.
    But since I now use Delphi random function it only generates me real numbers between 0 and 1 while original Perlin Noise algorithm uses real numbers from -1 to 1.
    So I was wondering if anybody of you have code for random number generator wich is capable of generating random numbers between -1 and 1.

  6. #6
    Junior Member
    Join Date
    Mar 2012
    Location
    London, UK
    Posts
    27
    Quote Originally Posted by SilverWarior View Post
    capable of generating random numbers between -1 and 1.
    r := random(2) - 1

  7. #7

  8. #8
    Junior Member
    Join Date
    Oct 2012
    Location
    Columbus, Ohio
    Posts
    4
    Blog Entries
    3

    Clarification for SilverWarior

    Hello,
    I do beg every body's forgiveness as I struggle to understand the dynamics of programming and how best to express my vision and goals.
    To start, a game that I enjoy playing is a 2D game of course played on a square surface. If you start at point a and move in a straight line to the right when you come to the edge you can go no further. Now in my mind you should be repositioned to the the left side and be able to continue on your path.
    It is my impression that the only why to accomplish this goal is to have a spherical game space...of course I could be wrong.
    As a beginning base for my project I would prefer this MyWorld.jpgas a game space. With the ability to zoom into street level yet not have the streets or buildings one would find in say google maps. Natural Earth does have the appropriate dataset although there would need to be some work done as when their maps are zoomed in they get blurry. But, I am sure there is a height map, shapefile that can resolve that issue.
    Then there is the issue of the actual ...algorithm... to create the proper paths such as something like these.MyWorldBasicTravelLines.jpg

    Now, not being a programmer much less a game programmer, I can image that there is some process to achieve this goal. But, I am not yet knowledgeable enough to understand it.

    I, in my project am attempting to fly from space, land, drive in a vehicle until I come to the ocean, then board a ship etc. etc.
    Once I figure out the 3D terrain then I hope I can then combine it with other open source code snippets to finish the project...easier said then done.

    So, I guess the real question is. Does a terrain engine or a game engine allow for this type of path following? Will I need a PhD in mathematics to program the behavior or has some wizard already figured it out? If there is an engine that will allow embedding satellite imaging to create a natural earth terrain could some one suggest it to me?

    As always all advice an d admonishments are appreciated.
    Bill

  9. #9
    Junior Member
    Join Date
    Oct 2012
    Location
    Columbus, Ohio
    Posts
    4
    Blog Entries
    3
    SilverWarior,
    I am attempting the impossible.
    Part of my plan is to start with a planet as the game area as opposed to a square. I have been looking for a google earth, earth 3d, ossimplanet equivalent for Pascal but have not found anything...until I found this post.
    I would be very interested in learning about your progress.
    Thanks in advance,
    Bill

  10. #10
    whtemple1959 welcome to PGD first.
    Unfortunately I haven't done much progress so far. As you might nit know this was part of myGame project with whic I intended to ener 2nd PGD mini competition. But since there was a time limit I had to abandon further development on this part and try to finish rest of the game. Unfortunately I was unsecsessful as the time ran out before I managed to create games GUI (spent more time on this mater than I planed).
    Even after the 2nd PGD mini competition was over I had not resumet work on this becouse I got idea of making a library which would alow me to easily make GUI for any of my future games.
    I must also admit that I haven't done much programing in the last mont or so. I0m having problem getting myself to do any work.

    My original goal was to use perling noise function to generate heightmap texture, use some postprocessing on this texture for finetuning and then finaly use the heightmap to generate planets surface texture. I didn't have intention to make actuall planet model but only to make texture which I could render on a sphere so that it will look atleas a bit similar to planet.
    Sure I could apply heightmap to the sphere to actually gain elevated terrain but this was deffinitly out of my reach for a project which needed to be done in a month time.

    You are saying that you intent to use sphere for game map instead of square map. What dimensions do you intent to use? If you want lots of percision you have to realize that this will require lots of space for textures.
    For instance Google Earth suposingly uses more than 150 TB of data for storing all the surface images.
    http://www.gearthblog.com/blog/archi...up_google.html

    Now if you want quickest answer about how to implement planetary map in your game I recomend you to get in contact with Sascha Willems the author of game named Projekt Weltherrscher.
    http://www.pascalgamedevelopment.com...t-Phase-2-quot
    He is using planetary map in his own game and I'm sure he will be glad to help you out. I only think that he has no algoriithm for radom map generation but I might be wrong (havent tried latest version of his game).

Page 1 of 2 12 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •