Hello,
(moderator, I don't know if this is the right section for this question... I'd call it 'scene management' rather than 'modeling' but since that section doesn't exist, etc)
I've searched around in the manual, here and on base but cannot find an answer to this one, although it seems very basic. How do I replace one object with another? In my case, I'm talking about polygonal meshes. Say I'd want to swap a cube for a ball. Or a tree I've modelled with another tree. Or a simple proxy-object with a finely detailed one. Or one hundred identical simple trees with one hundred identical detailed trees, all in one swoop? Or one simple tree in a scene with one hundred identical simple trees with one detailed tree?
Hope someone knows how to do this!
jasper
replacing a mesh/object with another one
- xsisupport
- Posts: 713
- Joined: 09 Jun 2009, 11:02
- Location: Montreal Canada
- Contact:
Re: replacing a mesh/object with another one
Reference models?
Re: replacing a mesh/object with another one
I'll get back to you on that later, I know how to use ref'd models but I don't think they would be a practical option in many scenarios. I'll try that out first though.
thanks, Jasper
thanks, Jasper
Re: replacing a mesh/object with another one
Hi, there's a few way that you can try: If its just one object the simplest way is to just use the "Match transforms" option. As long as both object's centers are in the middle of their geometry it will match co-ords perfectly. If it's hundreds of objects like a forest as you say maybe put the whole lot into a model null and match transforms on a model null of the old trees.
Nothing's too difficult to achieve, it just takes longer...
Re: replacing a mesh/object with another one
Hi nas,
it's not a problem to get one object be in the exact position of another one, it's more about having it replace all scene functions of that other object - like animation, hierarchical position, expressions driving or driven by, constraints, dynamics, etc etc. Basically any property an object can have apart from it's mesh.
To make an analogy, think of replacing footage in a layer in a compositing program like After Effects with other footage (alt-drag-done). Or replacing the sounds in a drumpattern you've made in an audio software like Cubase with another set of sounds (drag-drop-done). You want to keep the pattern, keep the composition the way it's set up, you just want to swap the elements that are used.
I've accomplished the job that made me ask this question by using ref'd models, but it was convoluted and not flexible enough - I ran into problems as soon as I wanted to completely swap a mesh with another one and see how that would work, try out a couple of different meshes to see which one would work best and in what combination. Ref'd models are not flexible in that way, they're more heavy-duty scene management assets.
But suggestions are still wellcome!
it's not a problem to get one object be in the exact position of another one, it's more about having it replace all scene functions of that other object - like animation, hierarchical position, expressions driving or driven by, constraints, dynamics, etc etc. Basically any property an object can have apart from it's mesh.
To make an analogy, think of replacing footage in a layer in a compositing program like After Effects with other footage (alt-drag-done). Or replacing the sounds in a drumpattern you've made in an audio software like Cubase with another set of sounds (drag-drop-done). You want to keep the pattern, keep the composition the way it's set up, you just want to swap the elements that are used.
I've accomplished the job that made me ask this question by using ref'd models, but it was convoluted and not flexible enough - I ran into problems as soon as I wanted to completely swap a mesh with another one and see how that would work, try out a couple of different meshes to see which one would work best and in what combination. Ref'd models are not flexible in that way, they're more heavy-duty scene management assets.
But suggestions are still wellcome!
Re: replacing a mesh/object with another one
Hi Jasper,
It's not like lightwave where the mesh itself has to be referenced as it lives externally. That's one of those rare instances where lightwaves limitations actually plays to it's advantage.
It wouldn't work like that in xsi because each mesh is a separate thing in xsi.
The only exceptions are either if it's an instance, a clone, or a reference model. However, xsi planning ahead with these, provides far more flexible solutions as long as you work with it and not try and make it pull off one of lightwave's tricks.
Where was the inflexibility for you in the ref models solution?
It's not like lightwave where the mesh itself has to be referenced as it lives externally. That's one of those rare instances where lightwaves limitations actually plays to it's advantage.
It wouldn't work like that in xsi because each mesh is a separate thing in xsi.
The only exceptions are either if it's an instance, a clone, or a reference model. However, xsi planning ahead with these, provides far more flexible solutions as long as you work with it and not try and make it pull off one of lightwave's tricks.
Where was the inflexibility for you in the ref models solution?
Re: replacing a mesh/object with another one
take a look here if this works for your needs
http://caffeineabuse.blogspot.com/searc ... /Scripting
http://caffeineabuse.blogspot.com/searc ... /Scripting
Re: replacing a mesh/object with another one
Hi Paul, didn't have time to get back to you before. Here's the project I ran into this issue with:
I had to do a kind of transformer-like animation where a stack of beercrates would transform into a football stand. I would be supplied a hires industrial mesh, but it would only arrive late in the production so I had to go ahead and set up everything using a proxy. I set it all up using one crate as a master-model and the stand was a hierarchy made out of clones of that, that were being driven by the master with offsets and stuff like that.
I turned the mastermodel into a reffed model and that way I could make changes to the original model (in another scene), save that scene and the changes would reflect in my animated scene. Some of the attributes (mainly UV sets and materials) would not move across correctly from the reffed model to the clones though, especially so after doing a complete mesh switch in my original model (it was not about modifying the mesh, it was being replaced altogether with another one). The reffed model would have all the attributes of the original, but the clones would be random - some materials would show up, some wouldn't. Same with UVs. In the end the number of objects in the scene wasn't that big that I couldn't manually fix things each time I made a change.
How would you go about something like this if it would involve massive amounts of clones/models/objects?
cheers,
Jasper
I had to do a kind of transformer-like animation where a stack of beercrates would transform into a football stand. I would be supplied a hires industrial mesh, but it would only arrive late in the production so I had to go ahead and set up everything using a proxy. I set it all up using one crate as a master-model and the stand was a hierarchy made out of clones of that, that were being driven by the master with offsets and stuff like that.
I turned the mastermodel into a reffed model and that way I could make changes to the original model (in another scene), save that scene and the changes would reflect in my animated scene. Some of the attributes (mainly UV sets and materials) would not move across correctly from the reffed model to the clones though, especially so after doing a complete mesh switch in my original model (it was not about modifying the mesh, it was being replaced altogether with another one). The reffed model would have all the attributes of the original, but the clones would be random - some materials would show up, some wouldn't. Same with UVs. In the end the number of objects in the scene wasn't that big that I couldn't manually fix things each time I made a change.
How would you go about something like this if it would involve massive amounts of clones/models/objects?
cheers,
Jasper
Who is online
Users browsing this forum: No registered users and 56 guests