scene graph and prestation

Started by
1 comment, last by JohnnyCode 14 years, 3 months ago
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
Advertisement
nobody?
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.

This topic is closed to new replies.

Advertisement