I'm trying hard to import a scene file to ogre following the (very useful) tutorial found in the ogreaddons\dotsceneoctree, readable at this adress
http://www.icetecstudios.com/public/OgreTest/Tutorial/
I run into a very strange problem (at least for me, i m quite newbie in Ogre) : when i am trying to import my scene (a building) the geometry of some parts of the building is completly messed up. When I import only partially my building every thing is fine.
It seems to me that there is a threshold not to overstep in the number of faces in the scene. under 70000 faces (approx.), everything is ok, but more renders a completly wrong geometry.
Please HELP, what am i doing wrong?
I tried changing the parameters of the sceneconverter when compiling the octree but it doesn't help (but in fact I'm not sure to understand the meaning of each parameters since i don't know precisely what is an octree in 3D rendering)
Geometry Problem when importing scene with DotSceneOctree
-
ncazanav
- Gnoblar
- Posts: 6
- Joined: Fri Feb 24, 2006 10:29 am
- tuan kuranes
- OGRE Retired Moderator

- Posts: 2653
- Joined: Wed Sep 24, 2003 8:07 am
- Location: Haute Garonne, France
- x 4
- Contact:
-
ncazanav
- Gnoblar
- Posts: 6
- Joined: Fri Feb 24, 2006 10:29 am
- tuan kuranes
- OGRE Retired Moderator

- Posts: 2653
- Joined: Wed Sep 24, 2003 8:07 am
- Location: Haute Garonne, France
- x 4
- Contact:
I'm no expert of dotscene exporter.
Sorry, wasn't very clear. Second try :
Problem is :
Dotscene seems export everything into a Single Buffer, or into Several Buffer but partitionned only by space partionning algoritms (octree). Problem arise when a single buffer needs more than 65535 indexes.
Three solution there :
If you reduce whole scene tris counts so that it need smaller index buffer, it would work. But you loose details.
If you patch dotscene loaded so that it loads index into 32Bits indexbuffer. But it will need recent (<2yrs) hardware, will impact performance and will not loose details.
If you patch dotscene exporter so that it handles that particular case and spit buffer > 65535 into several ones. It will work on all hardware and will not loose details. (That's the best solution.)
Sorry, wasn't very clear. Second try :
Problem is :
Dotscene seems export everything into a Single Buffer, or into Several Buffer but partitionned only by space partionning algoritms (octree). Problem arise when a single buffer needs more than 65535 indexes.
Three solution there :
If you reduce whole scene tris counts so that it need smaller index buffer, it would work. But you loose details.
If you patch dotscene loaded so that it loads index into 32Bits indexbuffer. But it will need recent (<2yrs) hardware, will impact performance and will not loose details.
If you patch dotscene exporter so that it handles that particular case and spit buffer > 65535 into several ones. It will work on all hardware and will not loose details. (That's the best solution.)
Last edited by tuan kuranes on Fri Feb 24, 2006 6:29 pm, edited 2 times in total.
-
ncazanav
- Gnoblar
- Posts: 6
- Joined: Fri Feb 24, 2006 10:29 am
I am surprised that there is no loader for scene with more than 65535 tris. Is there another way to load such scenes?
P.S : il fait beau a Grenoble, de la neige?
I'll have a look at the code of the dotscene exporter, but i am not sure to be able to patch it as you suggest...Do you know where can I find docs about octree, buffers, i dont know much about 3d programming...If you patch dotscene exporter so that it handles that particular case and spit buffer > 65535 into several ones. It will work on all hardware and will not loose details. (That's the best solution.)
P.S : il fait beau a Grenoble, de la neige?
- tuan kuranes
- OGRE Retired Moderator

- Posts: 2653
- Joined: Wed Sep 24, 2003 8:07 am
- Location: Haute Garonne, France
- x 4
- Contact:
perhaps the problem is that the 100.000 tris is not taking advantage of space partition, therefore resulting in a single big buffer in a single leaf of the Octree.
Isn't there any option to the exporter/loader, nor the loader to change Octree Depth, or the root Octree Size ?
There's lot of litterature on the web on spatial partionning, octree, quadtree, kd-tree, bsp.
Here's some
basic : http://www.gamasutra.com/features/19970801/octree.htm
more advanced : http://www.flipcode.com/articles/articl ... rees.shtml
But above proposed solution is more Ogre Mesh handling oriented, as patch will results in code that take a big Mesh Buffer (> 65535) and splits it in several ones (< 65535).
Just have to find where to do that.
Anyway Octree read is a must read to know how everything is handled there and optimize scene organization.
ps: pas de neige en bas, ni de soleil, à Grenoble, obligé de gravir les sommets pour percer la couche de nuages et tater la neige
Isn't there any option to the exporter/loader, nor the loader to change Octree Depth, or the root Octree Size ?
There's lot of litterature on the web on spatial partionning, octree, quadtree, kd-tree, bsp.
Here's some
basic : http://www.gamasutra.com/features/19970801/octree.htm
more advanced : http://www.flipcode.com/articles/articl ... rees.shtml
But above proposed solution is more Ogre Mesh handling oriented, as patch will results in code that take a big Mesh Buffer (> 65535) and splits it in several ones (< 65535).
Just have to find where to do that.
Anyway Octree read is a must read to know how everything is handled there and optimize scene organization.
ps: pas de neige en bas, ni de soleil, à Grenoble, obligé de gravir les sommets pour percer la couche de nuages et tater la neige
- jacmoe
- OGRE Retired Moderator

- Posts: 20570
- Joined: Thu Jan 22, 2004 10:13 am
- Location: Denmark
- x 179
- Contact: