[Maya-Python] Center pivot while preserving translation with rotateTranslationMatrix

2014-07-28 Thread Aleks Berg-Jones
I have a torus which I set translation to (0,2,2), rotation to (90,0,0) and move the pivot to (5,2,0). Now I center the pivot on the object and none of these values change whereas in other 3d apps translation does actually change when the pivot is centered. Reading up on how this works, in the

Re: [Maya-Python] Couple of housekeeping questions ....

2014-07-28 Thread Tony Barbieri
Ah, thanks for the additional info, Justin! On Mon, Jul 28, 2014 at 6:05 PM, Justin Israel wrote: > Busted on cross-posting? :-) > > @Tony, I also like QSettings since it handles a few things for you like > platform-specific storage locations that can resolve from User -> System. > You can actu

Re: [Maya-Python] Couple of housekeeping questions ....

2014-07-28 Thread Justin Israel
Busted on cross-posting? :-) @Tony, I also like QSettings since it handles a few things for you like platform-specific storage locations that can resolve from User -> System. You can actually pass a Format flag to the constructor to tell it to use INI (I do that do keep it consistent on OSX/Linux)

Re: [Maya-Python] Couple of housekeeping questions ....

2014-07-28 Thread md
omg On Monday, July 28, 2014 4:56:36 PM UTC-4, Marcus Ottosson wrote: > > This couldn't have been a coincidence, could it? :-) > > > http://tech-artists.org/forum/showthread.php?4872-Storing-settings-for-tools&p=25084#post25084 > > > On 28 July 2014 21:51, md > wrote: > >> I have a couple general

Re: [Maya-Python] Couple of housekeeping questions ....

2014-07-28 Thread Tony Barbieri
I have been using QSettings but I don't think I'll continue to use them for all cases. First off on Windows they are stored in the Registry which I'm not super pleased about. I know there is an option to store them in an .ini file as well but I haven't investigated it. The other issue is then th

Re: [Maya-Python] Couple of housekeeping questions ....

2014-07-28 Thread Marcus Ottosson
This couldn't have been a coincidence, could it? :-) http://tech-artists.org/forum/showthread.php?4872-Storing-settings-for-tools&p=25084#post25084 On 28 July 2014 21:51, md wrote: > I have a couple general housekeeping questions for you guys ... > > 1. Where do you store your persistent appli

[Maya-Python] Couple of housekeeping questions ....

2014-07-28 Thread md
I have a couple general housekeeping questions for you guys ... 1. Where do you store your persistent application settings ? 2. How/Where do you check to see if a dialog you have wrapped in the Maya application exists so it does not create multiple instances ? Thanks M -- You received this me

Re: [Maya-Python] Calling external programs from your Python script using subprocess and os.system

2014-07-28 Thread md
Thanks Justin and Marcus ... Popen is the way to go for me. Worked great. On Monday, July 28, 2014 3:54:17 PM UTC-4, Justin Israel wrote: > > The subprocess module superseded all of the other various ways of > launching processes, such as os.system, os.popen, commands, etc. > > What you were call

Re: [Maya-Python] Calling external programs from your Python script using subprocess and os.system

2014-07-28 Thread Justin Israel
The subprocess module superseded all of the other various ways of launching processes, such as os.system, os.popen, commands, etc. What you were calling is the convenience call() function that waits for the return code of the process. So of you don't want to wait for the return code immediately,

Re: [Maya-Python] software agnostic tools

2014-07-28 Thread Justin Israel
As one example, I did something similar when I was experimenting with getting an XBOX kinect to drive some of our characters at SouthPark. It wasn't a graphical interface but I had the same design intentions to make the library agnostic of the host app, so that at some point if I wanted I could sw

Re: [Maya-Python] Calling external programs from your Python script using subprocess and os.system

2014-07-28 Thread md
worked great ... why have both ? On Monday, July 28, 2014 2:05:08 PM UTC-4, Marcus Ottosson wrote: > > Try subprocess.Popen instead. > > > On 28 July 2014 18:32, md > wrote: > >> I have a question about calling external programs from inside Maya using >> Python. (in this case an image viewer) >>

Re: [Maya-Python] Calling external programs from your Python script using subprocess and os.system

2014-07-28 Thread Marcus Ottosson
Try subprocess.Popen instead. On 28 July 2014 18:32, md wrote: > I have a question about calling external programs from inside Maya using > Python. (in this case an image viewer) > > I am trying the following : > > *from subprocess import call* > > and then inside my code using : > > *call([rv_

[Maya-Python] Calling external programs from your Python script using subprocess and os.system

2014-07-28 Thread md
I have a question about calling external programs from inside Maya using Python. (in this case an image viewer) I am trying the following : *from subprocess import call* and then inside my code using : *call([rv_path, "'"+_review_arg+"'"]) * The program launches , but its in a modal state for

Re: [Maya-Python] Point-based animation applied while rendering

2014-07-28 Thread Nicolas Castagne
Auto-answer to my own message : I got time to look arround myself and got some success. Execute the following Maya script : testVar=5 cmds.scriptNode( n='test script node R', bs='print "current time is %f" %maya.cmds.currentTime(q=1); print "value of testVar : %i" %testVar;', st=7, stp='pytho

Re: [Maya-Python] Point-based animation applied while rendering

2014-07-28 Thread Nicolas Castagne
Yet another small new question... Is there a mean to pass a value to a Python script node (as we pass a value to a function) ? Thanks, Nicolas -- You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group. To unsubscribe from this gr

Re: [Maya-Python] Point-based animation applied while rendering

2014-07-28 Thread Nicolas Castagne
Hello all, Thanks for your answers Manuel and Marcus. The notion of "Script Node" is apparently very appropriate, with a "on software frame render" setting. Thank you Marcus. However, it raises two question we could not solve so far. First question : Is it possible to pass a Python variable

Re: [Maya-Python] Point-based animation applied while rendering

2014-07-28 Thread Nicolas Castagne
Hello all, and thanks Manuel and Marcus. The notion of "Script Node" is apparently very appropriate, with a "on software frame render" setting. Thank you Marcus. However, it raises two question we could not solve so far. First question : Is it possible to pass a Python variable to a Script

Re: [Maya-Python] software agnostic tools

2014-07-28 Thread Marcus Ottosson
But I would like to know what are advantages and disadvantages for using this system for our need and how can we achieve this. Without knowing exactly what your needs are, I would summarise the main disadvantage as “up-front cost”; considering the additional overhead of even the simplest call to M

Re: [Maya-Python] software agnostic tools

2014-07-28 Thread LIJU
@Cesar : Thanks for sharing those links, it gives better idea what did you mean. On Sun, Jul 27, 2014 at 9:18 PM, Cesar Saez wrote: > Sure! > I like the way in which design patterns are described on this page, simple > and straight forward: > http://www.go4expert.com/articles/design-pattern-sim