embedded mesh instancing
-
- Posts: 512
- Joined: Wed May 02, 2007 11:34 am
embedded mesh instancing
Hi, I think a similar thing was addressed in a different post not too long ago, but i am having trouble using instanced meshes with different materials. as I understand it, the way to do this is to first define the mesh, then the material, then model instance, material, model, material, model, etc...
but when using an embedded mesh, the material is defined within the mesh node and that seems to override any materials you define later for each instance. if you remove the material from the mesh definition you get an error and adding a material inside the model node is not allowed (though that seems like it would be a logical way for this to work, format-wise).
anyway, if someone could post an example of working code on this I would be very grateful. maybe I am just misunderstanding something.
freaking fantastic program, by the way!
but when using an embedded mesh, the material is defined within the mesh node and that seems to override any materials you define later for each instance. if you remove the material from the mesh definition you get an error and adding a material inside the model node is not allowed (though that seems like it would be a logical way for this to work, format-wise).
anyway, if someone could post an example of working code on this I would be very grateful. maybe I am just misunderstanding something.
freaking fantastic program, by the way!
-
- Posts: 512
- Joined: Wed May 02, 2007 11:34 am
-
- Posts: 512
- Joined: Wed May 02, 2007 11:34 am
yes, so using an external obj, 3ds, or ply gives basically the same problem. an error if you don't give the mesh a pre-defined material, and then no way to override a pre-defined material if you want to change it for each instance of the model. how was this done: http://www2.indigorenderer.com/joomla/f ... light=poly
?
mesh
material
model
material
model
material
model
is what I have in my code, but it's not working for me...
?
mesh
material
model
material
model
material
model
is what I have in my code, but it's not working for me...
-
- Posts: 512
- Joined: Wed May 02, 2007 11:34 am
Who is online
Users browsing this forum: No registered users and 51 guests