0

I want to store some export settings into my binary Maya file, but I also want to be able to import those settings from an existing, on disk binary Maya file. I have looked at fileInfo, which works to save the data, but I don't know how I can read that out of another Maya .mb file without loading it into the scene.

Any ideas? A side-band file is not an option.

Steven
  • 619
  • 5
  • 24
  • 1
    It is not possible to read the file infos from a binary file without opening it in maya. What you can try is to open it in an seperate process maybe with mayapy and read the needed data. Of course a maya ascii file would be easier to parse but I suppose that is not an option either. – haggi krey Oct 06 '19 at 12:24
  • What about using .ma? – ababak Oct 08 '19 at 11:50
  • 1
    You can have a look at this library for reading Maya binary: https://mayatools.readthedocs.io/en/latest/binary.html – ababak Oct 08 '19 at 12:20
  • @ababak We normally use binary formats for size and speed. Is .MA noticably slower for large files? – Steven Oct 08 '19 at 15:32
  • 1
    @Steven We use .ma files in production as it is easier to fix if something goes wrong and allows us to read and modify theses files outside Maya. I would not say it is noticeably slower in any way. – ababak Oct 09 '19 at 07:45

0 Answers0