PDA

View Full Version : Parsing Maya binary file with mel


ghoest
03-29-2009, 07:37 AM
Does anyone know any python module that will either convert a .mb file to ascii or a format I can grab fun things like image paths out of?

I'll continue to play with thing and update this thread

Thanks!

Robert Bateman
03-30-2009, 10:15 AM
Use mel. If you *really* want to read a maya binary format, it's stored as an iff based format where the node tags are documented in the node+attr reference (click on the tags buttons). Realistically, you don't want to read the maya binary file, becuase most of it is undocumented, and even if you did manage to read it, it wouldn't give you anything useful. So, the only way to convert to maya ascii is to use mel to save as a different type (assuming there are no unknown nodes, in which case the conversion will always fail). Even if you converted the file to maya ascii, you'd not get anything useful out of it. Therefore the simplest way (and dare I say it, the only sane way) is to use mel to get the paths in a running instance of Maya.

CGTalk Moderation
03-30-2009, 10:15 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.