Sign in to follow this  
giugio

scene graph and prestation

Recommended Posts

Hy. I use dx 10 and i have a scene graph in my demo , the scene graph of node is traversed and the node have a indexbuffer and a vertexbuffer. In my scene i have a lot of models of the same type and also other geometry(terrain , homes ecc..) I'm think to use a bsp for sorting the scenegraph for have the same models at the top of the scene(a group of my principal models) 1)this is usefull for cache and stream out? 2)I'm not' fully understand the stream out. 3)the process of bind a vertex or index buffer is greedy of resources or is a light process? Thanks

Share this post


Link to post
Share on other sites
This is a concept of a dynamic scene manager:
there is a traversal tree of objects that keeps an information enough to state wheather object is positioned in player assigned scene volume (you just need AABS world position and AABS world radius) . This tree is traversed and if the node is in reach and if it is not loaded in the scene already you use one node property "out pointer". This number is an integer number that is a position of byte in "stream out"- the position in file. the "stream out" is a binary file that stores nodes another info. this stream info of an object is rather large and contains all data you need (8 matricies,mesh data file path, textures file path, and all properties you just use and need..). You then can load object rendering data and other data and send them to GPU ready to be rendered. Do not load textures online! Evene 256x256 will take a noticable time. But you can load vertex data online, even more you would say :).
"stream out"- before application starts, the application needs to create the stream out file for the nodes in the tree. You store initial scene in a rather nice text format that you can parse and build a stream out file. Xml is best choice.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this