Meshing Question What is the "STATIC" flag ?

Bibi Uncle

50% Orbinaut, 50% Developer
Addon Developer
Joined
Aug 12, 2010
Messages
192
Reaction score
0
Points
0
Location
Québec, QC
Hello everybody !

I am currently working on a OpenGL Mesh Viewer (you can see my project here : http://orbiter.dansteph.com/forum/read.php?f=5&i=21450&t=21450&page=0 I write in French, I come from Quebec, Canada. However, there's a lot of screenshot.). My program reads the mesh file and displays it on the screen (with textures).

However, when I try loading the 2010 version of Atlantis, my program always bugs.

By looking in the mesh file itself, I find a line which is "STATIC", that is at the beginning of a few groups. By looking in the 2006 versions of the Atlantis mesh, it doesn't appear.

I would like to know this line specify. I have look in the 3DMODEL.pdf and there is no reference to it.
 
might be an optimization thing.... where's the good doctor?
 
Static mesh groups are those which will not have their vertices modified dynamically during the simulation session (e.g. by animations). Orbiter creates vertex buffers that can be loaded directly on the GPU for static groups, while dynamic groups are kept in host memory.

So declaring mesh groups 'STATIC' makes rendering them more efficient, as long as they are not modified during the simulation.

Alternatively, you can declare the entire mesh as static by putting a 'STATICMESH' flag into the header (before the first group definition). Then to exempt individual groups from being treated statically, you put in a 'DYNAMIC' flag in the appropriate group definition.
 
Wow...that kind of information would maybe bring us 3 fps in SSU...
 
Thank you Dr. Schweiger !

Finaly, my program skip those lines because I only render the mesh, no need of rendering optimisations like that. However, this is a really good idea for Orbiter. It'll probably save a lot of memory (and time...).
 
Back
Top