Home » XSI

Digital assets in XSI.

16 June 2006 7,712 views No Comment

Sometimes when you’re trying your hardest to put together a rig that the animators won’t break, you wish that XSI had something like Houdini’s digital assets. In case you haven’t come across Houdini yet, ‘Digital Assets’ are a way of encapsulating a group of objects and hiding everything except for certain items that you choose.

So as an example, you could create a Digital Asset of an apple. In the interface that you create, you would maybe expose a control to change the color of the apple. In fact, to make it even easier, it might just be a slider that controls the color to go from green to red. You could call that control ‘Ripeness’ if you want. You could also add a slider for controlling the size.

If you now give this asset to another artist, the only way they can change the apple is for them to use the controls you have provided. This means that they won’t be able to make the apple turn blue (accidentally or otherwise).
In a large pipeline, this can prove to be extremely useful. It means that if the TD knows what they’re doing, they can deploy assets in production which won’t get broken or changed in an unexpected way later on. Obviously, care must be taken not to take this paradigm too far and to over encapsulate the object making that asset inflexible. So research and planning for an asset’s role in the pipeline is vital to make sure that the right level of control is applied.
So how can we create Digital Assets in XSI? Natively, they aren’t supported. What do we need? We just need a way to store our asset, a method of presenting certain parameters of our choice to the user, and a way of hiding objects from various XSI editors (Explorer, etc.).
The obvious choice for storing our asset is to use an XSI model. Each model represents a unique namespace for objects and they are XSI’s current method of asset encapsulation (albeit limited).
The second one is also easy. Proxy parameters enable us to provide another location to change any parameter we want. We can also use conventional parameters and then link to them using expressions. While this method might not be quite as nice as a fully customised interface, it will do for this article. Other options might include using an HTML page to display controls to drive parameters, or an ActiveX control, etc.
So that just leaves us with hiding objects from the various XSI editors. To do that we use this:
obj.SetCapabilityFlag( siNotInspectable, true);
The SetCapabilityFlag() method can be found on the ProjectItem object, which occurs near the top of the class hierarchy of the SDK. This means that a large number of objects support this method, including mesh objects, operators, clips, materials, properties, clusters, and many others. In addition, the parameter object also has this method, despite not inheriting from the ProjectItem object.

See the next page for a downloadable example of the apple Digital Asset.

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading...

Leave your response!

Add your comment below, or trackback from your own site. You can also subscribe to these comments via RSS.

You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

This is a Gravatar-enabled weblog. To get your own globally-recognized-avatar, please register at Gravatar.