load a 3D land from a bitmap

Started by
6 comments, last by LilBudyWizer 19 years, 5 months ago
i want to make a program that loads a 3D land (made of triangles) from a bitmap (a geographical map). please help me with some links or ideas!!!
Advertisement
Start here:
http://nehe.gamedev.net/data/lessons/lesson.asp?lesson=34

:)
where to begin?

doing a search for 'brute force heightmap terrain' will probably yield something usefull.
You probably want to look into loading a height map. I believe there's a tutorial at http://nehe.gamedev.net/data/lessons/lesson.asp?lesson=34 if you're using OpenGL. There's also a good tutorial at http://gametutorials.com.

You'll essentially be determining the height of each point by looking at the intensity of each pixel. Both of these tutorials describe how to load a RAW file and then create a height map from it. If you mean by bitmap, a Windows '.bmp' file, then it's simple enough to write a function that extracts the data from a Windows '.bmp' file.
Hey newbie,
the terminology you want is
terrain generation from height maps
that typed into google returned the following:
http://home.planet.nl/~monstrous/terrain.html
its got some good openGL code. Reading from a bitmap is your problem, but DevIL (http://openil.sourceforge.net/) is pretty good.

double.
10x a lot u all!!!
anywayz... i was wondering if i could apply any other algorithm to identify the "hot spots" on the map (those points from the center of a same coloured area) and then use triangulation algorithms (like delaunay or stuff) that generate less triangles and might render faster and smoother... i think...
please help me again!!!!!!!
Well, first would be culling. Rather than sending the entire grid through the rendering pipeline you eliminate some part of it that just isn't possibly visible. Examples are things behind the camera or simply too far away. Then there are level of detail (LOD) methods that say when you are standing on a mountaintop looking at the valley below you don't need as much detail to the valley as you do when you are standing in the valley looking up at the mountain. Generally you use culling to first get it down to something responsive. Then you use LOD to extend the view distance.
Keys to success: Ability, ambition and opportunity.

This topic is closed to new replies.

Advertisement