Page 3 of 9

Posted: Wed Sep 22, 2010 7:46 am
by hybrid
Lonesome Ducky wrote:If irrlicht has a way of changing MipMap bias, you can change it to a further value as well.
Yes, in SMaterial, MipmapLODBias or something like that.

Posted: Thu Sep 30, 2010 2:37 am
by pepeshka
Hey ducky,

Once again, bravo, I just have a question; I've got .obj meshes with multiple materials applied, and when I use the combiner, everything but the first material gets dropped (turns black). Does this support multiple materials, am I just doing it wrong?

Thanks!

Posted: Thu Sep 30, 2010 4:09 am
by Lonesome Ducky
It should, as the dwarf model had a different texture for its axe and it worked. Now, if you're using materials with different colors then that's a problem. It combines any materials that use the same texture into one material (otherwise separate meshbuffers would have to be used, which would defeat the purpose.) Be sure you're using materials that have textures

Posted: Thu Sep 30, 2010 5:35 pm
by Xero
really nice work lonesome ducky, but

1.Although the FPS is shown and i can see a big difference between the mesh combiner and scene nodes I get a black screen when i start the example.

2. I don't really understand how your mesh combiner works. Whats the difference between normal scene nodes and your method? Pls explain for dummies^^

Posted: Thu Sep 30, 2010 7:45 pm
by pepeshka
That's good to hear, actually I was just using a test model with (IIRC) one textured material and one color. I'll try with multiple textures.

Posted: Thu Sep 30, 2010 9:06 pm
by Lonesome Ducky
Xero wrote:really nice work lonesome ducky, but

1.Although the FPS is shown and i can see a big difference between the mesh combiner and scene nodes I get a black screen when i start the example.

2. I don't really understand how your mesh combiner works. Whats the difference between normal scene nodes and your method? Pls explain for dummies^^
1) Try moving the camera around, I don't think I actually faced it towards the terrain :lol:

2) Basically, the graphics card can render a single huge batch of triangles much faster than tons of small batches. So this combines those small batches into one large batch. Not only this, but it also greatly reduces the amount of work irrlicht itself has to do, because it only needs to update one scene node instead of thousands.
pepeshka wrote:That's good to hear, actually I was just using a test model with (IIRC) one textured material and one color. I'll try with multiple textures.
Yeah, I seem to recall having problems with a single texture being used for the whole thing, as the texture packer would expand the texture atlas bigger than it needed to be for just one texture, so the uv's would be off and incorrect.

Posted: Fri Oct 01, 2010 3:08 pm
by Xero
Lonesome Ducky wrote: 1) Try moving the camera around, I don't think I actually faced it towards the terrain :lol:
can't find it ...just a black screen.

Posted: Fri Oct 01, 2010 9:03 pm
by Lonesome Ducky
Well that's odd, I haven't had any other reports of it doing this. Have you tried using it in your own code or tried recompiling the example?

Posted: Sat Oct 02, 2010 7:37 am
by milkshakeman
a small question; is it possible to use mesh scene combiner on a complete scene and still have standard shadows and lighting working? Because afaik you can not add a shadowvolume to this kind of node.

Posted: Sat Oct 02, 2010 2:50 pm
by Lonesome Ducky
You can, shadow volumes and lighting should work. Just be aware that the whole thing uses the same material, so without shaders you won't be able to set specular etc. for individual models.

Posted: Sun Nov 07, 2010 7:25 am
by Dan911
Was messing around with this, can be very helpful performance boost in a lot of cases! Any chance of this getting added to irrlicht?

Posted: Sun Nov 07, 2010 10:43 am
by Zurzaza
Great project Ducky...but there still a lot of memory leaks..is there a way to fix this?

A question about combining meshes

Posted: Wed Nov 24, 2010 6:52 pm
by DanielLoynaz
It is possible to combine several meshes and to respect the materials and textures assigned, using MeshCombiner.

My problem is the following: I am creating a room using planes for walls, floor and roof and when I combine the meshes, using MeshCombiner, it tries to combine the textures of the floor, walls and roof in all the places.

Some way exists of combining the meshes of the planes to obtain a single object but that the textures are in the place that I put them.

Re: A question about combining meshes

Posted: Thu Nov 25, 2010 3:14 am
by Lonesome Ducky
DanielLoynaz wrote:It is possible to combine several meshes and to respect the materials and textures assigned, using MeshCombiner.

My problem is the following: I am creating a room using planes for walls, floor and roof and when I combine the meshes, using MeshCombiner, it tries to combine the textures of the floor, walls and roof in all the places.

Some way exists of combining the meshes of the planes to obtain a single object but that the textures are in the place that I put them.
It will only work when the textures don't tile, which is likely the problem your case. It is not at all trivial to make it work with tiling textures and I regret to say that it's beyond my ability.
Zurzaza wrote:Great project Ducky...but there still a lot of memory leaks..is there a way to fix this?
I wasn't aware of any large memory leaks. I thought I deleted all my pointers. But if you're having problems with it, go through the code and make sure I really did delete all the pointers :lol:

Posted: Thu Apr 14, 2011 4:58 pm
by Kostya
Now this library not correct calculate bounding box.

To fix this bug add this line in CMeshCombiner.cpp
to lines 470 and 351

Code: Select all

meshBuffer[x]->recalculateBoundingBox();