Archived

This topic is now archived and is closed to further replies.

Filami

Frustun Culling

Recommended Posts

Hey ppl, This is my fist post on this forum... Well, my question is, how can I make a fruston culling in Delphi4...I''m trying to make my own but it does''nt work as I want.... If some one say me a tutorial that ports to delphi I apreciate Thanks in advance.... Filami Techno Grooves

Share this post


Link to post
Share on other sites
GameTutorials has a frustum culling program in C++, which I've converted to Delphi. Grab it over here (120K).

You need the DirectX headers (not included) as I'm using DirectInput 8 for handling the keyboard and mouse. You can get the headers from http://www.crazyentertainment.net/ (the site's down at the mo, but it should be back up soon), assuming you don't have them already.

I may have stripped out some of the comments in the process of converting, so it might be an idea to check the original C++ code if you want more comments (not sure, though). Also, caveat emptor: the conversion was done quickly so there may be a bug or two lurking about.

Hit the 'f' key to see the effect that frustum culling has (which can be big). You can move around with wasd and the mouse.

EDIT: The two files you're interested in are "frustum.pas" and "PlayingGameState.pas", btw . The rest is just a quick framework. Also, note that you'll need to extract the files before running - the code wants to load a .raw texture (which is not used and is just totally black) because I didn't remember to change the texture manager code. Doh!

[edited by - Alimonster on August 31, 2002 9:41:53 PM]

Share this post


Link to post
Share on other sites
Thank you a lot Alimonster....

It was that what I''ve wanted to do, to convert that tutorial to delphi4 but I failed!!! That was a completely mess and the fruston doesn''r work....Thats why I came her to know how I could do that....This way, I will now look to what I miss!!

Thanks!!

About that tutorial penetrator, it seems to be a good reading!! thank to you too...

Filami

Techno Grooves

Share this post


Link to post
Share on other sites
Sorry to bother you, but it might be worth your while downloading the zip again. I''ve added more comments to the functions so that the rest of the stuff makes a little more sense .

Share this post


Link to post
Share on other sites