Re: [Maya-Python] get scene data python

2018-02-09 Thread AK Eric
Thanks, I'll take a look at that too.  I'm on 2016, so yah, maybe the file 
format has changed since then.  This is actually related to another issue, 
I'll start a new thread for it.

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to python_inside_maya+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/74e791c2-c84a-4fd6-a53c-abf5e1ec1f2b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] get scene data python

2018-02-09 Thread Marcus Ottosson
I updated what I think is a flavour of mayabinary.py a while ago, though
it's very rudimentary still.

https://github.com/mottosso/maya-scenefile-parser

On 9 February 2018 at 20:30, Justin Israel  wrote:

>
>
> On Sat, Feb 10, 2018, 8:15 AM AK Eric  wrote:
>
>> Revive this old thread:  I tried using the mayabinary module, and, I'm
>> getting no love, just running the built in example.  It seems like the
>> mayabinary reader actually expects an *iff *(image) file instead.
>>
>> > python mayabinary.py metaTest.mb
>> > ValueError: The file "C:\temp\maya\metaTest.mb" is not a Maya IFF file.
>>
>> If I then go into the code and disable that check, I get this error:
>> > ValueError: The file "metaTest.mb" is not a Maya file.
>>
>> Anyone got that code working?
>>
>
> What version of Maya are you using? Keep in mine that the mayabinary.py
> code doesn't show an update single 2010
>
>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Python Programming for Autodesk Maya" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to python_inside_maya+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit https://groups.google.com/d/
>> msgid/python_inside_maya/428feaab-7ae0-49c6-b36e-
>> a9aa3da60cf2%40googlegroups.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Python Programming for Autodesk Maya" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to python_inside_maya+unsubscr...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/python_inside_maya/CAPGFgA1QePi0cgCPqNEAvtKzPtt5z
> HPzEvA45RJNqMU8i%3DOdnw%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to python_inside_maya+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/CAFRtmOCcOai%2BATCuAgociz3Q_Gs%2Bp8unUOWVFbngd5z9cKN1mw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] get scene data python

2018-02-09 Thread Justin Israel
On Sat, Feb 10, 2018, 8:15 AM AK Eric  wrote:

> Revive this old thread:  I tried using the mayabinary module, and, I'm
> getting no love, just running the built in example.  It seems like the
> mayabinary reader actually expects an *iff *(image) file instead.
>
> > python mayabinary.py metaTest.mb
> > ValueError: The file "C:\temp\maya\metaTest.mb" is not a Maya IFF file.
>
> If I then go into the code and disable that check, I get this error:
> > ValueError: The file "metaTest.mb" is not a Maya file.
>
> Anyone got that code working?
>

What version of Maya are you using? Keep in mine that the mayabinary.py
code doesn't show an update single 2010


>
> --
> You received this message because you are subscribed to the Google Groups
> "Python Programming for Autodesk Maya" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to python_inside_maya+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/python_inside_maya/428feaab-7ae0-49c6-b36e-a9aa3da60cf2%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to python_inside_maya+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/CAPGFgA1QePi0cgCPqNEAvtKzPtt5zHPzEvA45RJNqMU8i%3DOdnw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] get scene data python

2018-02-09 Thread AK Eric
Revive this old thread:  I tried using the mayabinary module, and, I'm 
getting no love, just running the built in example.  It seems like the 
mayabinary reader actually expects an *iff *(image) file instead.

> python mayabinary.py metaTest.mb
> ValueError: The file "C:\temp\maya\metaTest.mb" is not a Maya IFF file.

If I then go into the code and disable that check, I get this error:
> ValueError: The file "metaTest.mb" is not a Maya file.

Anyone got that code working?


-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to python_inside_maya+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/428feaab-7ae0-49c6-b36e-a9aa3da60cf2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] get scene data python

2012-06-07 Thread Justin Israel
What parts are giving you trouble specifically though? That video is really
long as does a lot of stuff

Here are some examples:

# number of poly faces in scene?
faceCount = cmds.polyEvaluate(cmds.ls(g=True), face=True)

# path and file size of current scene?
import os
name = cmds.file(q=True, sceneName=True)
sizeBytes = os.path.getsize(name)




On Thu, Jun 7, 2012 at 1:07 PM, Matias Volonte volontemat...@gmail.comwrote:

 Justin thanks for answering. I will definitely check what your suggestion.

 Also, I found a youtube video that shows a similiar concept to what I
 need. I would like to have a tool that access files and retrieves data
 (size, face amount, file path, etc) and image of the scene. I already have
 built the core of the tool, but for some reason is hard to achieve the
 scene data of the maya.mb's file.

 Pseudo example:
 http://www.youtube.com/watch?v=B2fE0sVeT44

 Thanks and any tip will help.

 --
 view archives: http://groups.google.com/group/python_inside_maya
 change your subscription settings:
 http://groups.google.com/group/python_inside_maya/subscribe


-- 
view archives: http://groups.google.com/group/python_inside_maya
change your subscription settings: 
http://groups.google.com/group/python_inside_maya/subscribe