Dark Bit Factory & Gravity
PROGRAMMING => Freebasic => Topic started by: Voltage on June 03, 2008
-
Some code that:
1) Rotates the camera
2) Extracts the view frustum planes from OpenGL
3) Loops through all objects (30 000)
4) Compares the objects bounding sphere to the frustum
5) Draws if possibly inside the view
The OpenGL window setup code is by rbraz (what a guy), thank you.
The frustum clipping is all explained http://www.crownandcutlass.com/features/technicaldetails/frustum.html.
The next steps on my list are:
1) Delta timing
2) FPS counter
3) Quadtree
4) Skydome
My goal for this engine is to be able to walk around a large world, with terrain with many objects.
-
Looking very cool, welldone dude :)
-
Indeed. Looking good! Good job!
-
Thats looking ace, Voltage :) Trees are a good choice to test this type of function.
-
Works fine and smootly here, welldone dude
-
very cool work voltage!
jim showed me how to do something like this before although i think we might have done it slightly diffrently http://dbfinteractive.com/index.php?PHPSESSID=17e57cb43b381ce0609ce8db11881ba0&topic=1690.0 (http://dbfinteractive.com/index.php?PHPSESSID=17e57cb43b381ce0609ce8db11881ba0&topic=1690.0)
what would be really cool would be to have a lib with these techniques that folks could just plug into there project.
-
Did I? Crikey, you're right!
The article Voltage linked to is much clearer, but it wastes a bit of effort in the sums. Get it working first though :)
Jim