«
»

Maya, MentalRay, Python

miBox

04.14.09 | 7 Comments

The mibox for mentalray is the same concept as RibBox for
Renderman.

In your maya 2009 scene create a polyCube primitive. Select the polyshape, open the frameLayout mentalray and select a mi file.
Now when you render this cube, you’ve got the mi file. It’s very interesting, now you can replace a very high mesh by a simple cube in maya UI. But it’s more interesting to replace this cube by an animated character. For simulated a crowd per exemple.
I wrote a python module to do this. mibox.py (python module need the procedure A7.goodPadding contain in goodpadding.mel

I created two definition writeMiBox and readMiBox. writeMiBox get the range to process and determine the bounding box of the selected
objects during the animation. Write an Xml file with this information. And bake the mesh and shading info into a mi file for each frame. Xml file and miDir Files are created at the same place.


Inside the miDir

Now use readMiBox to load the miBox. Select the Xml file and read it.
Left Soft Mesh High | Right miBox – in Maya User Interface


You can setup the start, end and offset animation in the channelBox

In renderView

In future, i post a video with an animated result.
Download 2010 :
mibox.py
goodpadding.mel

Download Maya 2011 :
Dario Ortisi say to me the script doesn’t work on Maya 2011.
I’ve modified the original script to support 2011.
You can fin d the new script here : mibox_2011

Tags: , , , ,

7 Comments

have your say

Add your comment below, or trackback from your own site. Subscribe to these comments.

Be nice. Keep it clean. Stay on topic. No spam.

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

You must be logged in to post a comment.


«
»