Xmas tree Obj and 3DS meshes not loading all details
Xmas tree Obj and 3DS meshes not loading all details
Is Irrlicht unable to load more complex meshes, like trees?
Here is a link to an obj file that irrlicht loads but dumps nearly all of the pine needles:- http://www.sendspace.com/file/bgmh37
I tried with 3DS fromat, does the same, and smoothing does not work.
The mesh works fine in Max and Blender.
It would be nice to be able to make a nice xmas tree scene with Irrlicht!
Any ideas welcome!
Here is a link to an obj file that irrlicht loads but dumps nearly all of the pine needles:- http://www.sendspace.com/file/bgmh37
I tried with 3DS fromat, does the same, and smoothing does not work.
The mesh works fine in Max and Blender.
It would be nice to be able to make a nice xmas tree scene with Irrlicht!
Any ideas welcome!
Re: Xmas tree Obj and 3DS meshes not loading all details
Are there too many vertices for the u16 index type?
See:
http://irrlicht.sourceforge.net/forum/v ... ices+limit
and:
http://irrlicht.sourceforge.net/forum/v ... ices+limit
Regards,
smso
See:
http://irrlicht.sourceforge.net/forum/v ... ices+limit
and:
http://irrlicht.sourceforge.net/forum/v ... ices+limit
Regards,
smso
Re: Xmas tree Obj and 3DS meshes not loading all details
Thanks for that. The tree has 7 materials, so I guess it must be split into the coresponding groups. I´ll check the counts tomorrow and see.
I guess the U16 index can´t just be changed to u32...?
I guess the U16 index can´t just be changed to u32...?
-
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
Re: Xmas tree Obj and 3DS meshes not loading all details
Well, two things for the u16: You could use the special mesh/buffer type that supports 32bit indices, but the loaders don't. And you don't want to render meshbuffers with more than 10.000 tris, hence no need for more than 16bit indices.
The console would output a warning, though, if you render more than 65k indices.
The console would output a warning, though, if you render more than 65k indices.
Re: Xmas tree Obj and 3DS meshes not loading all details
Just checked and am getting 1.3 million vertices and the mentioned warning is going to the log.
The tree mesh, which is available on the SendSpace link I listed here earlier, has 7 materials, so its already split into groups/meshes.
I´m not a Blender expert so not sure how to split it further.
Could someone take a look at the obj and advise how best to handle it, editing the mesh or changing irrlicht, then maybe we could make a nice Irrlicht xmas scene... just an idea..
The tree mesh, which is available on the SendSpace link I listed here earlier, has 7 materials, so its already split into groups/meshes.
I´m not a Blender expert so not sure how to split it further.
Could someone take a look at the obj and advise how best to handle it, editing the mesh or changing irrlicht, then maybe we could make a nice Irrlicht xmas scene... just an idea..
Re: Xmas tree Obj and 3DS meshes not loading all details
As every other 3D program and its dog can load this mesh, I would think that Irrlicht should to, and perhaps issue a warning...
I guess I will see if I can increase the indicies to support more vertices in the loaders... happy christmas!
I guess I will see if I can increase the indicies to support more vertices in the loaders... happy christmas!
Re: Xmas tree Obj and 3DS meshes not loading all details
That model has over 1,000,000 vertices and 700,000 faces, and You ABSOLUTELY MAD if you think this is going to work in Irrlicht or any other game engine.
Try using the Sapling add on to make a tree -- It can be turned on in blender:
File -> User preferences -> addons -> Add Curve -> Sapling [X]
I took that model and knocked it down a few hundred thousand polies and re-exported it to obj.
You can download it from http://vital.lcarscom.com/Pine.zip
Try using the Sapling add on to make a tree -- It can be turned on in blender:
File -> User preferences -> addons -> Add Curve -> Sapling [X]
I took that model and knocked it down a few hundred thousand polies and re-exported it to obj.
You can download it from http://vital.lcarscom.com/Pine.zip
Re: Xmas tree Obj and 3DS meshes not loading all details
It does print a warning:
Yep, same as mss, that model would run seconds per frame.robmar wrote:Just checked and am getting 1.3 million vertices and the mentioned warning is going to the log.
Re: Xmas tree Obj and 3DS meshes not loading all details
The frame rate will be low I know, but if Blender can show it, why not irrlicht.
Your model has the same problem I guess as only the trunk, a couple of branches, and a few needles show when I load it with Irrlicht.
Your model has the same problem I guess as only the trunk, a couple of branches, and a few needles show when I load it with Irrlicht.
Re: Xmas tree Obj and 3DS meshes not loading all details
So I´ve exported the model without the needles and that is within limits.
The plan is to export a few needles as one mesh, then paste em all over the tree, but Blender is hanging when I try to split them.
Too many I guess in one mesh!!! Any Blener experts about?
The plan is to export a few needles as one mesh, then paste em all over the tree, but Blender is hanging when I try to split them.
Too many I guess in one mesh!!! Any Blener experts about?
Re: Xmas tree Obj and 3DS meshes not loading all details
So I checked through the Obj loader code, and all vertices are loaded, but the drawing code uses as we know the u16 for indices and faces.
I went thro the code and using a #define, recompiled with u32 for indicies and faces.
The result after loading large 1.3 million vertice meshes was distorted rendering, a few of the vertices were quite wrong.
Maybe I missed an u16 in a for-loop somewhere though! May take a while to go through it all.
I went thro the code and using a #define, recompiled with u32 for indicies and faces.
The result after loading large 1.3 million vertice meshes was distorted rendering, a few of the vertices were quite wrong.
Maybe I missed an u16 in a for-loop somewhere though! May take a while to go through it all.
Re: Xmas tree Obj and 3DS meshes not loading all details
1.3 million verts? You have to split this model inside an Irrlicht from smaller parts. How many mesh buffers/materials do You have on Your model? Please don't tell me that just 1
Please remember that renderers in graphic engines are optimized for display smaller tris grups with high performance, 3D Modelling tools are optimized for display high poly models, but not with high FPS.
Please remember that renderers in graphic engines are optimized for display smaller tris grups with high performance, 3D Modelling tools are optimized for display high poly models, but not with high FPS.
Library helping with network requests, tasks management, logger etc in desktop and mobile apps: https://github.com/GrupaPracuj/hermes
Re: Xmas tree Obj and 3DS meshes not loading all details
well its a tree in this case, so there is the trunk, broughs, twigs, 6 materials for 6 meshbuffers, and 1 massive mesh buffer for all the needles. Total 7.
Should the needles be best separated into two separate meshes, a ring of needles for the ends of all twigs, and a small row of needles that can be duplciated and placed along the sides of twigs?
I´ve done the separation into 21 mesh buffers and its fine, the problem is that sometimes I just want to load some mesh, and not spend time in Blender or whatever with it.
I guess its not critical, its just that so far all other software can load any mesh as long as the system has the memory.
Should the needles be best separated into two separate meshes, a ring of needles for the ends of all twigs, and a small row of needles that can be duplciated and placed along the sides of twigs?
I´ve done the separation into 21 mesh buffers and its fine, the problem is that sometimes I just want to load some mesh, and not spend time in Blender or whatever with it.
I guess its not critical, its just that so far all other software can load any mesh as long as the system has the memory.
Re: Xmas tree Obj and 3DS meshes not loading all details
The needles are double-sided faces, so in order to see them from both sides in Irrlicht you have to disable backface culling per material that is used by the needles.robmar wrote:well its a tree in this case, so there is the trunk, broughs, twigs, 6 materials for 6 meshbuffers, and 1 massive mesh buffer for all the needles. Total 7.
Should the needles be best separated into two separate meshes, a ring of needles for the ends of all twigs, and a small row of needles that can be duplicated and placed along the sides of twigs?
Re: Xmas tree Obj and 3DS meshes not loading all details
did that already. with the tree loaded the FPS takes quite a hit, I guess its just too complex an object to run in real-time well.
I´ve seen some RT 3D that handles trees on large landscapes from that french guy, had thought they were meshes but guess he´s using another technique..
I´ve seen some RT 3D that handles trees on large landscapes from that french guy, had thought they were meshes but guess he´s using another technique..