Delphi and Kylix

Moderators: pritaeas
Number of threads: 7244
Number of posts: 19051

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
Terrain Rendering For Flight Simualtion Posted by delphiqueries on 27 Dec 2005 at 4:04 AM
Hi all,

Kindly help Me to implement ROAM algorithm for Rendering Terrain in Delphi/OpenGL.

Please Let me Know if there are any Good Sites for Getting information regarding Same.

your help is very much appericiated,Thanks in Advance,

Regards

Santosh.



Report
Re: Terrain Rendering For Flight Simualtion Posted by jobromedia on 1 Jan 2006 at 5:56 PM
: Hi all,
:
: Kindly help Me to implement ROAM algorithm for Rendering Terrain in Delphi/OpenGL.
:
: Please Let me Know if there are any Good Sites for Getting information regarding Same.
:
: your help is very much appericiated,Thanks in Advance,
:
: Regards
:
: Santosh.
:
Hmmm...

I dunno a shit on how one could render graphics for a flightsim, but let me elaborate on how one can create the terrain.

One way that you can create a landscape is basically by having a grid of say 16 x 16 floats where each float value indicates the altitude below and over the sea level where 0 is the lowest sea ground and 1 is as high as heaven. Say that you have the sea level at 0.25 then each point above it is equivalent to land.

Now to continue you gotta specify how wide in pixels the grid is, say that you specify 1024 x 1024 as the amount of pixels per gridsquare then you have 16384 x 16384 pixels. Now all you need to do is to draw a picmap of the area you want to render and apply as a texture on top of it.

Next; calculate the heights for each pixel in the grid. Either this can be done by leting pixel 0,0 determin the hight of all pixels wich gives a bulky look, or smoothly calculate each pixel from 0,0, to 1023,1023. Then you have to do the same proess for all the squares in the grid wich will take some time to do, but the end result will look quite good.

Don't ask for any code on how to do this, just me elaborating a bit on how the engine could be constructed. And if you follow my advices then please add in the credits:

Terrain render mechanism
suggested by JoBro Media.

Good luck with your project!



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.