Hello!
I have an OBJ mesh. How can I use subobjects of main model?
For example, in Unity I can import my mesh and work with all components of it (car model has wheels, mirrors etc).
OBJ mesh groups
Re: OBJ mesh groups
Each meshpart with an own material is in it's own meshbuffer. You can access those from the mesh interface.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: OBJ mesh groups
Give a couple of examples, please.CuteAlien wrote:Each meshpart with an own material is in it's own meshbuffer. You can access those from the mesh interface.
Re: OBJ mesh groups
IMeshSceneNode::getMesh to get the mesh: http://irrlicht.sourceforge.net/docu/cl ... _node.html
IMesh::getMeshBuffer to access a meshbuffer by index: http://irrlicht.sourceforge.net/docu/cl ... _mesh.html
Not sure if you need any other information. Depends on what you are actually planning to do with those meshbuffers...
IMesh::getMeshBuffer to access a meshbuffer by index: http://irrlicht.sourceforge.net/docu/cl ... _mesh.html
Not sure if you need any other information. Depends on what you are actually planning to do with those meshbuffers...
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: OBJ mesh groups
Probably it's not what I want.
I have the main model. When it's loaded, debug writes "loaded group start" and name of subobjects. So, how can I manipulate them?
UPD: This is my OBJ mesh with subobjects. I want to control them separately.
I have the main model. When it's loaded, debug writes "loaded group start" and name of subobjects. So, how can I manipulate them?
UPD: This is my OBJ mesh with subobjects. I want to control them separately.
Re: OBJ mesh groups
Yeah, probably not doing what you want. Meshbuffers don't have names - and you generally don't manipulate them (as in moving them around or so).
Can't tell from just a few names, but probably what you need here is to create scene instead of a single model. I've not worked yet by doing complete scenes in Blender and exporting them, so not sure what might work. Maybe give an collada (.dae) exporter a try.
Can't tell from just a few names, but probably what you need here is to create scene instead of a single model. I've not worked yet by doing complete scenes in Blender and exporting them, so not sure what might work. Maybe give an collada (.dae) exporter a try.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: OBJ mesh groups
OK. I will try to separate my model. Thanks for your reply!