Re: [Maya-Python] Re: News: Additional Manager for Group

2021-06-01 Thread Kurian O.S
Nice .. thanks to both of you !! .. Marcus it's time to fight with spams :)

On Tue, Jun 1, 2021 at 11:53 AM vince touache  wrote:

> yy! And I'm also happy that Marcus has accepted =]
> Thank you both for the priceless work done here!
>
> Le mardi 1 juin 2021 à 14:50:59 UTC-4, justin...@gmail.com a écrit :
>
>> Hi Everyone!
>>
>> I wanted to let you all know that there is now an additional Manager for
>> this group.
>> Marcus Ottosson has been a very active and valuable contributor to the
>> group since Aug 2010. I'm happy to report that Marcus has accepted my
>> request to share the responsibility of approving new members and smashing
>> spam!
>>
>> Thank you Marcus!
>>
>> Justin
>>
> --
> 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/22c47f0d-2217-40cd-9162-f152b8ae24b6n%40googlegroups.com
> 
> .
>


-- 
--:: Kurian ::--

-- 
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/CANEMyhPhykWtXGhXPdFU-1Zth05KObp0KkMnSG4juvHFfGwmeA%40mail.gmail.com.


Re: [Maya-Python] Ctrl + P

2021-04-09 Thread Kurian O.S
https://knowledge.autodesk.com/support/maya/learn-explore/caas/CloudHelp/cloudhelp/2018/ENU/Maya-Basics/files/GUID-B79EBC73-40D6-4D7C-B1D4-5DF5C8784914-htm.html

MC.colorEditor() ?


On Fri, Apr 9, 2021 at 11:36 AM Marcus Ottosson 
wrote:

> Sorry for the cryptic title, but this has eluded me for years and I can
> never remember the hotkey for this hidden but surprisingly useful little
> widget that pops up in Maya whenever you hit Ctrl + P when I actually
> need it. So there, crystallised and written into the stone that is the
> internets.
>
> Does anyone know what this is called? Where does it come from? And how can
> it can be called from Python? :O
>
> And if you think “Why didn’t he just look in he Hotkey editor, lol?”, then
> think again!
>
> [image: image.png]
>
> --
> 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/CAFRtmOByy0bntSPZ4pzCO40GeF42PmNvdaJVg65f80HpN%3Dq2wA%40mail.gmail.com
> 
> .
>


-- 
--:: Kurian ::--

-- 
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/CANEMyhOYFA8Cyct%2Bjqyt4KeEZ2nk9wSShQMgV3eEoPDDdtzwJQ%40mail.gmail.com.


Re: [Maya-Python] Checking order of list items in 2 lists

2018-10-10 Thread Kurian O.S
Sort can do that


In [2]: list01=['cleve', 'adam', 'yuno', 'pete']

In [3]: list02 = ['pete', 'yuno', 'cleve', 'adam']

In [4]: list02 = sorted(list2, key=list01.index)

In [5]: list02
Out[5]: ['cleve', 'adam', 'yuno', 'pete']


On Wed, Oct 10, 2018 at 2:31 PM kiteh  wrote:

> Hi Justin, sorry that I may have made my question confusing/ I was
> babbling, typing away of the way I am trying to phrase my question.
> Let me try again :)
>
> 1. Deriving the hierarchy from Outliner
>  Eg. This is the hierarchical level as seen in my Outliner
>
> |-- base
> |--|-- names
> |--|--|-- cleve
> |--|--|-- adam
> |--|--|-- yuno
> |--|--|-- pete
>
>
> If I run a cmds command as follows, note that the result is as what I will
> be seeing in the Outliner.
>
> list01 = cmds.listRelatives('base', ad=True, f=True)[:-1]
> print all_items
> """
> Result :
> ['|base|name|cleve',
>  '|base|name|adam',
>  '|base|name|yuno',
>  '|base|name|pete']
> """
>
>
> 2. As mentioned, list02 is derived from dictionary keys from a custom
> module, but the result/ order from the dictionary's keys does not follows
> any orders etc.
> list02 = ['pete', 'yuno', 'cleve', 'adam']
>
>
> And so, I am trying to check the ordering between 2 lists, one from
> Outliner, the other from a custom iterator, where list01 is the main list
> to be check.
> In this case, what I am trying to achieve is:
>
>- if the order of list02 is different from list01, re-order the items
>in list02 such that it follows the same hierarchical level in list01
>
>
> About the part that I say I cannot use `list01 = list02` is because I will
> be making use of the other values within that dicitonary (where it derive
> the list02) in a different application, and sorry that I mentioned about
> `sorted`, ignore it as I seems to have make the question more confusing.
>
> --
> 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/d6c9066b-e3f2-4186-b544-98bea96b5726%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>


-- 
--:: Kurian ::--

-- 
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/CANEMyhM3UEYTevSG97UrekfCkAW26Yac10Ut3vhjkLmmaWh-JA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] dock menu help

2018-03-06 Thread Kurian O.S
There are few things wrong with this code .. but for answering your
question

You where trying to create multiple instance with same name with this line
.."christy.dockControl( 'MyRigShortcut',area='left', content= myWindow ,
allowedArea='left' )"
that's why you got that error , to correct that you can add condition to
check if its exists then delete it.


import maya.cmds as christy

if christy.dockControl('MyRigShortcutDock',  q=1, ex=1) and
christy.window('MyRigShortcut', exists=True):
christy.deleteUI('MyRigShortcutDock')
christy.deleteUI('MyRigShortcut', window=True)

myWindow = christy.window("MyRigShortcut", iconName='Short Name',
widthHeight=(200, 55) )
christy.columnLayout( adjustableColumn=True )
christy.button (label = 'Show/Hide Joint', c = 'HideShow()')
christy.setParent('..')
christy.showWindow(myWindow)


def HideShow():
jointList = []
jointList = christy.ls(type = 'joint' )
for j in jointList:
n = christy.getAttr (j+'.drawStyle')
if (n==0):
christy.setAttr(j+'.drawStyle',2)
else:
christy.setAttr(j+'.drawStyle',0)
buttonForm = christy.formLayout( parent = myWindow)

christy.dockControl( 'MyRigShortcutDock',area='left', content= myWindow ,
allowedArea='left')


On Tue, Mar 6, 2018 at 7:11 AM, Cssara  wrote:

> am new to python..I try to create a button with a ui..for the first time
> its ok.. if i try to run the script for the 2nd time its shows
> myrigshortcut is not unique. please help me to rectify this
>
>
>
>
>
> import maya.cmds as christy
>
> if christy.dockControl('MyRigShortcut', exists=True):
> christy.deleteUI('MyRigShortcut', window=True)
>
>
>
> myWindow = christy.window( iconName='Short Name', widthHeight=(200, 55) )
> christy.columnLayout( adjustableColumn=True )
> christy.button (label = 'Show/Hide Joint', c = 'HideShow()')
> christy.setParent('..')
> christy.showWindow(myWindow)
>
>
> def HideShow():
> jointList = []
> jointList = christy.ls(type = 'joint' )
> for j in jointList:
> n = christy.getAttr (j+'.drawStyle')
> if (n==0):
> christy.setAttr(j+'.drawStyle',2)
> else:
> christy.setAttr(j+'.drawStyle',0)
> buttonForm = christy.formLayout( parent = myWindow)
>
>
> christy.dockControl( 'MyRigShortcut',area='left', content= myWindow ,
> allowedArea='left' )
>
> --
> 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/e7f84d83-7e5f-40a8-b5d3-
> 19a613416da1%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhNTZw0UKWQf-NSTP7FMDAxyke1rrtz7W4rPrjv0DPRwDw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Nuke API resources?

2018-02-13 Thread Kurian O.S
nuke-pyt...@foundry.com I use this mailing list and very use full

http://www.nukepedia.com/

https://stackoverflow.com/questions/tagged/nuke



On Tue, Feb 13, 2018 at 10:45 AM, Ravi Jagannadhan  wrote:

> Hi all, this is not a Maya-Python question, but I imagine some people here
> use Nuke and its Python API. For those of you who do, are there any
> resources you'd recommend (aside from the doc page on the Foundry's site)?
> Any groups like this one?
>
> Thank you for your time,
> Ravi
> --
> Where we have strong emotions, we're liable to fool ourselves - Carl Sagan
>
> --
> 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/CADHeb2Ytkz8U4HqBSZbLqLXbiQa-
> Qzg-UiVvMTzQd-U7ZjpNhw%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhNvNK9af%2BAP%2B9tsVVg4Wtm-bRB_wm4EeHbkXGD1tz50zg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Selects only the group nodes

2016-08-29 Thread Kurian O.S
You can use set to filter duplicate's ( although its not duplicate its
because you are using all parents = True)

sel = list(set(cmds.listRelatives(cmds.ls(transforms=True), ap=True,
ni=True)))
print sel

This should give back you what you expecting

On Mon, Aug 29, 2016 at 5:56 PM, likage  wrote:

> I am trying to grab only the group nodes within the hierarchy as shown in
> the screenshot..
>
> While I use this code:
>
> sel = cmds.listRelatives(cmds.ls(transforms=True), ap=True, ni=True)
> print sel
>
> It is giving me the following results:
> [u'Group_1', u'Group_2', u'Group_2', u'Group_2', u'Group_2', u'Group_2', u
> 'Group_3', u'Group_4', u'Group_5']
>
> Though it gives me duplicated result of certain groups, is this the best
> way to approach this?
> I am using Group_ as a generic naming and hence my reluctance to use
> Group_*, in case you are wondering...
>
>
>
> 
>
> --
> 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/a70ebb57-f68c-493f-b84a-
> ba5a52334697%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhMHUtsSsn%3DddONFz5kRKyxmC95hn1BXBkMq_ka%2Bnkg8Aw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Drag and drop from Outliner into custom QTreeView

2016-07-19 Thread Kurian O.S
To Justin ;)
http://forums.autodesk.com/t5/maya-programming/the-x-maya-data-mimetype-used-for-drag-and-drop/td-p/4274294


On Tue, Jul 19, 2016 at 3:24 PM, Justin Israel 
wrote:

> I was trying to recall the discussions we had in the past about this, but
> I couldn't find anything. I don't remember what the result of my own
> experience with this was either. Does it really not register anything in
> the target widget, when you implement the dragEnterEvent() in the tree
> view? You are right that it would not be handled on the Maya Outliner side
> of things. A drag and drop operation kind of goes though this generic
> process where arbitrary mime data is delivered to the target. The target
> has to decide whether it can handle it.
>
> But if I remember correctly, the data that is provided by dragging Maya's
> own tree view items is an internal and undocumented format. It was never
> useful to determine any information about it. So you would have to just
> identify that it is a Maya drag in general and then follow Marcus's
> suggestion of looking at the current selection.
>
>
>
> On Wed, Jul 20, 2016 at 7:13 AM Marcus Ottosson 
> wrote:
>
>> I once had a go with this, but came up empty.
>>
>> I ended up with something similar to what you suggest, but rather than
>> making it a button I simply ran cmds.ls(selection=True) in the dropEvent
>> and required users to first select the items they are about to drag. Not
>> ideal, but was simple enough and works fine.
>> ​
>>
>> On 19 July 2016 at 19:49, Peter Makal  wrote:
>>
>>> Hey guys!
>>>
>>> I'm writing a plugin in which I really like to have a drag and drop
>>> feature: copy selected objects from Maya Outliner into my own
>>> *QTreeView*. I started with obvious: setDragEnabled(True),
>>> setAcceptDrops(True) and setDropIndicatorShown(True) functions for my
>>> view. Didn't work. I overwrote  canDropMimeData and dropMimeData functions
>>> for my model with simple print instructions just to see if they will
>>> fire... Nope. So after some googling I came across *MExternalDropCallback
>>> *class in Maya API but it seems to work only the other way around -
>>> drag and drop from custom widget into Maya UI.
>>>
>>> Is there any way to do this? In the end I can add a button saying
>>> something like: "Add selected objects" and just add them by using 
>>> *MSelectionList
>>> *and not drag and drop behaviour but it seems less UI/UX friendly.
>>>
>>> --
>>> 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/1b11ce11-e1cc-4e84-98a0-d2d240fd5965%40googlegroups.com
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
>>
>> --
>> *Marcus Ottosson*
>> konstrukt...@gmail.com
>>
>> --
>> 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/CAFRtmOC756cp4c0Jg1uw2vyV1%2Bk-d7jTyxghtaaaEOtBJSg3%3Dw%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/CAPGFgA2bf4t2A5%2BvRdnxTNDFzx07gwZD565DQuk4mVaAY%2BwoNw%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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 

Re: [Maya-Python] Mel to Python conversion

2016-07-06 Thread Kurian O.S
import maya.cmds as cmds
import maya.mel as mel

win = cmds.window(title = "Long Name", iconName = "Short Name", widthHeight
= (200, 55))
cmds.columnLayout(adjustableColumn = True)

fbTable = mel.eval('$tempFbValList = $gFilmbackTable')
print fbTable

cmds.optionMenu("omFilmbackMenu", label = "Film Gate")

# If you want all
#for eachItm in rfbTable:
#cmds.menuItem(label=eachItm)

for eachItm in range(0, len(fbTable), 3):
cmds.menuItem(label=eachItm)

cmds.showWindow(win)

You can use range to do the increment. And hope this helps




On Wed, Jul 6, 2016 at 9:42 AM, likage  wrote:

> Hi all, I am trying to convert the following Mel into python but was met
> with some trouble.
> Though I do not intend to implement the code, still, I would like to be
> enlighten, shedding some light as I am trying to learn / be knowledgeable
> in both Mel and Python..
>
> The following is the Mel code:
> string $window = `window -title "Long Name" -iconName "Short Name"`;
> columnLayout -adjustableColumn true;
>
>
> // this is maya's global variable of all the preset film backs
> global string $gFilmbackTable[];
>
>
> // create an option menu that will contain all the preset film backs
> optionMenu - l "Film Gate" omFilmbackMenu;
>
>
> // grab the film backs in the table and add them to the drop down menu
> for($i=0; $i < size($gFilmbackTable); $i += 3) {
> menuItem -l $gFilmbackTable[$i];
> }
>
> showWindow $window;
>
> And the following is the converted Python that I did:
> import maya.cmds as cmds
> import maya.mel as mel
>
>
> win = cmds.window(title = "Long Name", iconName = "Short Name",
> widthHeight = (200, 55))
> cmds.columnLayout(adjustableColumn = True)
>
>
> fbTable = mel.eval('global string $gFilmbackTable[]')
> # fbValues = mel.eval('$gFilmbackTable')
>
>
> cmds.optionMenu("omFilmbackMenu", label = "Film Gate")
>
>
> cmds.showWindow(win)
>
>
> First problem that I had, is grabbing the value of $gFilmbackTable. As I
> tried printing them out (fbValues), it either prompts me error saying
> - RuntimeError: Error occurred during execution of MEL script
>
> Whereas in Mel tab, it is able to print out a list of things.. Guess I
> screwed up somewhere?
>
> The second issue that I had would be converting the for statement (and
> onwards) in Mel to python. While I can think of replacing 'size' with
> 'len', but the other parameters within - $i=0 and $i += 3, how do I do so
> in Python?
>
> --
> 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/c8c039f0-dfa9-4372-abd9-9ab26453724e%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhNhgGt29sU9644vHJE88oq8_620FNq4-FTfZ0u_i0Ftng%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] News: Chris Maynard - cmiVFX

2016-06-08 Thread Kurian O.S
I got mail from cmi yesterday and it was so sad to listen this news :(...
talked to him around month back and i don't know what to say .. RIP Chris

On Wed, Jun 8, 2016 at 2:40 PM, simonp91  wrote:

> Ditto on this. He only ever wanted to help people. And helped a LOT of
> people. His passing is a tragic loss to a great many people who's lives he
> touched.
>
> Simon
>
> Sent from my iPhone
>
> On 8 Jun 2016, at 22:27, Justin Israel  wrote:
>
> For anyone that knows about cmiVFX and hasn't heard... I got a message
> about this earlier today...
>
> Chris Maynard, the owner of CMI, passed away in May at the age of 41:
>
> http://www.obitsforlife.com/obituary/1331671/Maynard-Christopher.php
>
>
> http://mackleystudios.com/blog/0006-the-progress-and-vision-of-cmivfx-and-cmiuniverse
>
> Sad that he was so young. He was a really driven and passionate guy. If
> you ever spoke to him (I did a couple different projects with him in the
> past), you would know instantly how much he cared about our industry and
> making an impact... even if he did sound a bit nuts sometimes. You could
> tell he always wanted to do "next level stuff".
>
> Justin
>
> --
> 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/CAPGFgA1KhJfG%2BZepMowZ%3D_xBwnopibzPmjEXoQfT%2BohwMQDkYg%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/CB0F5A61-5D89-40E0-8DAF-F1E77C11FCA2%40gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhNHK80tW3vtBXqhPnc455Cu-4O6Tzyv8iOW9OCsjN_5dg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Re: Python Modules in System Environment Variable ?

2016-04-04 Thread Kurian O.S
On Mon, Apr 4, 2016 at 4:43 PM, Crest Christopher <
crestchristop...@gmail.com> wrote:

> Justin can you make a video of your Maya.env including the Maya.env,
> including PYTHONPATH as well your userSetup file and what is within the
> userSetup file ?


Are you serious ?


-- 
--:: Kurian ::--

-- 
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/CANEMyhNrVMrHEgLTSraviUmHDDn%3DmSO4%2BVfmDyOiKk%2BePGvLmA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] How to normalize similarity measurements (lch, wup, path, res, lin, jcn) between [0,1]?

2016-03-02 Thread Kurian O.S
This group mainly for maya based python questions  not really for nltk kind
of stuff.  But some one maybe will have some idea. But the real question is
how you using this group as your ID ?

from:'AM' via Python Programming for Autodesk Maya <
python_inside_maya@googlegroups.com>

How it become your from address ?

On Wed, Mar 2, 2016 at 10:46 AM, 'AM' via Python Programming for Autodesk
Maya  wrote:

>
> Could you see what is stack overflow answered below?, I couldn't apply in
> my code, please if you could to applying on my example I would be thankful.
>  I don't know what is ( words w, u) and what the difference between it
> and M(w,w).
> If I assume that M(w,w) is (wn.res_similarity(s1[0], s2[0], brown_ic)),
>  then what is MN (w, u) really I couldn't understand.
>
> thanks.
>
>
> How to normalize a single measure
>>>
>>> Let's consider a single arbitrary similarity measure M and take an
>>> arbitrary word w.
>>>
>>> Define m = M(w,w). Then m takes maximum possible value of M.
>>>
>>> Let's define MN as a normalized measure M.
>>>
>>> For any two words w, u you can compute MN(w, u) = M(w, u) / m.
>>>
>>> It's easy to see that if M takes non-negative values, then MN takes
>>> values in [0, 1].
>>> How to normalize a measure combined from many measures
>>>
>>> In order to compute your own defined measure F combined of k different
>>> measures m_1, m_2, ..., m_k first normalize independently each m_i using
>>> above method and then define:
>>>
>>> alpha_1, alpha_2, ..., alpha_k
>>>
>>> such that alpha_i denotes the weight of i-th measure.
>>>
>>> All alphas must sum up to 1, i.e:
>>>
>>> alpha_1 + alpha_2 + ... + alpha_k = 1
>>>
>>> Then to compute your own measure for w, u you do:
>>>
>>> F(w, u) = alpha_1 * m_1(w, u) + alpha_2 * m_2(w, u) + ... + alpha_k * 
>>> m_k(w, u)
>>>
>>> It's clear that F takes values in [0,1]
>>>
>> --
> 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/344f9795-5444-45c8-9e68-7b7514c5b57b%40googlegroups.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhMER0_%2Bvqn_58V-EVK3xiGfZgFxFgNjMTgs_2K8v3Bu2w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] How to normalize similarity measurements (lch, wup, path, res, lin, jcn) between [0,1]?

2016-03-02 Thread Kurian O.S
from: 'AM' via Python Programming for Autodesk Maya <
python_inside_maya@googlegroups.com>
reply-to: python_inside_maya@googlegroups.com
to: Python Programming for Autodesk Maya <
python_inside_maya@googlegroups.com>
date: Wed, Mar 2, 2016 at 7:47 AM

Actually what's going on ?

On Wed, Mar 2, 2016 at 8:16 AM, 'AM' via Python Programming for Autodesk
Maya  wrote:

> Yes, but I didn't find any response.
>
>
>> --
> 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/da1be2db-2448-4202-9c6f-b2238504506a%40googlegroups.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhMLA9VPNK7JoZ%3DuaZwpkFdmYePfD6-nj1SFivx3Qzyydg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] rotate difference in Mel and python

2016-02-25 Thread Kurian O.S
rotate take a list


pm.rotate([0,45,0], r=1, os=1)

On Thu, Feb 25, 2016 at 1:19 PM, Todd Widup  wrote:

> mel and maya.cmds
>
> rotate -r -os 0 45 0;
>
> works different than
>
> pymel
>
> pm.rotate(0,45,0,r=1,os=1)
>
> any ideas why and what is going on with it?
>
>
> --
> Todd Widup
> Creature TD / Technical Artist
> t...@toddwidup.com
> todd.wi...@gmail.com
> www.toddwidup.com
>
> --
> 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/CABBPk34Ewu9_i_cTd48jB2GGMm11XNYjhOYmJAm-5o0SPn6-sQ%40mail.gmail.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhPSoshxn4_oC_mYr-hJ4G2aR4xBcqRruhCNdA4-4ZK_CQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] mayapy.exe issue

2015-12-06 Thread Kurian O.S
PysideCode.MyTool.qtshim is not != PysideCode.myTool.qtshim :)

On Sun, Dec 6, 2015 at 10:46 PM, David Moulder 
wrote:

> You're a folder to deep when setting the python path.  Hope that helps.
>
> On Mon, 7 Dec 2015 06:40 Padraig Ó Cuínn 
> wrote:
>
>>
>>
>> PysideCode
>> myTool
>> myToolUI
>> __init__.py
>> myToolUI.py
>> MyToolCode
>> __init__.py
>> __init__.py
>> qtshim.py
>> mayautils.py
>> __init__.py
>>
>>
>> Hi everyone above is my current working directory, as you can see they
>> all have their __init__.py files and can be easily accessed from code.
>> So what is my problem well then...
>>
>> I cannot get to qtshim.py from mayapy.exe I am using fully qualified
>> naming
>>
>> from PysideCode.myTool.qtshim import QtGui, QtCore, Signal  <<< Yes from
>> Robs Book :)
>>
>> importError : No module names PysideCode.MyTool.qtshim
>>
>> here is the weird part >>> script editor accepts it and so does Pycharm,
>>
>> PYTHONPATH = C:\Users\OCuinn\Dropbox\Maya Scripts\Python Code\PysideCode
>>
>> its in sys.path and in windows environment variables
>>
>> however > set PYTHONPATH=%PYTHONPATH%;C:\Users\OCuinn\Dropbox\Maya
>> Scripts\Python Code\PysideCode goes through but comes out False when
>> checked every time.
>>
>>
>> EXPERTS I NEED YOUR HELP!
>>
>> Padraig
>>
>> --
>> 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/786e3fb5-4e3c-49f5-8ca1-52a4438825ea%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/CABD4PkRqoHwKVKrcWQ34F1Lci%3DZgdui4tphUyD-RS_6W-HDntA%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhPAFm4vcM-sNmw6DZm8fe6raq4uFnk%3DeVp1qSH3OetBbQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] lambda in a loop

2015-11-09 Thread Kurian O.S
First you had syntax issues and I really don't like lambda in this case
used partial

import maya.cmds as mc
from functools import partial
def blah(value, *args):
print "I was given:", value

mc.window(w=500, h=500);
mc.columnLayout();
for i in range(0, 5):
mc.button(l="Touch!"+str(i), c=partial(blah, 10*i));
mc.showWindow();

On Mon, Nov 9, 2015 at 4:53 PM, ynedelin  wrote:

> hey guys
> I have this little code.
>
>
>
>
>
>
>
>
>
>
> *import maya.cmds as mcdef blah(value):print "I was given:",
> valuemc.window(w=500, h=500)mc.columnLayout()for i in range(0, 5):
> mc.button(l="Touch!"+str(i), c=lambda x:blah(10*i))mc.showWindow()*
>
> if you run this it will create a window with 5 buttons and they all will
> have unique names, but they all will pass the same value to blah function,
> the last value of the loop.
>
> why is that and how to fix it?
>
> what I want to see is each button returns 10* by index it was created in.
>
> Thanks
>
> Yury
>
>
> --
> 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/9e7b0efc-3d79-4719-bbb6-243a33d9b0c6%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhN_C7jUBntdSX39r38bL6bV6S-cPE9T8c9x_JFhOgdSqw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Plugin hanging with change to currentTime

2015-10-31 Thread Kurian O.S
Actually autodesk started adding "features" without any documentation or
any release note which will affect too much at user end. We faced huge
issue with the new feature called "hideinoutliner". Seriously i will kill
that guy who added this in maya if i saw him. Its okay hideinoutliner but
why you hiding from every where ? like graph editor node editor hypergraph
every where.

On Sat, Oct 31, 2015 at 1:12 PM, Justin Israel 
wrote:

>
>
> On Sun, Nov 1, 2015 at 12:21 AM Paul Molodowitch 
> wrote:
>
>> Hey there - we had a similar issue with a python plugin in 2016, and it
>> turned out to be related to the new multi threaded graph evaluation and the
>> python GIL. Try turning that off in the prefs and see if it works.
>>
>> If that is the cause, you can try a fix suggested by a fine fellow at
>> autodesk: set the environment variable $MAYA_RELEASE_PYTHON_GIL to 1 before
>> launching maya, and hopefully it works.
>>
>> According to autodesk support, setting this on has no adverse side
>> effects, but I'm leery - if so, why not have it on by default? That said,
>> it's worked for us beautifully so far, without any noticeable issues...
>>
> Was there any extra documentation on the MAYA_RELEASE_PYTHON_GIL setting?
> I'm curious to know details of what it affects.
>
>
>>
>> On Sat, Oct 31, 2015, 3:36 AM Bob Loblaw 
>> wrote:
>>
>>> Interesting but inconclusive. Using the Legacy Viewport, the loop makes
>>> it through two calls to cmds.currentTime and then locks up on the third. I
>>> saw similar behavior when trying to narrow down the issue. The second and
>>> third time I try this experiment though, with the Legacy Viewport, the loop
>>> locks up immediately. Hm
>>>
>>> It's surprising that the Viewport choice has any effect.
>>>
>>> Thanks for the suggestion.
>>>
>>> Bob
>>>
>>>
>>>
>>>
>>>
>>>
>>> On Fri, Oct 30, 2015 at 6:46 AM, Mark Jackson  wrote:
>>>
 Can I ask if you're not in 2016 to turn off VP2 and try again. I have a
 similar issue where running a plugin that snaps transforms over time hangs
 Maya but ONLY in V2, in legacy VP all is fine.

 On 29 October 2015 at 17:03, Bob Loblaw 
 wrote:

> Was anyone able to reproduce this issue? It's a blocker...
>
> Thanks,
> Bob
>
>
>
>
> --
> 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/CAN0Hdevj6FEA53UL9YyKcctV_7QrUpLr-RK0ZtqMuo2OZZXy4A%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



 --
 -
 Mark Jackson
 CEO / Technical Director
 red9consultancy.com

 --
 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/CAGQH2FEyPZrr6qGQ%2BjL4MEVz9m-CZ1Yq15%3DSva67mLic8d9c_w%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/CAN0HdeuD5Y8Gb677%3DHm14K0-LZ9kSdu8hitq0zPjSLRBVVS6sA%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
>> 

Re: [Maya-Python] Search and Replace with Python

2015-09-18 Thread Kurian O.S
import maya.mel as mel
newName = "L_arm"
mel.eval('searchReplaceNames "pSphere1" "%s" "all"' % newName)


On Fri, Sep 18, 2015 at 12:38 PM, Félix CT  wrote:

> searchReplaceNames "side_limb" "L_arm" "all"





-- 
--:: Kurian ::--

-- 
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/CANEMyhOnWsMyLt%2BFWkTrL1Yb71wDxyCcBS3oL%2BGbYB%3Dsmga5bg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Command to run script ?

2015-09-13 Thread Kurian O.S
put it in /usr/maya20*/scripts then craOffsetKeys() in maya

On Sun, Sep 13, 2015 at 9:38 PM, yury nedelin  wrote:

> are  you trying to run mel script in python or just run it as it it in MEL
> ?
> Yury
>
> On Sun, Sep 13, 2015 at 11:32 PM, Christopher.  > wrote:
>
>> I have a MEL Maya script called craOffsetKeys; I can't find how to run
>> the script.  I've searched within the script can't find the correct command
>> ?
>>
>> --
>> 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/aec6f9f3-9aeb-4995-93f1-48a1e2aa68a9%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/CACqGSciYQF-9fban9GzUwNwOZBGb7KF5f3%2BK4KzW_dksaU62yg%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhMw4gk6Qd-XrvjQ1_nbgkJhOZOcEz0vZaR7%2BaC-PqZJGA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] takes at least 3 arguments (2 given)

2015-09-10 Thread Kurian O.S
http://pastebin.com/y0nBAy9W Try this

If you want to pass a argument to another function you can use partial or
lambda, But I will stay with partial :)

On Thu, Sep 10, 2015 at 5:52 PM, Félix CT  wrote:

> Hello this is my first post, I have troubles with this small script, if
> anyone could help me, that would be great.
>
> The script:
>
> import maya.cmds as cmds
>
> def myName( self, nombre, apellido, *args ):
> print ( nombre + "_" + apellido )
>
> def myWin():
> cmds.window()
> cmds.columnLayout()
> cmds.button( label= 'Press', c= myName( nombre='Pepe',
> apellido='Grillo' ) )
> cmds.showWindow()
>
> myWin()
>
> This is the error:
>
> #TypeError: myName() takes at least 3 arguments (2 given)
>
>
> Saludos!!
>
> --
> 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/b58aa1c8-013b-48a8-8499-01a1e2ee9be1%40googlegroups.com
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhOLN3UdX8%2BPQxCXi6_WXj%3DvEC8yEQJpQR0-5b8jQ66wyA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[Maya-Python] Re: Layer Editor With PyQT

2015-09-09 Thread Kurian O.S
I think i will give up on this :)

On Tuesday, September 8, 2015, Jefri Yeh <r4inm4...@gmail.com> wrote:

> Yeah too bad that after moving it to our custom UI the layer editor
> doesn't even work anymore. Seems that it's not designed to work that way.
> The worst case is you need to look at layerEditor.mel and replicate the
> functionality...
>
> On Wed, Sep 9, 2015 at 1:24 AM, Kurian O.S <kuria...@gmail.com
> <javascript:_e(%7B%7D,'cvml','kuria...@gmail.com');>> wrote:
>
>> I was actually looking for a solution similar to outliner like I can have
>> multiple instance in same maya session.
>>
>> On Tue, Sep 8, 2015 at 10:22 AM, yury nedelin <ynede...@gmail.com
>> <javascript:_e(%7B%7D,'cvml','ynede...@gmail.com');>> wrote:
>>
>>> All LayerEditor.Mel updates take place after Maya is restarted.
>>> On Sep 8, 2015 10:15 AM, "Kurian O.S" <kuria...@gmail.com
>>> <javascript:_e(%7B%7D,'cvml','kuria...@gmail.com');>> wrote:
>>>
>>>> This works, but the issue is once if you source the layerEditor.mel
>>>> then we won't get any update on the wrapped one :(
>>>>
>>>> On Tue, Sep 8, 2015 at 9:58 AM, Kurian O.S <kuria...@gmail.com
>>>> <javascript:_e(%7B%7D,'cvml','kuria...@gmail.com');>> wrote:
>>>>
>>>>> Perfect , thanks Jefri
>>>>>
>>>>> On Tue, Sep 8, 2015 at 7:14 AM, Jefri Yeh <r4inm4...@gmail.com
>>>>> <javascript:_e(%7B%7D,'cvml','r4inm4...@gmail.com');>> wrote:
>>>>>
>>>>>> After abit of searching, it seems that Maya creates the layer editor
>>>>>> by sourcing "layerEditor.mel" in the script directory, and the script can
>>>>>> only create single instance of layerEditor called 
>>>>>> "DisplayLayerUITabLayout"
>>>>>> (repeated sourcing  layerEditor.mel will fail). Thus if we use this 
>>>>>> unique
>>>>>> name and convert it to qt widget, we can then embed it into our own 
>>>>>> widget.
>>>>>> I've pasted the snippets here:
>>>>>>
>>>>>> https://gist.github.com/r4inm4ker/dfd7eb0ce2915d004367
>>>>>>
>>>>>> after that don't forget to source layerEditor.mel again to recreate
>>>>>> the default layerEditor widget below channelBox...
>>>>>>
>>>>>>
>>>>>> ---Jefri
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Tue, Sep 8, 2015 at 1:08 AM, Kurian O.S <kuria...@gmail.com
>>>>>> <javascript:_e(%7B%7D,'cvml','kuria...@gmail.com');>> wrote:
>>>>>>
>>>>>>> Hey Guys,
>>>>>>>
>>>>>>> Anyone got any luck to embed maya layer editor inside a pyqt dialog
>>>>>>> ?. i was able to embed some of the other ui items like panel's outliner
>>>>>>> etc.. but layer editor I never got any idea. Anyone have any hints ?
>>>>>>>
>>>>>>> Thanks
>>>>>>>
>>>>>>> --
>>>>>>> --:: Kurian ::--
>>>>>>>
>>>>>>> --
>>>>>>> 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
>>>>>>> <javascript:_e(%7B%7D,'cvml','python_inside_maya%2bunsubscr...@googlegroups.com');>
>>>>>>> .
>>>>>>> To view this discussion on the web visit
>>>>>>> https://groups.google.com/d/msgid/python_inside_maya/CANEMyhOmwjcxH5pa9_x3aqjY6eq8E0AVVms6XZ7ASPEkxbQRWg%40mail.gmail.com
>>>>>>> <https://groups.google.com/d/msgid/python_inside_maya/CANEMyhOmwjcxH5pa9_x3aqjY6eq8E0AVVms6XZ7ASPEkxbQRWg%40mail.gmail.com?utm_medium=email_source=footer>
>>>>>>> .
>>>>>>> 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 an

Re: [Maya-Python] Re: Animated Gif Widget triggered during mouse Hover Over

2015-09-09 Thread Kurian O.S
http://pyqt.sourceforge.net/Docs/PyQt4/qmovie.html#started did you check
the default signals from QMovie ?

On Wed, Sep 9, 2015 at 3:17 PM, Antonio Govela  wrote:

> Sorry.. it was late and was getting kinda lost. So I managed to clean the
>>> code and actually trigger an animated gif widget using events. >> widgets can be added with classes and respond independently to the 'hover
>>> over and leave' mouse tracking.
>>
>>
> Here's the code: http://pastebin.com/C43HwDgi fully functional...
>
> My question would then be: is using the event filter better than trying to
> use signals or vice versa, and how can this be done using signals to
> trigger events like start, stop and reset.
>
> Thanks!
>
> Antonio
>
>
>
> --
> 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/4115dda0-d481-47c7-bbdc-0a016d70e121%40googlegroups.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhOszTu4eHEH-WxAT_qT7KvyG8tT7S0tuaEVNq5_izhX-w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Layer Editor With PyQT

2015-09-08 Thread Kurian O.S
I was actually looking for a solution similar to outliner like I can have
multiple instance in same maya session.

On Tue, Sep 8, 2015 at 10:22 AM, yury nedelin <ynede...@gmail.com> wrote:

> All LayerEditor.Mel updates take place after Maya is restarted.
> On Sep 8, 2015 10:15 AM, "Kurian O.S" <kuria...@gmail.com> wrote:
>
>> This works, but the issue is once if you source the layerEditor.mel then
>> we won't get any update on the wrapped one :(
>>
>> On Tue, Sep 8, 2015 at 9:58 AM, Kurian O.S <kuria...@gmail.com> wrote:
>>
>>> Perfect , thanks Jefri
>>>
>>> On Tue, Sep 8, 2015 at 7:14 AM, Jefri Yeh <r4inm4...@gmail.com> wrote:
>>>
>>>> After abit of searching, it seems that Maya creates the layer editor by
>>>> sourcing "layerEditor.mel" in the script directory, and the script can only
>>>> create single instance of layerEditor called "DisplayLayerUITabLayout"
>>>> (repeated sourcing  layerEditor.mel will fail). Thus if we use this unique
>>>> name and convert it to qt widget, we can then embed it into our own widget.
>>>> I've pasted the snippets here:
>>>>
>>>> https://gist.github.com/r4inm4ker/dfd7eb0ce2915d004367
>>>>
>>>> after that don't forget to source layerEditor.mel again to recreate the
>>>> default layerEditor widget below channelBox...
>>>>
>>>>
>>>> ---Jefri
>>>>
>>>>
>>>>
>>>> On Tue, Sep 8, 2015 at 1:08 AM, Kurian O.S <kuria...@gmail.com> wrote:
>>>>
>>>>> Hey Guys,
>>>>>
>>>>> Anyone got any luck to embed maya layer editor inside a pyqt dialog ?.
>>>>> i was able to embed some of the other ui items like panel's outliner etc..
>>>>> but layer editor I never got any idea. Anyone have any hints ?
>>>>>
>>>>> Thanks
>>>>>
>>>>> --
>>>>> --:: Kurian ::--
>>>>>
>>>>> --
>>>>> 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/CANEMyhOmwjcxH5pa9_x3aqjY6eq8E0AVVms6XZ7ASPEkxbQRWg%40mail.gmail.com
>>>>> <https://groups.google.com/d/msgid/python_inside_maya/CANEMyhOmwjcxH5pa9_x3aqjY6eq8E0AVVms6XZ7ASPEkxbQRWg%40mail.gmail.com?utm_medium=email_source=footer>
>>>>> .
>>>>> 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/CACdyi7qcbdjQmVsnxdOWmPWy7NgeTENXihYLeTUiYGrRe9QaYA%40mail.gmail.com
>>>> <https://groups.google.com/d/msgid/python_inside_maya/CACdyi7qcbdjQmVsnxdOWmPWy7NgeTENXihYLeTUiYGrRe9QaYA%40mail.gmail.com?utm_medium=email_source=footer>
>>>> .
>>>> For more options, visit https://groups.google.com/d/optout.
>>>>
>>>
>>>
>>>
>>> --
>>> --:: Kurian ::--
>>>
>>
>>
>>
>> --
>> --:: Kurian ::--
>>
>> --
>> 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/CANEMyhME6oHEdNaBF4ezTwqMj%2BGr1i9FO%2BX%3D%3D_2ms9XzOpJu_w%40mail.gmail.com
>> <https://groups.google.com/d/msgid/python_inside_maya/CANEMyhME6oHEdNaBF4ezTwqMj%2BGr1i9FO%2BX%3D%3D_2ms9XzOpJu_w%40mail.gmail.com?utm_medium=email_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
> --
> You received this message because you are subscribed to the Google Groups
> 

Re: [Maya-Python] Layer Editor With PyQT

2015-09-08 Thread Kurian O.S
Perfect , thanks Jefri

On Tue, Sep 8, 2015 at 7:14 AM, Jefri Yeh <r4inm4...@gmail.com> wrote:

> After abit of searching, it seems that Maya creates the layer editor by
> sourcing "layerEditor.mel" in the script directory, and the script can only
> create single instance of layerEditor called "DisplayLayerUITabLayout"
> (repeated sourcing  layerEditor.mel will fail). Thus if we use this unique
> name and convert it to qt widget, we can then embed it into our own widget.
> I've pasted the snippets here:
>
> https://gist.github.com/r4inm4ker/dfd7eb0ce2915d004367
>
> after that don't forget to source layerEditor.mel again to recreate the
> default layerEditor widget below channelBox...
>
>
> ---Jefri
>
>
>
> On Tue, Sep 8, 2015 at 1:08 AM, Kurian O.S <kuria...@gmail.com> wrote:
>
>> Hey Guys,
>>
>> Anyone got any luck to embed maya layer editor inside a pyqt dialog ?. i
>> was able to embed some of the other ui items like panel's outliner etc..
>> but layer editor I never got any idea. Anyone have any hints ?
>>
>> Thanks
>>
>> --
>> --:: Kurian ::--
>>
>> --
>> 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/CANEMyhOmwjcxH5pa9_x3aqjY6eq8E0AVVms6XZ7ASPEkxbQRWg%40mail.gmail.com
>> <https://groups.google.com/d/msgid/python_inside_maya/CANEMyhOmwjcxH5pa9_x3aqjY6eq8E0AVVms6XZ7ASPEkxbQRWg%40mail.gmail.com?utm_medium=email_source=footer>
>> .
>> 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/CACdyi7qcbdjQmVsnxdOWmPWy7NgeTENXihYLeTUiYGrRe9QaYA%40mail.gmail.com
> <https://groups.google.com/d/msgid/python_inside_maya/CACdyi7qcbdjQmVsnxdOWmPWy7NgeTENXihYLeTUiYGrRe9QaYA%40mail.gmail.com?utm_medium=email_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhMQ1m_1xEC_o8z0nU4U_EwHkVNiBojSj-NzZViVXus2oA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Layer Editor With PyQT

2015-09-08 Thread Kurian O.S
This works, but the issue is once if you source the layerEditor.mel then we
won't get any update on the wrapped one :(

On Tue, Sep 8, 2015 at 9:58 AM, Kurian O.S <kuria...@gmail.com> wrote:

> Perfect , thanks Jefri
>
> On Tue, Sep 8, 2015 at 7:14 AM, Jefri Yeh <r4inm4...@gmail.com> wrote:
>
>> After abit of searching, it seems that Maya creates the layer editor by
>> sourcing "layerEditor.mel" in the script directory, and the script can only
>> create single instance of layerEditor called "DisplayLayerUITabLayout"
>> (repeated sourcing  layerEditor.mel will fail). Thus if we use this unique
>> name and convert it to qt widget, we can then embed it into our own widget.
>> I've pasted the snippets here:
>>
>> https://gist.github.com/r4inm4ker/dfd7eb0ce2915d004367
>>
>> after that don't forget to source layerEditor.mel again to recreate the
>> default layerEditor widget below channelBox...
>>
>>
>> ---Jefri
>>
>>
>>
>> On Tue, Sep 8, 2015 at 1:08 AM, Kurian O.S <kuria...@gmail.com> wrote:
>>
>>> Hey Guys,
>>>
>>> Anyone got any luck to embed maya layer editor inside a pyqt dialog ?. i
>>> was able to embed some of the other ui items like panel's outliner etc..
>>> but layer editor I never got any idea. Anyone have any hints ?
>>>
>>> Thanks
>>>
>>> --
>>> --:: Kurian ::--
>>>
>>> --
>>> 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/CANEMyhOmwjcxH5pa9_x3aqjY6eq8E0AVVms6XZ7ASPEkxbQRWg%40mail.gmail.com
>>> <https://groups.google.com/d/msgid/python_inside_maya/CANEMyhOmwjcxH5pa9_x3aqjY6eq8E0AVVms6XZ7ASPEkxbQRWg%40mail.gmail.com?utm_medium=email_source=footer>
>>> .
>>> 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/CACdyi7qcbdjQmVsnxdOWmPWy7NgeTENXihYLeTUiYGrRe9QaYA%40mail.gmail.com
>> <https://groups.google.com/d/msgid/python_inside_maya/CACdyi7qcbdjQmVsnxdOWmPWy7NgeTENXihYLeTUiYGrRe9QaYA%40mail.gmail.com?utm_medium=email_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> --:: Kurian ::--
>



-- 
--:: Kurian ::--

-- 
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/CANEMyhME6oHEdNaBF4ezTwqMj%2BGr1i9FO%2BX%3D%3D_2ms9XzOpJu_w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[Maya-Python] Layer Editor With PyQT

2015-09-07 Thread Kurian O.S
Hey Guys,

Anyone got any luck to embed maya layer editor inside a pyqt dialog ?. i
was able to embed some of the other ui items like panel's outliner etc..
but layer editor I never got any idea. Anyone have any hints ?

Thanks

-- 
--:: Kurian ::--

-- 
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/CANEMyhOmwjcxH5pa9_x3aqjY6eq8E0AVVms6XZ7ASPEkxbQRWg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Python in Maya - script for applying a material?

2015-08-14 Thread Kurian O.S
https://gist.github.com/achayan/e8f14f6b88a34e731351


On Fri, Aug 14, 2015 at 8:58 AM, f.michal f.mic...@gmail.com wrote:

 Pardon MEL, but that's what I have now :)

 global proc mfNewShaderForSL()
 {
 string $sl[]= `ls -sl -l`;
 for($o in $sl)
 {
 string $SG = `sets -renderable true -noSurfaceShader true -empty`;
 string $shader = `shadingNode -asShader lambert`;
 connectAttr -f ($shader + .outColor) ($SG + .surfaceShader);
 select $o;
 //this is what you need !
 sets -e -forceElement $SG;
 }
 }

 W dniu 2015-08-14 o 17:55, Kate Sendall pisze:

 Hi! I'm trying to assign a material to an object in the script editor
 using python. I've managed to assign the object to maya_material_x, but
 can't seem to find a way to make it one of the presets! Help would be
 greatly appreciated. :)

 def applyMaterial():
 myShader = mc.shadingNode('mia_material_x', asShader=True)
 mc.select('myStep*')
 mc.hyperShade(assign = myShader)


 Simple really, don't know why I can't figure it out. XD

 Kate
 --
 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/25b05c27-2e35-4bec-abc5-f4c19dc2a40b%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/25b05c27-2e35-4bec-abc5-f4c19dc2a40b%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 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/55CE1018.8090001%40gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/55CE1018.8090001%40gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhNG%2BgYr3ATxJuniNN3dzf%3DPeevG-k-VJw7Ea1bnrvgebQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Re: Combined Texture Channel

2015-08-11 Thread Kurian O.S
Thanks :)

On Fri, Aug 7, 2015 at 12:54 PM, Ahmet Levent Tasel leventta...@gmail.com
wrote:

 try this :)

 import maya.cmds as cmds


 shaderNode = 'shaderName'
 if cmds.objExists(shaderNode):
 materialInfoNode = cmds.ls(cmds.listConnections(shaderNode), typ=
 'materialInfo')[-1]
 cmds.connectAttr('%s.message' % shaderNode, '%s.texture' %
 materialInfoNode, nextAvailable=True)





 On Thursday, August 6, 2015 at 6:25:45 PM UTC-7, Kurian wrote:

 Hey,

 Anyone tried to change a shader texture channel ( Hardware Texturing)
 contained textures through python ?. I tried but no luck, AE never get
 updated. Any hints ?

 Thanks

 --
 --:: Kurian ::--

 --
 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/29ac65d2-9012-47d6-b958-b25b5729e60a%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/29ac65d2-9012-47d6-b958-b25b5729e60a%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhNgmtWhtkvp3qo2Mc6__4dfAMiAb5doDSJzuLEiHGwAgw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Procedural programming stairs. Have a RuntimeError saying my object is not found?

2015-08-10 Thread Kurian O.S
First thing don't use your style formatting to post code, its totally not
readable :(. Can you put your code in pastebin or some other
https://gist.github.com/ . It will much better.

On Mon, Aug 10, 2015 at 9:41 AM, Kate Sendall 
kate.alicia.send...@googlemail.com wrote:

 Here's my code so far. Ignore some of the code that doesn't seem to 'do'
 anything. It's a work in progress! The problem lies in a complete piece of
 code/script that *should *run. I'm putting blue lines in where I think
 the issue might be:

 *1.import maya.cmds as mc*
 *   import pymel.core.datatypes as pym   *

 *   #clearing up the scene *

 *   mc.select(all=True)*
 *   mc.delete()*

 *   #defining my User Interface window*
 *10.*
 *   def createSUI():*

 *   #checking to see if my window exists and deleting*
 *   if mc.window('myWin', exists=True):*
 *   mc.deleteUI('myWin')*

 *   #creating window and setting layout*
 *   windowID = mc.window('myWin', rtf=True, t=Can't Stop Stairing
 - Stair Maker 2015, backgroundColor=(0.2, 0.2, 0.2), mnb=False, mxb=False,
 sizeable=True)*
 *   mc.columnLayout(w=400, h=600)*
 *20.*
 *   #placing banner image*
 *   imagePath = mc.internalVar(userPrefDir=True)
 +'icons/stairImage.png'*
 *   mc.image(image=imagePath)*
 *   mc.separator(h=5)*

 *   #creating my physical in-window sliders*

 *   mc.intSliderGrp('stepWidthSlider', l = 'Step Width', v=20,
 min=1, max=40, field=True)*
 *   mc.separator(h=5)*
 *30.   mc.floatSliderGrp('stepHeightSlider', l = 'Step Height', v=4.2,
 min=0.5, max=8.0, field=True)*
 *   mc.separator(h=5)*
 *   mc.floatSliderGrp('stepDepthSlider', l = 'Step Depth', v=5.2,
 min=0.5, max=10, field=True)*
 *   mc.separator(h=5)*
 *   mc.intSliderGrp('numSteps', l = 'Number of Steps', v=50,
 min=2, max=100, field=True)*
 *   mc.separator(h=5)*

 *   #creating my physical in-window button*

 *   mc.button(l= 'Make Step', backgroundColor=(0.25, 0.25, 0.25),
 w=400, h=50, c = 'myStep()')*
 *40.  mc.separator(h=5)*
 *   mc.button(l= 'Make Spiral Stairs', backgroundColor=(0.3, 0.3,
 0.3), w=400, h=50, c='makeSpiralStairs()')*
 *   mc.separator(h=5)*
 *   mc.button(l= 'Make Straight Stairs', backgroundColor=(0.35,
 0.35, 0.35), w=400, h=50, c='makeStraightStairs()')*
 *   mc.separator(h=5)*
 *   mc.button(l= 'Change Stair Material', backgroundColor=(0.4,
 0.4, 0.4), w=400, h=50, c='applyMaterial()')*
 *   mc.separator(h=5)*
 *   mc.button(l= 'Delete All', backgroundColor=(0.45, 0.45, 0.45),
 w=400, h=50, c='deleteStairs()')*
 *   mc.showWindow('myWin')*

 *50.#fetching data from User Interface sliders*

 *   def myStep():*
 *   mc.polyCube(w = myStepWidth(), h = myStepHeight(), d =
 myStepDepth(), n = 'myStep')***

 *   def myStepDepth():*
 *   return mc.floatSliderGrp('stepDepthSlider', q = True, value =
 True) ***

 *   def myStepHeight():*
 *   return mc.floatSliderGrp('stepHeightSlider', q = True, value =
 True)*
 *60.*
 *   def myStepWidth():*
 *   return mc.intSliderGrp('stepWidthSlider', q = True, value =
 True)*

 *   def numOfMySteps():*
 *   return mc.intSliderGrp('numSteps', q = True, value = True)*

 *   #calculating rotate integer for Spiral Stairs from step dimension
 slider values  *

 *   def rotationRadian():*
 *70.   return
 pym.atan((myStepDepth()-(0.15*myStepDepth()))/myStepWidth()) *
 *   print rotationRadian()*

 *   def rotationFactor():*
 *   return pym.degrees(rotationRadian())*
 *   print rotationFactor()  *


 *   def makeSpiralStairs():*
 *   i=0*
 *80.   myStep()*
 *   while i  80:*
 *   mc.duplicate()*
 *   mc.move(0, myStepHeight(), 0, relative=True)*
 *   mc.rotate(0, rotationFactor(), 0, relative=True) *
 **
 *   i+=1*


 *   def makeStraightStairs():*
 *   myStep()*
 *90.   mc.duplicate (rr = True)*
 *   mc.move (0, 0.8*myStepHeight(), -0.8*myStepDepth(), relative =
 True) ***
 *   for i in range (numOfMySteps()):*
 *   #Duplicates the step again using the previous transform*
 *   mc.duplicate (rr = True, st = True)*


 *   def applyMaterial():*
 *   myShader = mc.shadingNode('mia_material_x', asShader=True)*
 *   mc.select('myCube*')*
 *100. mc.hyperShade(assign = myShader) *


 *   def deleteStairs():*
 *   mc.select(all=True)*
 *   mc.delete()   *



 *   createSUI()*
 110.

 The error code is exactly: #Error: RuntimeError: file maya console line
 56: Object 'stepDepthSlider' not found. I don't know what could be wrong?
 The 

Re: [Maya-Python] Register specific node type created

2015-08-06 Thread Kurian O.S
MCallbackId MDGMessage::addNodeAddedCallback ( MMessage::MNodeFunction func,
const MString  nodeType = dependNode,
void * clientData = NULL,
MStatus * ReturnStatus = NULL
)

Parameters:
[in] nodeType Type of node that will trigger the callback
[in] clientData User defined data passed to the callback function
[out] ReturnStatus status code


There is a nodeType argument so that will help you to get what you trying.

On Thu, Aug 6, 2015 at 3:02 PM, Ravi Jagannadhan enr...@gmail.com wrote:

 Filter in the callback for your specific node type?

 On Thu, Aug 6, 2015 at 3:00 PM, Arvid Schneider arvidschnei...@gmail.com
 wrote:

 How would I create a callback that fires when a specific node type is
 created?
 I know about: MDGMessage.addNodeAddedCallback( function )
 but that registers any node created. I want to limit that.
 Someone an idea?
 Arvid

 --
 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/62af34c5-03e1-4064-86c3-76e11df510b9%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/62af34c5-03e1-4064-86c3-76e11df510b9%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 Where we have strong emotions, we're liable to fool ourselves - Carl Sagan

 --
 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/CADHeb2azw6SZ7_asi6i7Le%2BD-7DyhfstwR2mbTatp4B1L%3D3Y%2BA%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CADHeb2azw6SZ7_asi6i7Le%2BD-7DyhfstwR2mbTatp4B1L%3D3Y%2BA%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhOWQCCT2R2eBaHptjEwGgcYtsN0fkEdWYzGjxjVmner-w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Register specific node type created

2015-08-06 Thread Kurian O.S
def testFooMain(*args, **kwargs):
print Foo

MDGMessage.addNodeAddedCallback(testFooMain, directionalLight)


//Foo

On Thu, Aug 6, 2015 at 3:07 PM, Arvid Schneider arvidschnei...@gmail.com
wrote:

 Thats exactly what I did. I get an error, TypeError:
 MDGMessage_addNodeAddedCallback() takes no keyword arguments //

 On 6 August 2015 at 23:05, Kurian O.S kuria...@gmail.com wrote:


 MCallbackId MDGMessage::addNodeAddedCallback ( MMessage::MNodeFunction
 func,
 const MString  nodeType = dependNode,
 void * clientData = NULL,
 MStatus * ReturnStatus = NULL
 )

 Parameters:
 [in] nodeType Type of node that will trigger the callback
 [in] clientData User defined data passed to the callback function
 [out] ReturnStatus status code


 There is a nodeType argument so that will help you to get what you trying.

 On Thu, Aug 6, 2015 at 3:02 PM, Ravi Jagannadhan enr...@gmail.com
 wrote:

 Filter in the callback for your specific node type?

 On Thu, Aug 6, 2015 at 3:00 PM, Arvid Schneider 
 arvidschnei...@gmail.com wrote:

 How would I create a callback that fires when a specific node type is
 created?
 I know about: MDGMessage.addNodeAddedCallback( function )
 but that registers any node created. I want to limit that.
 Someone an idea?
 Arvid

 --
 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/62af34c5-03e1-4064-86c3-76e11df510b9%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/62af34c5-03e1-4064-86c3-76e11df510b9%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 Where we have strong emotions, we're liable to fool ourselves - Carl
 Sagan

 --
 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/CADHeb2azw6SZ7_asi6i7Le%2BD-7DyhfstwR2mbTatp4B1L%3D3Y%2BA%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CADHeb2azw6SZ7_asi6i7Le%2BD-7DyhfstwR2mbTatp4B1L%3D3Y%2BA%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

 --
 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/CANEMyhOWQCCT2R2eBaHptjEwGgcYtsN0fkEdWYzGjxjVmner-w%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CANEMyhOWQCCT2R2eBaHptjEwGgcYtsN0fkEdWYzGjxjVmner-w%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 Arvid Schneider
 Look Develpopment | Lighting TD | Show TD
 www.arvidschneider.com

 Mobil DE: (+49) 170 321 0074
 Mobile UK: (+44) 744 824 6973
 Mail: arvidschnei...@gmail.com

 --
 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/CADrk2uScuj2g%2B4P9sjSRAy%2B6R%2BU3SL7cZKX-zc%3DsisdsxsE7HQ%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CADrk2uScuj2g%2B4P9sjSRAy%2B6R%2BU3SL7cZKX-zc%3DsisdsxsE7HQ%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhNZb-Mp3FLh19LsN8eH5CVeA%2BcFnWobtVimy%2B4R%3Dnkn9A%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[Maya-Python] Combined Texture Channel

2015-08-06 Thread Kurian O.S
Hey,

Anyone tried to change a shader texture channel ( Hardware Texturing)
contained textures through python ?. I tried but no luck, AE never get
updated. Any hints ?

Thanks

-- 
--:: Kurian ::--

-- 
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/CANEMyhNS8Km_zvjK%3DB5qVAitNrjkzP_7LvCt4_hk7TeE%3DLzpFA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Setting Render Settings

2015-07-15 Thread Kurian O.S
Okay defaultRenderGlobals, defaultRenderQuality and defaultResolution those
are separate nodes in maya, if you want to get rez then
cmds.getAttr(defaultResolution.width)
cmds.getAttr(defaultResolution.height)

As Marcus  said you can select each of them and see what attrs there :)

On Wed, Jul 15, 2015 at 10:22 AM, Tim Crowson tcrow...@gmail.com wrote:

 Thanks. I've used this for certain attributes, but I can't figure out
 resolution specifically.

 For example, *cmds.getAttr(defaultRenderGlobals.resolution)* throws an
 error: Error: Message attributes have no data values. Hence some
 confusion


 On Wed, Jul 15, 2015 at 11:40 AM Kurian O.S kuria...@gmail.com wrote:

 welcome to maya world ;)

 if you do a listAttr on renderglobals you will see all the attrs which
 connected to renderglobals eg :

 cmds.listAttr(defaultRenderGlobals)
 # Result: [u'message', u'caching', u'isHistoricallyInteresting',
 u'nodeState', u'binMembership', u'macCodec', u'macDepth', u'macQual',
 u'comFrrt', u'renderAll', u'ignoreFilmGate', u'quality', u'resolution',
 u'clipFinalShadedColor', u'enableDepthMaps', u'enableDefaultLight',
 u'currentRenderer',etc .] #  list was long so i just removed bunch of
 items

 then you can say

 cmds.setAttr(defaultRenderGlobals.imageFormat, 8) #this will set jpg as
 image format.

 Hope this help


 On Wed, Jul 15, 2015 at 8:07 AM, Tim Crowson tcrow...@gmail.com wrote:

 Hey folks,

 I did a quick search through this group's threads and couldn't really
 find the answers I was looking for...

 I am still quite a novice with how Maya does things. I touched the tip
 of the iceberg a few months ago but got pulled onto other things. I'm
 struggling with how to set render settings in Maya. Specifically, I'm
 wanting to set things like render resolution, aspect ratio, image format,
 render cam.

 On a related note, I'm also curious about how to set render paths
 properly. In Softimage there is a root path field in the scene settings,
 but Maya seems to want to me to set this in the Project Settings. Any
 insight here?

 Thanks for your help! Someday I won't be a Maya noob anymore, I promise.

 -Tim

  --
 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/CAPh%3D1bnFvhgVG%2BPKW%3DqFs4d08%3DfqoHuaWekRTsihm4mPVxeVeA%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CAPh%3D1bnFvhgVG%2BPKW%3DqFs4d08%3DfqoHuaWekRTsihm4mPVxeVeA%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

 --
 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/CANEMyhOiiGvCr9Bbjq6NPYMEG_4sSGhXqoU7DY6Teo%2BN-mvzPA%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CANEMyhOiiGvCr9Bbjq6NPYMEG_4sSGhXqoU7DY6Teo%2BN-mvzPA%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 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/CAPh%3D1b%3Dw3GkHVzvNiFgHodRz_W28SqCjyqcfbTWVHF%3Dw8VY3nQ%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CAPh%3D1b%3Dw3GkHVzvNiFgHodRz_W28SqCjyqcfbTWVHF%3Dw8VY3nQ%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhNzE36W9jTEbEX7YpaJ7qtVDBDNBdUN%3DFx0-8X-%2B%2Buafw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Setting Render Settings

2015-07-15 Thread Kurian O.S
welcome to maya world ;)

if you do a listAttr on renderglobals you will see all the attrs which
connected to renderglobals eg :

cmds.listAttr(defaultRenderGlobals)
# Result: [u'message', u'caching', u'isHistoricallyInteresting',
u'nodeState', u'binMembership', u'macCodec', u'macDepth', u'macQual',
u'comFrrt', u'renderAll', u'ignoreFilmGate', u'quality', u'resolution',
u'clipFinalShadedColor', u'enableDepthMaps', u'enableDefaultLight',
u'currentRenderer',etc .] #  list was long so i just removed bunch of
items

then you can say

cmds.setAttr(defaultRenderGlobals.imageFormat, 8) #this will set jpg as
image format.

Hope this help


On Wed, Jul 15, 2015 at 8:07 AM, Tim Crowson tcrow...@gmail.com wrote:

 Hey folks,

 I did a quick search through this group's threads and couldn't really find
 the answers I was looking for...

 I am still quite a novice with how Maya does things. I touched the tip of
 the iceberg a few months ago but got pulled onto other things. I'm
 struggling with how to set render settings in Maya. Specifically, I'm
 wanting to set things like render resolution, aspect ratio, image format,
 render cam.

 On a related note, I'm also curious about how to set render paths
 properly. In Softimage there is a root path field in the scene settings,
 but Maya seems to want to me to set this in the Project Settings. Any
 insight here?

 Thanks for your help! Someday I won't be a Maya noob anymore, I promise.

 -Tim

 --
 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/CAPh%3D1bnFvhgVG%2BPKW%3DqFs4d08%3DfqoHuaWekRTsihm4mPVxeVeA%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CAPh%3D1bnFvhgVG%2BPKW%3DqFs4d08%3DfqoHuaWekRTsihm4mPVxeVeA%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhOiiGvCr9Bbjq6NPYMEG_4sSGhXqoU7DY6Teo%2BN-mvzPA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Check time taken to open a file

2015-07-07 Thread Kurian O.S
import time
import maya.cmds as cmds
curTime = time.time()
fileToOpn = /some/fld/somefile.mb
cmds.file(fileToOpn, o=True,f=True)
print %s to %s seconds % (fileToOpn, time.time() - curTime)

This will show in seconds

On Tue, Jul 7, 2015 at 8:00 PM, likage dissidia@gmail.com wrote:

 Hi all,

 I suppose this question of mine can only be done by scripting...
 Was wondering if there are any ways to check the time - how long Maya
 takes to open a file?


  --
 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/aaf774c1-7e21-433b-99e6-0a7605f00445%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/aaf774c1-7e21-433b-99e6-0a7605f00445%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhPfXP48P%3DQpNFooZLaAtqm0H_9WsT1tDgjn2zq%2BkBG5PQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Re: Check time taken to open a file

2015-07-07 Thread Kurian O.S
There will be slight difference always based on the cpu usage, even like
you have a vlc player playing can make a huge difference in the results :).

On Tue, Jul 7, 2015 at 8:55 PM, likage dissidia@gmail.com wrote:

 Thanks guys, that is what I am looking for :D

 Will take a look into Maya API though it may take me a while to digest it
 since I am not at all familiar with it.

 I have a question though.

 While using the 2 methods as suggested by Justin and Kurlan, the output
 results that I have obtained from both methods are slightly different.
 Justin's method gave me 44.0617549419 while Kurlan's method gave me
 44.7263860703

 Though the difference is very minor, was wondering if anyone could tell me
 why is there a 0.7 gap? I am pretty curious in it seeing that the coding
 for both method is almost the same...


  --
 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/996f39be-dbb6-400c-a2bb-e3394cbdc6d8%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/996f39be-dbb6-400c-a2bb-e3394cbdc6d8%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhOfg%3DjX%2Br1MOJU9ULyBmu3WOo1XTx0wnK%3DTX_c3ymD0pg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Re: Check time taken to open a file

2015-07-07 Thread Kurian O.S
And remember Justin is always right :D

On Tue, Jul 7, 2015 at 8:59 PM, Kurian O.S kuria...@gmail.com wrote:

 There will be slight difference always based on the cpu usage, even like
 you have a vlc player playing can make a huge difference in the results :).

 On Tue, Jul 7, 2015 at 8:55 PM, likage dissidia@gmail.com wrote:

 Thanks guys, that is what I am looking for :D

 Will take a look into Maya API though it may take me a while to digest it
 since I am not at all familiar with it.

 I have a question though.

 While using the 2 methods as suggested by Justin and Kurlan, the output
 results that I have obtained from both methods are slightly different.
 Justin's method gave me 44.0617549419 while Kurlan's method gave me
 44.7263860703

 Though the difference is very minor, was wondering if anyone could tell
 me why is there a 0.7 gap? I am pretty curious in it seeing that the coding
 for both method is almost the same...


  --
 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/996f39be-dbb6-400c-a2bb-e3394cbdc6d8%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/996f39be-dbb6-400c-a2bb-e3394cbdc6d8%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--




-- 
--:: Kurian ::--

-- 
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/CANEMyhO_P7i89mpZ_d0nvV5QwmayOn%3DM%3DX%3D9%3DideGYvmnJGcfg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] List/Print maya group content names

2015-06-19 Thread Kurian O.S
cmds.listRelatives(cmds.ls(sl=True)[0], ad=True, type=mesh) it will give
you all the mesh under your selection

On Fri, Jun 19, 2015 at 2:51 PM, brianbuckle...@gmail.com wrote:

 I'm in need of a method to print out the names of the geometry in a
 selected group node. Any ideas? Even if it is inside another group or
 complex group hierarchy.  Example. I select a group node Heart, print the
 names of the geo in this group.

 -Brian

 --
 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/f22393a4-8a51-449a-bed3-c8367a3c2a67%40googlegroups.com
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhMcVA7wWBJRyjkCVFFxaQiBQ7ZAJW9XJO1MTf02jgyxTg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Can someone filter out the email address that is sending spam?

2015-06-19 Thread Kurian O.S
By the way good to see you back Farsheed after long time ;)

On Fri, Jun 19, 2015 at 1:56 PM, Justin Israel justinisr...@gmail.com
wrote:

 And you as well, Farsheed!

 On Sat, 20 Jun 2015 8:47 AM Farsheed Ashouri farsheed.asho...@gmail.com
 wrote:

 Thanks Justin for your service.


 On Friday, June 19, 2015 at 12:00:03 AM UTC+4:30, Justin Israel wrote:

 Just sit tight. I see everything coming through here. First time posters
 usually require me to approve them as members. And spam is usually caught
 for me to reject.

 On Fri, 19 Jun 2015 5:13 AM Eric Thivierge ethivie...@hybride.com
 wrote:

 Can someone filter out the email address that is sending spam please?
 Boot from the list...

 I'm afraid its going to start raising alarms with our email filter here
 at work and I don't want everything from the list blocked.

 --
 Eric Thivierge
 Rigging Lead


 --
 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/5582FC11.6000101%40hybride.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/17c64762-5fff-43b7-a5a6-b5267ce77743%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/17c64762-5fff-43b7-a5a6-b5267ce77743%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 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/CAPGFgA2NW194DgBGVNWT%2BY9C_2x3ha26cheEc0rQs6%3Dj1tDcTw%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CAPGFgA2NW194DgBGVNWT%2BY9C_2x3ha26cheEc0rQs6%3Dj1tDcTw%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhNN7VkBoA8JbQw-Z9MtW46rTOJF6rS9yeA3iKG%2BQb7E-Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] images for buttons

2015-06-19 Thread Kurian O.S
self.cylinder_btn.setIcon(icon) to self.cube_btn.setIcon(icon) ?

On Fri, Jun 19, 2015 at 8:41 PM, Todd Widup todd.wi...@gmail.com wrote:

 hey guys

 I have been trying to create an image button, but every way I found a
 suggestion on how to try doesn't seem to work.

 self.cube_btn = QtGui.QPushButton(Cube)
 icon = QtGui.QIcon({0}winPub_PUB.png.format(self.icons))
 self.cylinder_btn.setIcon(icon)


 ive tried that and I have tried setting the style sheet background-image
 and neither work.

 any suggestions?

 --
 Todd Widup
 Creature TD / Technical Artist
 t...@toddwidup.com
 todd.wi...@gmail.com
 www.toddwidup.com

 --
 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/CABBPk36-VSG0bzWig4ap1aQyBsZEKW%2BvzWcaveHWO-oLOXxFqw%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CABBPk36-VSG0bzWig4ap1aQyBsZEKW%2BvzWcaveHWO-oLOXxFqw%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhNw30Qde0%3D5vASf%3DwGgL2%3DVNn36zB_Jq7WMNgLbu5o4uA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] images for buttons

2015-06-19 Thread Kurian O.S
self.cube_btn = QtGui.QPushButton(Cube)
btIcon = QtGui.QPixmap({0}winPub_PUB.png.format(self.icons))
self.cube_btn .setIcon(QtGui.QIcon(btIcon ))

On Fri, Jun 19, 2015 at 9:29 PM, Todd Widup todd.wi...@gmail.com wrote:

 I have both   Just copied paste was wrong

 Sent from my iPhone

 On Jun 19, 2015, at 9:09 PM, Kurian O.S kuria...@gmail.com wrote:

 self.cylinder_btn.setIcon(icon) to self.cube_btn.setIcon(icon) ?

 On Fri, Jun 19, 2015 at 8:41 PM, Todd Widup todd.wi...@gmail.com wrote:

 hey guys

 I have been trying to create an image button, but every way I found a
 suggestion on how to try doesn't seem to work.

 self.cube_btn = QtGui.QPushButton(Cube)
 icon = QtGui.QIcon({0}winPub_PUB.png.format(self.icons))
 self.cylinder_btn.setIcon(icon)


 ive tried that and I have tried setting the style sheet background-image
 and neither work.

 any suggestions?

 --
 Todd Widup
 Creature TD / Technical Artist
 t...@toddwidup.com
 todd.wi...@gmail.com
 www.toddwidup.com

 --
 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/CABBPk36-VSG0bzWig4ap1aQyBsZEKW%2BvzWcaveHWO-oLOXxFqw%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CABBPk36-VSG0bzWig4ap1aQyBsZEKW%2BvzWcaveHWO-oLOXxFqw%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

 --
 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/CANEMyhNw30Qde0%3D5vASf%3DwGgL2%3DVNn36zB_Jq7WMNgLbu5o4uA%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CANEMyhNw30Qde0%3D5vASf%3DwGgL2%3DVNn36zB_Jq7WMNgLbu5o4uA%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 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/B7332091-C65E-4301-9CA9-05D8794D76FD%40gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/B7332091-C65E-4301-9CA9-05D8794D76FD%40gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhPpqdFmEi6oR1Bz%2BAPAASO7XfGQeae-nSB-LJyZPZg3TQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] ينظم مركز أرض المعرفة دورات تدريبية شهر أغسطس2015

2015-06-18 Thread Kurian O.S
Translated By google ..

God names pocket - responsible diplomas
And Azb: 00971529139857
Phone: 0097143513999
Fax: 0097142557615
Yours sincerely accept ...

Why we getting this spam mails ?

2015-06-17 23:26 GMT-07:00 Sara Swed saraknowle...@gmail.com:







 *السادة / عملاءنا الكرام*

 السلام عليكم ورحمة الله وبركاته  ،،،

 يهديكم مركز أرض المعرفـــة تحياته متمنياً لكم دوام التوفيق والتقدم
 والنجاح في أعمالكــم.

 يسرنا أن نرفق لسيادتكم:



 *الدورات التدريبية   *

 * شهر أغسطس2015** *



 *آملين أن نتلقى ترشيحاتكم الكريمة في أقرب وقت**.*



 لمزيد من المعلومات نرجو أن لا تترددوا في الاتصال بنـــا:



 *أسماء جيب  الله – مســئولة الدبلومات*

 *واتسب **: **00971529139857*

 *الهاتف: 0097143513999*

 *الفاكس: 0097142557615*

 *وتفضلوا بقبول **فائق الاحتــرام والتقدير...*






  --
 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/CAAkHHOQOxejLA5M-vxKDW8D8hpPzyCANMGL86YwH-p_jB0FoGQ%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CAAkHHOQOxejLA5M-vxKDW8D8hpPzyCANMGL86YwH-p_jB0FoGQ%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhPACAVY5QD_D6WLOV3zDDwxmK_Q-cAU%3DoKx7%2BB-458YtA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] MEL questons ?

2015-05-20 Thread Kurian O.S
go for it :)

On Wed, May 20, 2015 at 8:25 PM, Christopher. crestchristop...@gmail.com
wrote:

 Is it safe to assume, I can ask MEL questions, beginner  expert on this
 list/group ?

 --
 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/d97b4014-18bf-4607-a3be-12b8fd74cbf7%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/d97b4014-18bf-4607-a3be-12b8fd74cbf7%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhMuK4ZbLxJ6zkQHjF7tdHhM%3D4Zzztqvy6hV4BUk5uMj3Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] creating a curve from points

2015-03-03 Thread Kurian O.S
What about this ?

vertexList = [330, 136, 58]
postList = []
for eachVer in vertexList:
postList.append(cmds.pointPosition('pSphere1.vtx[%s]' % eachVer))
cmds.curve(n='curve1', d=1, p=postList)

On Tue, Mar 3, 2015 at 5:50 PM, e9554...@gmail.com wrote:

 Yo,

 if you want to create a curve from a set of points that already exist. eg
 you want to create a curve from points on a mesh. Is this the cleanest way
 to do it?:

 Pnt1=cmds.pointPosition('geo.vtx[330]')
 Pnt2=cmds.pointPosition('geo.vtx[136]')
 Pnt3=cmds.pointPosition('geo.vtx[58]')

 cmds.curve(n='curve1', d=1, p=[Pnt1,Pnt2,Pnt3])

 or is it possible to just enter the 'geo.vtx[330]' items into the curve
 command somehow?  - basically im trying to shrink my script because i have
 a hell load of curves in my scene now.


 thanks alot,
 Sam

 --
 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/91ebea63-0f77-4879-a3ed-4101ed6f2fb1%40googlegroups.com
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhPHKqoctgiMSp2FKFG%3DiiP%2BN-50ydxgT4YG_1MZXrPTDA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Re: cmds.polySplit crashing maya aaaahh

2015-03-02 Thread Kurian O.S
If you pass the geo name then it should work eg:

surfaceNode, creatorNode = cmds.polyCreateFacet( p=[(0, 2, 0), (0, -2, 0),
(4, -2, 0), (4, 2, 0)] )
#just make sure we clear current selection
cmds.select(cl=True)
cmds.polySplit(surfaceNode, ip=[(2, 0.1), (3, 0.5), (0, 2, -1, 0.0), (0,
0.9)] )



On Mon, Mar 2, 2015 at 12:30 PM, e9554...@gmail.com wrote:

 its ok i figured it. I needed to put a cmds.select command to select the
 specific piece of geometry first. Its weird you can't specify that in the
 polySplit command, but anyway...

 --
 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/18c57141-2dba-4077-a926-be04dc3e377f%40googlegroups.com
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhO87rUBqDd95G8B%2Bbds_3VvFBw0WxdpRBeDNv4QmF5tsg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] mayapy throws segmentation fault 11 errors when executing functions

2015-02-18 Thread Kurian O.S
Can you show us your error log ?

On Wed, Feb 18, 2015 at 6:01 PM, Alex W alexwilsonw...@gmail.com wrote:

 I'm just getting started with Python for Maya, following the book *Practical
 Maya Programming with Python*, and I am getting stuck quite early.  When
 I use mayapy, I get *segmentation fault 11* errors when I try to execute
 functions and simple lines of code:

  import sys

 throws the error

  def hello():
 ...  return 'Hello, Maya!'

 also throws the same error.

 I'm running a student version of Maya 2014 on mac osx Yosemite.  Any
 thoughts?

 --
 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/15f23fcd-21af-452a-b254-f9f2a61b8b0a%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/15f23fcd-21af-452a-b254-f9f2a61b8b0a%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhMFqwgZaZ5j4DK8Vkqgj0vX6_771a0uNuevroLKFi-%3DQA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[Maya-Python] Segmentation Fault Catch

2014-09-05 Thread Kurian O.S
Hey Guys,

I have a python script and it will loop through bunch of maya files and do
some stuff. But some time maya get seg fault and my script will stop there.
I tried with signal and multiprocess. But both failed

def sig_handler(signum, frame):
pass

signal.signal(signal.SIGSEGV, sig_handler)


from multiprocessing import Process, Queue
p = Process(target=startCrawling, args=(args, options))
p.start()
p.join()

Both failed.

Any other method which can trap seg fault and continue with next ?

Thanks
-- 
--:: Kurian ::--

-- 
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/CANEMyhN3UQnJmc_mWYvQb%3D2B6d6LcNrCmqZ-AaY63DzmG8aSKQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Segmentation Fault Catch

2014-09-05 Thread Kurian O.S
I got a hint that I was using signal.signal(signal.SIGSEGV, sig_handler)
in wrong place.


On Fri, Sep 5, 2014 at 11:20 AM, Marcus Ottosson konstrukt...@gmail.com
wrote:

 Hi Kurian,

 Do you mean you are running separate processes that open up Maya in the
 background to do some processing?

 Have a look at subprocess.Popen
 https://docs.python.org/2/library/subprocess.html#subprocess.Popen, it
 runs a process completely separate from where you ran it from and shouldn't
 be affected by any of them crashing. They can also be run concurrenctly, by
 just running many of them at the same time. You'll be given a handle to the
 process where you can either communicate or just wait (join), similar to
 Process().

 Best,
 Marcus


 On 5 September 2014 19:52, Kurian O.S kuria...@gmail.com wrote:

 Hey Guys,

 I have a python script and it will loop through bunch of maya files and
 do some stuff. But some time maya get seg fault and my script will stop
 there. I tried with signal and multiprocess. But both failed

 def sig_handler(signum, frame):
 pass

 signal.signal(signal.SIGSEGV, sig_handler)


 from multiprocessing import Process, Queue
 p = Process(target=startCrawling, args=(args, options))
 p.start()
 p.join()

 Both failed.

 Any other method which can trap seg fault and continue with next ?

 Thanks
 --
 --:: Kurian ::--

 --
 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/CANEMyhN3UQnJmc_mWYvQb%3D2B6d6LcNrCmqZ-AaY63DzmG8aSKQ%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CANEMyhN3UQnJmc_mWYvQb%3D2B6d6LcNrCmqZ-AaY63DzmG8aSKQ%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 *Marcus Ottosson*
 konstrukt...@gmail.com

 --
 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/CAFRtmODZ1cvY2OFNCF0q6Yg1GMrNd6_y1bcepXF9mZhWkuddgg%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CAFRtmODZ1cvY2OFNCF0q6Yg1GMrNd6_y1bcepXF9mZhWkuddgg%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhOJ%3Dq%2BYnNaskYQux6ON-zX%2Bfyg9HVXViBqfUXFF%2BjD2Kg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Segmentation Fault Catch

2014-09-05 Thread Kurian O.S
I was wrong its not working :(

def sig_handler(signum, frame):
pass

def dosome(args, options):
#here is my seg fault coming
signal.signal(signal.SIGSEGV, sig_handler)
#maya functions goes here

if __name__ == __main__:
from multiprocessing import Process, Queue
p = Process(target=dosome, args=(args, options))
p.start()
p.join()

This is my code


On Fri, Sep 5, 2014 at 11:45 AM, Kurian O.S kuria...@gmail.com wrote:

 I got a hint that I was using signal.signal(signal.SIGSEGV, sig_handler)
 in wrong place.


 On Fri, Sep 5, 2014 at 11:20 AM, Marcus Ottosson konstrukt...@gmail.com
 wrote:

 Hi Kurian,

 Do you mean you are running separate processes that open up Maya in the
 background to do some processing?

 Have a look at subprocess.Popen
 https://docs.python.org/2/library/subprocess.html#subprocess.Popen, it
 runs a process completely separate from where you ran it from and shouldn't
 be affected by any of them crashing. They can also be run concurrenctly, by
 just running many of them at the same time. You'll be given a handle to the
 process where you can either communicate or just wait (join), similar to
 Process().

 Best,
 Marcus


 On 5 September 2014 19:52, Kurian O.S kuria...@gmail.com wrote:

 Hey Guys,

 I have a python script and it will loop through bunch of maya files and
 do some stuff. But some time maya get seg fault and my script will stop
 there. I tried with signal and multiprocess. But both failed

 def sig_handler(signum, frame):
 pass

 signal.signal(signal.SIGSEGV, sig_handler)


 from multiprocessing import Process, Queue
 p = Process(target=startCrawling, args=(args, options))
 p.start()
 p.join()

 Both failed.

 Any other method which can trap seg fault and continue with next ?

 Thanks
 --
 --:: Kurian ::--

 --
 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/CANEMyhN3UQnJmc_mWYvQb%3D2B6d6LcNrCmqZ-AaY63DzmG8aSKQ%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CANEMyhN3UQnJmc_mWYvQb%3D2B6d6LcNrCmqZ-AaY63DzmG8aSKQ%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 *Marcus Ottosson*
 konstrukt...@gmail.com

 --
 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/CAFRtmODZ1cvY2OFNCF0q6Yg1GMrNd6_y1bcepXF9mZhWkuddgg%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CAFRtmODZ1cvY2OFNCF0q6Yg1GMrNd6_y1bcepXF9mZhWkuddgg%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--




-- 
--:: Kurian ::--

-- 
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/CANEMyhOVgQrUtinX0jWRvdMixb3urCGEtBPtxHW%3DEYe8bed2aw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Segmentation Fault Catch

2014-09-05 Thread Kurian O.S
Hey Guys,

First its a command line tool using optparse to get arguments and options
from user and using maya standalone to do some process ( running through
mayapy ). So Some files its just fail to do the process. Subprocess I am
not sure how I can call a function with arguments.


On Fri, Sep 5, 2014 at 3:40 PM, Justin Israel justinisr...@gmail.com
wrote:

 Hey Kurian,

 I'm not clear on this from your code example, but are you using the
 multiprocessing module from within Maya? Your example indicates that it is
 a standalone script. First, I don't think it is safe to use the
 multiprocessing module within Maya, since forking is not a very safe thing
 to do in that environment. And second, if you are going to handle the seg
 fault yourself, you would be expected to exit the process afterwards (since
 you aren't really doing anything to fix the problem), otherwise you are
 just going to make it continue having problems.

 I think you should go the route that Marcus suggested, where you use
 subprocess. This will fork and exec a new process, instead of just forking
 your current image, which could lead to tons of problems in Maya.




 On Sat, Sep 6, 2014 at 10:11 AM, Kurian O.S kuria...@gmail.com wrote:

 I was wrong its not working :(

 def sig_handler(signum, frame):
 pass

 def dosome(args, options):
 #here is my seg fault coming
 signal.signal(signal.SIGSEGV, sig_handler)
 #maya functions goes here

 if __name__ == __main__:
 from multiprocessing import Process, Queue
 p = Process(target=dosome, args=(args, options))
 p.start()
 p.join()

 This is my code


 On Fri, Sep 5, 2014 at 11:45 AM, Kurian O.S kuria...@gmail.com wrote:

 I got a hint that I was using signal.signal(signal.SIGSEGV, sig_handler)
   in wrong place.


 On Fri, Sep 5, 2014 at 11:20 AM, Marcus Ottosson konstrukt...@gmail.com
  wrote:

 Hi Kurian,

 Do you mean you are running separate processes that open up Maya in the
 background to do some processing?

 Have a look at subprocess.Popen
 https://docs.python.org/2/library/subprocess.html#subprocess.Popen,
 it runs a process completely separate from where you ran it from and
 shouldn't be affected by any of them crashing. They can also be run
 concurrenctly, by just running many of them at the same time. You'll be
 given a handle to the process where you can either communicate or just wait
 (join), similar to Process().

 Best,
 Marcus


 On 5 September 2014 19:52, Kurian O.S kuria...@gmail.com wrote:

 Hey Guys,

 I have a python script and it will loop through bunch of maya files
 and do some stuff. But some time maya get seg fault and my script will 
 stop
 there. I tried with signal and multiprocess. But both failed

 def sig_handler(signum, frame):
 pass

 signal.signal(signal.SIGSEGV, sig_handler)


 from multiprocessing import Process, Queue
 p = Process(target=startCrawling, args=(args, options))
 p.start()
 p.join()

 Both failed.

 Any other method which can trap seg fault and continue with next ?

 Thanks
 --
 --:: Kurian ::--

 --
 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/CANEMyhN3UQnJmc_mWYvQb%3D2B6d6LcNrCmqZ-AaY63DzmG8aSKQ%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CANEMyhN3UQnJmc_mWYvQb%3D2B6d6LcNrCmqZ-AaY63DzmG8aSKQ%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 *Marcus Ottosson*
 konstrukt...@gmail.com

 --
 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/CAFRtmODZ1cvY2OFNCF0q6Yg1GMrNd6_y1bcepXF9mZhWkuddgg%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CAFRtmODZ1cvY2OFNCF0q6Yg1GMrNd6_y1bcepXF9mZhWkuddgg%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--




 --
 --:: Kurian ::--

 --
 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/CANEMyhOVgQrUtinX0jWRvdMixb3urCGEtBPtxHW%3DEYe8bed2aw%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CANEMyhOVgQrUtinX0jWRvdMixb3urCGEtBPtxHW%3DEYe8bed2aw

Re: [Maya-Python] Segmentation Fault Catch

2014-09-05 Thread Kurian O.S
I think I am confusing you all

Here is a snippet

http://pastebin.com/J526ftrM

I tried my max to explain :)


On Fri, Sep 5, 2014 at 4:30 PM, Justin Israel justinisr...@gmail.com
wrote:

 Well if you want to stick with the multiprocessing module and just endure
 the possible seg faults and some files not getting processed, you could
 print a warning and then do a os._exit(1) to just terminate the process.

 Using subprocess, you could have your script take arguments, such as a
 -file flag to accept the file to process. When you run it without that
 particular flag it would start your batch operation, and then subprocesses
 can call the same executable again with specific -file options. Here would
 be a pretty crude example:

 #!/usr/bin/env python
 import sysimport subprocess
 def process(f):
 print process:, f
 if __name__ == __main__:
 if '-file' in sys.argv:
 process(sys.argv[-1])
 sys.exit()

 for names in ('foo', 'bar', 'baz'):
 cmd = [sys.argv[0], '-file', names]
 # cmd = [sys.executable, sys.argv[0], '-file', names]
 subprocess.Popen(cmd)

 ​
 If your script is already executable, then you wouldn't need that
 commented line that runs it with python script.
 You would want to actually do this in a bounded way, like using a thread
 pool or threads+queue to chew on your list of files to process.

 Normally the multiprocessing module could work for what you are doing, but
 I think it isn't playing nice with Maya's initialized environment when the
 process forks.



 On Sat, Sep 6, 2014 at 10:57 AM, Kurian O.S kuria...@gmail.com wrote:

 Hey Guys,

 First its a command line tool using optparse to get arguments and options
 from user and using maya standalone to do some process ( running through
 mayapy ). So Some files its just fail to do the process. Subprocess I am
 not sure how I can call a function with arguments.


 On Fri, Sep 5, 2014 at 3:40 PM, Justin Israel justinisr...@gmail.com
 wrote:

 Hey Kurian,

 I'm not clear on this from your code example, but are you using the
 multiprocessing module from within Maya? Your example indicates that it is
 a standalone script. First, I don't think it is safe to use the
 multiprocessing module within Maya, since forking is not a very safe thing
 to do in that environment. And second, if you are going to handle the seg
 fault yourself, you would be expected to exit the process afterwards (since
 you aren't really doing anything to fix the problem), otherwise you are
 just going to make it continue having problems.

 I think you should go the route that Marcus suggested, where you use
 subprocess. This will fork and exec a new process, instead of just forking
 your current image, which could lead to tons of problems in Maya.




 On Sat, Sep 6, 2014 at 10:11 AM, Kurian O.S kuria...@gmail.com wrote:

 I was wrong its not working :(

 def sig_handler(signum, frame):
 pass

 def dosome(args, options):
 #here is my seg fault coming
 signal.signal(signal.SIGSEGV, sig_handler)
 #maya functions goes here

 if __name__ == __main__:
 from multiprocessing import Process, Queue
 p = Process(target=dosome, args=(args, options))
 p.start()
 p.join()

 This is my code


 On Fri, Sep 5, 2014 at 11:45 AM, Kurian O.S kuria...@gmail.com wrote:

 I got a hint that I was using signal.signal(signal.SIGSEGV,
 sig_handler)   in wrong place.


 On Fri, Sep 5, 2014 at 11:20 AM, Marcus Ottosson 
 konstrukt...@gmail.com wrote:

 Hi Kurian,

 Do you mean you are running separate processes that open up Maya in
 the background to do some processing?

 Have a look at subprocess.Popen
 https://docs.python.org/2/library/subprocess.html#subprocess.Popen,
 it runs a process completely separate from where you ran it from and
 shouldn't be affected by any of them crashing. They can also be run
 concurrenctly, by just running many of them at the same time. You'll be
 given a handle to the process where you can either communicate or just 
 wait
 (join), similar to Process().

 Best,
 Marcus


 On 5 September 2014 19:52, Kurian O.S kuria...@gmail.com wrote:

 Hey Guys,

 I have a python script and it will loop through bunch of maya files
 and do some stuff. But some time maya get seg fault and my script will 
 stop
 there. I tried with signal and multiprocess. But both failed

 def sig_handler(signum, frame):
 pass

 signal.signal(signal.SIGSEGV, sig_handler)


 from multiprocessing import Process, Queue
 p = Process(target=startCrawling, args=(args, options))
 p.start()
 p.join()

 Both failed.

 Any other method which can trap seg fault and continue with next ?

 Thanks
 --
 --:: Kurian ::--

 --
 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

Re: [Maya-Python] || Sr. PL/SQL - BO- Java/ Jquery/Ext JS Developer || TX- NY

2014-09-03 Thread Kurian O.S
NICE TO HAVE SKILLS:

· Mortgage Banking Experience - Must.

What you mean by must under -NICE TO HAVE SKILLS- ? :)


On Wed, Sep 3, 2014 at 2:47 PM, Deepak Kaushik deep.ci...@gmail.com wrote:

 *Job Position: Sr. PL SQL developer*

 Location: Dublin, OH/ Dallas, TX

 Duration:- 12+ Months

 Exp.:- 7-10 years

 =



 *Role:-**   Sr. PL SQL developer*



 *ROLES AND RESPONSIBILITIES:-*

 · Strong experience  in distributed systems development using
 PL/SQL, Oracle Database Development experience

 · Strong shell scripting skills, mainly to encapsulate SQL 
 PL/SQL code and enable the code to be run on automated schedulers

 · Develop MIS reports in agile methodology

 · Experience in technologies such as CTL-M, Autosys

 · Must be able to work well in a collaborative, team environment
 as well as independently

 · Mortgage banking  experience is must



 *MUST HAVE SKILLS:*

 · 7-10 yrs of reports development and MIS experience

 · Strong PL/SQL  stored procedures development and Oracle
 database experience

 · MIS reports development experience by extracting data from
 large and complex databases

 · Strong experience in collaborating with business and IT teams
 to develop, test and deploy in Agile development methodology.

 · SAS experience is a plus

 · Experience with Mortgage banking is preferred

 · Bachelor’s Degree or higher in engineering, technology or
 related field.

 · Excellent communications, including written, verbal and
 presentation skills



 *NICE TO HAVE SKILLS:*



 · Mortgage Banking Experience - Must.

 =



 *Job Position: BO Developer*

 Location: Houston, TX

 Duration:- 12+ Months

 =



 *Role:-**   Developer*



 *ROLES AND RESPONSIBILITIES:-*

 · Primary Skill: Business Objects, Oracle, PL/SQL

 · Secondary skill : Qlikview, Jaspersoft

 *=*



 *Job Position: Java/ Jquery/Ext JS*

 Location: New York, NY

 Duration:- 12+ Months

 =



 *Role:-**   Developer*



 *ROLES AND RESPONSIBILITIES:-*

 · Strong experience in Java.

 · Strong experience in JQuery, HTML5 and EXTJS

 · Worked individually with Business Users.

 · Good Communication skill

 · Banking  Finance Domain knowledge is a must.

 · Experience in working in Client Facing Applications.

 · Good Problem Solving and Logical skills

 *=*

 *In case you are not looking for the change at this point of time please
 refer your colleagues, Friends etc.*





 *Regards*

 *Deepak*

 *United Software Group Inc.*
 565 Metro Place S. Suite # 110

 Dublin, OH 43017

 Phone: 614-588-8591

 dee...@usgrpinc.com

 deep.cit71

 --
 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/CAFVHj-95ms6Y3FgEob9zZyCtp_mCGchL-zZMLv7T5AkTGr5xvg%40mail.gmail.com
 https://groups.google.com/d/msgid/python_inside_maya/CAFVHj-95ms6Y3FgEob9zZyCtp_mCGchL-zZMLv7T5AkTGr5xvg%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhMwEYiMSmG1PQ50E4tuDuY0Nsen8%3DD_waH1u4WYmCVMvw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] QtGui.QDialog .... how do you show the Maximize button on the window ??

2014-07-25 Thread Kurian O.S
self.setWindowFlags(QtCore.Qt.Window)


On Fri, Jul 25, 2014 at 2:32 PM, md accou...@mdonovan.com wrote:

 Thanks !!! =)

 M

 --
 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/39d66abe-7155-4f49-b864-b402db508e10%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/39d66abe-7155-4f49-b864-b402db508e10%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhN%3DggvCtJZwyfYeD8OKvLGDbPBZrkD6271pRg0CbdRyYA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Bar Charts with PySide

2014-07-22 Thread Kurian O.S
http://matplotlib.org/ will help you on this ..
https://qt.gitorious.org/pyside/pyside-examples/source/492cb950507fc1606615c9869148baae45b33235:examples/itemviews/chart/chart.py
also give a idea.


On Tue, Jul 22, 2014 at 11:57 AM, md accou...@mdonovan.com wrote:

 Has anyone here done any sort of bar charting with PySide ? Are there any
 existing modules for this kind of thing ?

 Thanks

 M

 --
 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/90e5c392-75cd-4166-abf8-4b97a5e63119%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/90e5c392-75cd-4166-abf8-4b97a5e63119%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhPQCkkVR9BW%3Dk5nPnv%2Bdw6%2BrDtVqch2h25q%2BEuQgODVYA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] qProgressbar update questions

2014-07-21 Thread Kurian O.S
self.ui.pgr_copy_files.Value = bar_val

Needs to be

self.ui.pgr_copy_files.setValue(bar_val)



On Mon, Jul 21, 2014 at 2:51 PM, md accou...@mdonovan.com wrote:

 self.ui.pgr_copy_files.Value = bar_val





-- 
--:: Kurian ::--

-- 
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/CANEMyhPXbc2tmc8eT14swg1UAqQZsp-wa%3D%3Dr6PuLi%2B3jKVuMow%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Re: qProgressbar update questions

2014-07-21 Thread Kurian O.S
self.ui.pgr_copy_files.setValue(bar_val) not
self.ui.pgr_copy_files.setValue = bar_val

I think that's going wrong.


On Mon, Jul 21, 2014 at 3:00 PM, md accou...@mdonovan.com wrote:

 Kurian ... thanks .. but I actually made a typo when typing the question
 ... In my code it is self.ui.pgr_copy_files.setValue = bar_val

 still it does not update.


 On Monday, July 21, 2014 5:51:41 PM UTC-4, md wrote:

 Hey guys

 I have a couple functions where I am copying files. I want to update a
 progressbar on my form. Here is the basic code (this is inside a function
 on the form) :

 inc_val = (100 / hi_val - low_val )

 bar_val = 0
 for f_no in range(low_val,hi_val):

 bar_val += inc_val
 self.ui.pgr_copy_files.Value = bar_val


 The value is incrementing .. I am checking with a print statement ... but
 the bar is not updating.

 what am I doing wrong ?

 thanks !

  --
 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/5e810256-d6a0-4553-916d-c20937563d7f%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/5e810256-d6a0-4553-916d-c20937563d7f%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhM8RHSTJtDvy36XcvVOAOKT5rgTYWb-hMBJZZ5C_CfzDg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] pm.hasAttr(obj,'getShape') not working, even though obj.getShape() works...

2014-06-17 Thread Kurian O.S
hasAttr will check only for existing attribute.

  import maya.cmds as cmd

import pymel.core as pm

list = cmd.ls(sl=True)

for obj in list:

obj = pm.PyNode(obj)

print pm.hasAttr(obj,'tx')

This will work and what is getShape ?, is it a function ? or is it
attribute which is existed in selected object ?


On Tue, Jun 17, 2014 at 3:08 PM, Brian Eyre brianeyr...@googlemail.com
wrote:

 Hi,

 I'm trying to add a line that error checks for whether the getShape()
 method exists for selected objects, by using *hasAttr*, but it keeps
 returning *false* even when getShape() exists for the obj:

 import maya.cmds as cmd
 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:
 obj = pm.PyNode(obj)
 print pm.hasAttr(obj,'getShape')


 Any ideas??





  --
 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/0abb0814-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/0abb0814-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhOkf%2BBaSJOvDgY34eXeOfwBA%3DC9yAghaaUN734oAW5h%2Bw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] pm.hasAttr(obj,'getShape') not working, even though obj.getShape() works...

2014-06-17 Thread Kurian O.S
http://download.autodesk.com/us/maya/2011help/PyMel/generated/functions/pymel.core.general/pymel.core.general.hasAttr.html


On Tue, Jun 17, 2014 at 3:19 PM, Kurian O.S kuria...@gmail.com wrote:

 hasAttr will check only for existing attribute.

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 print pm.hasAttr(obj,'tx')

 This will work and what is getShape ?, is it a function ? or is it
 attribute which is existed in selected object ?


 On Tue, Jun 17, 2014 at 3:08 PM, Brian Eyre brianeyr...@googlemail.com
 wrote:

 Hi,

 I'm trying to add a line that error checks for whether the getShape()
 method exists for selected objects, by using *hasAttr*, but it keeps
 returning *false* even when getShape() exists for the obj:

 import maya.cmds as cmd
 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:
 obj = pm.PyNode(obj)
 print pm.hasAttr(obj,'getShape')


 Any ideas??





  --
 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/0abb0814-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/0abb0814-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--




-- 
--:: Kurian ::--

-- 
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/CANEMyhMpr%3DFftXiOEmexeNPSQv2G1SP0DiCJtZhZeaWZ1txq0w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] pm.hasAttr(obj,'getShape') not working, even though obj.getShape() works...

2014-06-17 Thread Kurian O.S
import maya.cmds as cmd

import pymel.core as pm

list = cmd.ls(sl=True)

for obj in list:

obj = pm.PyNode(obj)

if obj.getShape():

print obj.getShape()

Are you looking for this ?


On Tue, Jun 17, 2014 at 3:24 PM, Brian Eyre brianeyr...@googlemail.com
wrote:

 It's actually a function that returns the shape node, yes.  Do I need a
 different syntax for that?  obj.getShape() definitely works, which is why
 i'm puzzled.


 On Tuesday, June 17, 2014 3:20:19 PM UTC-7, Kurian wrote:

 hasAttr will check only for existing attribute.

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 print pm.hasAttr(obj,'tx')

 This will work and what is getShape ?, is it a function ? or is it
 attribute which is existed in selected object ?


 On Tue, Jun 17, 2014 at 3:08 PM, Brian Eyre brian...@googlemail.com
 wrote:

 Hi,

 I'm trying to add a line that error checks for whether the getShape()
 method exists for selected objects, by using *hasAttr*, but it keeps
 returning *false* even when getShape() exists for the obj:

 import maya.cmds as cmd
 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:
 obj = pm.PyNode(obj)
 print pm.hasAttr(obj,'getShape')


 Any ideas??





  --
 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/0abb0814-ff47-42a9-9464-
 5ce2f856dbee%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/0abb0814-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/1637e11d-8553-4b2d-a79a-43ae0c0cfc27%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/1637e11d-8553-4b2d-a79a-43ae0c0cfc27%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhMiDBCa%3DtfBtjsgvnc7Y79aKxQbqh_yKOusGau9W9Bu_Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] pm.hasAttr(obj,'getShape') not working, even though obj.getShape() works...

2014-06-17 Thread Kurian O.S
I didn't use pymel much, but I am not sure you can check a function with
hasAttr. Maybe some one will have better idea, I would go for a
AttributeError check with try.


On Tue, Jun 17, 2014 at 3:35 PM, Brian Eyre brianeyr...@googlemail.com
wrote:

 No, sorry.  That returns an error if *obj* happens to have no getShape()
 method, which is what i'm rying to check for...


 On Tuesday, June 17, 2014 3:27:16 PM UTC-7, Kurian wrote:

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 if obj.getShape():

 print obj.getShape()

 Are you looking for this ?


 On Tue, Jun 17, 2014 at 3:24 PM, Brian Eyre brian...@googlemail.com
 wrote:

 It's actually a function that returns the shape node, yes.  Do I need a
 different syntax for that?  obj.getShape() definitely works, which is why
 i'm puzzled.


 On Tuesday, June 17, 2014 3:20:19 PM UTC-7, Kurian wrote:

 hasAttr will check only for existing attribute.

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 print pm.hasAttr(obj,'tx')

 This will work and what is getShape ?, is it a function ? or is it
 attribute which is existed in selected object ?


 On Tue, Jun 17, 2014 at 3:08 PM, Brian Eyre brian...@googlemail.com
 wrote:

 Hi,

 I'm trying to add a line that error checks for whether the getShape()
 method exists for selected objects, by using *hasAttr*, but it keeps
 returning *false* even when getShape() exists for the obj:

 import maya.cmds as cmd
 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:
 obj = pm.PyNode(obj)
 print pm.hasAttr(obj,'getShape')


 Any ideas??





  --
 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/0abb0814-ff47-42a9-9464-5ce2f856dbee%
 40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/0abb0814-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/1637e11d-8553-4b2d-a79a-
 43ae0c0cfc27%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/1637e11d-8553-4b2d-a79a-43ae0c0cfc27%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/dca48f87-4fa9-4f61-ab57-0182c9d6f16a%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/dca48f87-4fa9-4f61-ab57-0182c9d6f16a%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhNORkmy5G6FYqGifkUdaeqOmFvRZ-6SV-FZu%2BKO5Jpqyg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] pm.hasAttr(obj,'getShape') not working, even though obj.getShape() works...

2014-06-17 Thread Kurian O.S
import maya.cmds as cmd

import pymel.core as pm

list = cmd.ls(sl=True)

for obj in list:

obj = pm.PyNode(obj)

print hasattr(obj,'getShape')


On Tue, Jun 17, 2014 at 3:40 PM, Kurian O.S kuria...@gmail.com wrote:

 I didn't use pymel much, but I am not sure you can check a function with
 hasAttr. Maybe some one will have better idea, I would go for a
 AttributeError check with try.


 On Tue, Jun 17, 2014 at 3:35 PM, Brian Eyre brianeyr...@googlemail.com
 wrote:

 No, sorry.  That returns an error if *obj* happens to have no getShape()
 method, which is what i'm rying to check for...


 On Tuesday, June 17, 2014 3:27:16 PM UTC-7, Kurian wrote:

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 if obj.getShape():

 print obj.getShape()

 Are you looking for this ?


 On Tue, Jun 17, 2014 at 3:24 PM, Brian Eyre brian...@googlemail.com
 wrote:

 It's actually a function that returns the shape node, yes.  Do I need a
 different syntax for that?  obj.getShape() definitely works, which is why
 i'm puzzled.


 On Tuesday, June 17, 2014 3:20:19 PM UTC-7, Kurian wrote:

 hasAttr will check only for existing attribute.

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 print pm.hasAttr(obj,'tx')

 This will work and what is getShape ?, is it a function ? or is it
 attribute which is existed in selected object ?


 On Tue, Jun 17, 2014 at 3:08 PM, Brian Eyre brian...@googlemail.com
 wrote:

 Hi,

 I'm trying to add a line that error checks for whether the getShape()
 method exists for selected objects, by using *hasAttr*, but it keeps
 returning *false* even when getShape() exists for the obj:

 import maya.cmds as cmd
 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:
 obj = pm.PyNode(obj)
 print pm.hasAttr(obj,'getShape')


 Any ideas??





  --
 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/0abb0814-ff47-42a9-9464-5ce2f856dbee%
 40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/0abb0814-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/1637e11d-8553-4b2d-a79a-
 43ae0c0cfc27%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/1637e11d-8553-4b2d-a79a-43ae0c0cfc27%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/dca48f87-4fa9-4f61-ab57-0182c9d6f16a%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/dca48f87-4fa9-4f61-ab57-0182c9d6f16a%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--




-- 
--:: Kurian ::--

-- 
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/CANEMyhPcN1TXn0JcvTSOMQWWw5LRfmdNJLn2bHFbYVEEPfHK%3DA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] pm.hasAttr(obj,'getShape') not working, even though obj.getShape() works...

2014-06-17 Thread Kurian O.S
Just a note hasattr is not a pymel function its a python built in method.
https://docs.python.org/2/library/functions.html#hasattr


On Tue, Jun 17, 2014 at 3:42 PM, Kurian O.S kuria...@gmail.com wrote:



 import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 print hasattr(obj,'getShape')


 On Tue, Jun 17, 2014 at 3:40 PM, Kurian O.S kuria...@gmail.com wrote:

 I didn't use pymel much, but I am not sure you can check a function with
 hasAttr. Maybe some one will have better idea, I would go for a
 AttributeError check with try.


 On Tue, Jun 17, 2014 at 3:35 PM, Brian Eyre brianeyr...@googlemail.com
 wrote:

 No, sorry.  That returns an error if *obj* happens to have no
 getShape() method, which is what i'm rying to check for...


 On Tuesday, June 17, 2014 3:27:16 PM UTC-7, Kurian wrote:

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 if obj.getShape():

 print obj.getShape()

 Are you looking for this ?


 On Tue, Jun 17, 2014 at 3:24 PM, Brian Eyre brian...@googlemail.com
 wrote:

 It's actually a function that returns the shape node, yes.  Do I need
 a different syntax for that?  obj.getShape() definitely works, which is 
 why
 i'm puzzled.


 On Tuesday, June 17, 2014 3:20:19 PM UTC-7, Kurian wrote:

 hasAttr will check only for existing attribute.

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 print pm.hasAttr(obj,'tx')

 This will work and what is getShape ?, is it a function ? or is it
 attribute which is existed in selected object ?


 On Tue, Jun 17, 2014 at 3:08 PM, Brian Eyre brian...@googlemail.com
 wrote:

 Hi,

 I'm trying to add a line that error checks for whether the
 getShape() method exists for selected objects, by using *hasAttr*,
 but it keeps returning *false* even when getShape() exists for the
 obj:

 import maya.cmds as cmd
 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:
 obj = pm.PyNode(obj)
 print pm.hasAttr(obj,'getShape')


 Any ideas??





  --
 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/0abb081
 4-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/0abb0814-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/1637e11d-8553-4b2d-a79a-
 43ae0c0cfc27%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/1637e11d-8553-4b2d-a79a-43ae0c0cfc27%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/dca48f87-4fa9-4f61-ab57-0182c9d6f16a%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/dca48f87-4fa9-4f61-ab57-0182c9d6f16a%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--




 --
 --:: Kurian ::--




-- 
--:: Kurian ::--

-- 
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/CANEMyhPbn41Mm4rioo0-sQvqwUX5Oskc%3D%2BzOTXCgq9UO4JZnVg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] pm.hasAttr(obj,'getShape') not working, even though obj.getShape() works...

2014-06-17 Thread Kurian O.S
I replied already I think :)

python built in hasattr will also work for you

  import maya.cmds as cmd

import pymel.core as pm

list = cmd.ls(sl=True)

for obj in list:

obj = pm.PyNode(obj)

print hasattr(obj,'getShape')

https://docs.python.org/2/library/functions.html#hasattr


On Tue, Jun 17, 2014 at 3:54 PM, Brian Eyre brianeyr...@googlemail.com
wrote:

 Oh, that's brilliant, thanks!  Wasn't aware of 'try'.. so this seems to
 work:



 import maya.cmds as cmd
 import pymel.core as pm

 list = pm.ls(sl=1)



 for obj in list:
 obj = pm.PyNode(obj)
 try:
 print obj.getShape()
 except:
 pm.warning('no shape!')

 If anyone knows why hasattr(obj,'getShape') does't work, please let me
 know!



 On Tuesday, June 17, 2014 3:41:02 PM UTC-7, Kurian wrote:

 I didn't use pymel much, but I am not sure you can check a function with
 hasAttr. Maybe some one will have better idea, I would go for a
 AttributeError check with try.


 On Tue, Jun 17, 2014 at 3:35 PM, Brian Eyre brian...@googlemail.com
 wrote:

 No, sorry.  That returns an error if *obj* happens to have no
 getShape() method, which is what i'm rying to check for...


 On Tuesday, June 17, 2014 3:27:16 PM UTC-7, Kurian wrote:

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 if obj.getShape():

 print obj.getShape()

 Are you looking for this ?


 On Tue, Jun 17, 2014 at 3:24 PM, Brian Eyre brian...@googlemail.com
 wrote:

 It's actually a function that returns the shape node, yes.  Do I need
 a different syntax for that?  obj.getShape() definitely works, which is 
 why
 i'm puzzled.


 On Tuesday, June 17, 2014 3:20:19 PM UTC-7, Kurian wrote:

 hasAttr will check only for existing attribute.

   import maya.cmds as cmd

 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:

 obj = pm.PyNode(obj)

 print pm.hasAttr(obj,'tx')

 This will work and what is getShape ?, is it a function ? or is it
 attribute which is existed in selected object ?


 On Tue, Jun 17, 2014 at 3:08 PM, Brian Eyre brian...@googlemail.com
 wrote:

 Hi,

 I'm trying to add a line that error checks for whether the
 getShape() method exists for selected objects, by using *hasAttr*,
 but it keeps returning *false* even when getShape() exists for the
 obj:

 import maya.cmds as cmd
 import pymel.core as pm

 list = cmd.ls(sl=True)

 for obj in list:
 obj = pm.PyNode(obj)
 print pm.hasAttr(obj,'getShape')


 Any ideas??





  --
 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/0abb081
 4-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/0abb0814-ff47-42a9-9464-5ce2f856dbee%40googlegroups.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/1637e11d-8553-4b2d-a79a-43ae0c0cfc27%
 40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/1637e11d-8553-4b2d-a79a-43ae0c0cfc27%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/dca48f87-4fa9-4f61-ab57-
 0182c9d6f16a%40googlegroups.com
 https://groups.google.com/d/msgid/python_inside_maya/dca48f87-4fa9-4f61-ab57-0182c9d6f16a%40googlegroups.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

  --
 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/3096bcdd-5f8e-44af-8f2b-fc6f396c4e91%40googlegroups.com
 

Re: [Maya-Python] Reference Node Attribute Unlocking

2014-03-21 Thread Kurian O.S
Thanks Guys


On Fri, Mar 21, 2014 at 3:10 AM, Marcus Ottosson konstrukt...@gmail.comwrote:

 As a workaround, you can store the values local to your scene (in other
 attributes) and connect the previously-locked attributes to those. Not sure
 if the connection will hold, but worst case you could add a script-node set
 to execute on scene start-up to reconnect.


 On 20 March 2014 22:16, Kurian O.S kuria...@gmail.com wrote:

 Thanks Paul, yeah that's bit sad :(


 On Thu, Mar 20, 2014 at 2:55 PM, Paul Molodowitch elron...@gmail.comwrote:

 import pymel.core as pm
 pm.Attribute('persp.tx').__apimplug__().setLocked(False)

 Like I said though... just be aware that any changes won't be saved

 On Thu, Mar 20, 2014 at 2:51 PM, Kurian O.S kuria...@gmail.com wrote:

 We using maya 2012 :( do you have any quick snippet with api ?

 Thanks Paul


 On Thu, Mar 20, 2014 at 2:50 PM, Paul Molodowitch 
 elron...@gmail.comwrote:

 There's two ways - in maya 2014 and up there's now an option to let
 you do that; and you can also use the maya api to unlock even referenced
 attributes.

 Be careful, though, as it will then let you make changes to that
 attribute, but I don't think it saves those changes...


 On Thu, Mar 20, 2014 at 2:47 PM, Kurian O.S kuria...@gmail.comwrote:

 Hey Guys,

 Any one was able to unlock a attribute from a reference node ?, I
 have a scene and it has some referenced geo and those geo has some 
 texture
 applied on it. I want to change the texture path. But fileTextureName
 attribute is lock. Is there any way to unlock this attribute without 
 going
 and editing the original reference file ?

 Thanks


 --
 --:: Kurian ::--

 --
 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/CANEMyhPxDAT9aCeRSK1KnEko_aOyAmbP34vE%2BnnOGKkyQ0Ldgw%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CANEMyhPxDAT9aCeRSK1KnEko_aOyAmbP34vE%2BnnOGKkyQ0Ldgw%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 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/CAAssL7Y_o-To0erwNWok%3DYoUhMi093jhJfdoPLjaNFk4C3h30g%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CAAssL7Y_o-To0erwNWok%3DYoUhMi093jhJfdoPLjaNFk4C3h30g%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

 --
 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/CANEMyhM-3%3D62XOTXhusgFiCVGq8e54rsW_LJL0sGZNxvo%3DhHTA%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CANEMyhM-3%3D62XOTXhusgFiCVGq8e54rsW_LJL0sGZNxvo%3DhHTA%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 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/CAAssL7ZoZ3Z1eJh_reqDnYa3S7MVP3E43sUj4q_Gy2dk%3DjbgDg%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CAAssL7ZoZ3Z1eJh_reqDnYa3S7MVP3E43sUj4q_Gy2dk%3DjbgDg%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

 --
 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/CANEMyhPktq9PY%2BzVfL%3Dv%3D5ynOLtRqQOz0XqCT498LD-pGdf5TQ%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CANEMyhPktq9PY%2BzVfL%3Dv%3D5ynOLtRqQOz0XqCT498LD-pGdf5TQ%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 *Marcus

[Maya-Python] Reference Node Attribute Unlocking

2014-03-20 Thread Kurian O.S
Hey Guys,

Any one was able to unlock a attribute from a reference node ?, I have a
scene and it has some referenced geo and those geo has some texture applied
on it. I want to change the texture path. But fileTextureName attribute
is lock. Is there any way to unlock this attribute without going and
editing the original reference file ?

Thanks


-- 
--:: Kurian ::--

-- 
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/CANEMyhPxDAT9aCeRSK1KnEko_aOyAmbP34vE%2BnnOGKkyQ0Ldgw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Reference Node Attribute Unlocking

2014-03-20 Thread Kurian O.S
We using maya 2012 :( do you have any quick snippet with api ?

Thanks Paul


On Thu, Mar 20, 2014 at 2:50 PM, Paul Molodowitch elron...@gmail.comwrote:

 There's two ways - in maya 2014 and up there's now an option to let you do
 that; and you can also use the maya api to unlock even referenced
 attributes.

 Be careful, though, as it will then let you make changes to that
 attribute, but I don't think it saves those changes...


 On Thu, Mar 20, 2014 at 2:47 PM, Kurian O.S kuria...@gmail.com wrote:

 Hey Guys,

 Any one was able to unlock a attribute from a reference node ?, I have a
 scene and it has some referenced geo and those geo has some texture applied
 on it. I want to change the texture path. But fileTextureName attribute
 is lock. Is there any way to unlock this attribute without going and
 editing the original reference file ?

 Thanks


 --
 --:: Kurian ::--

 --
 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/CANEMyhPxDAT9aCeRSK1KnEko_aOyAmbP34vE%2BnnOGKkyQ0Ldgw%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CANEMyhPxDAT9aCeRSK1KnEko_aOyAmbP34vE%2BnnOGKkyQ0Ldgw%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 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/CAAssL7Y_o-To0erwNWok%3DYoUhMi093jhJfdoPLjaNFk4C3h30g%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CAAssL7Y_o-To0erwNWok%3DYoUhMi093jhJfdoPLjaNFk4C3h30g%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhM-3%3D62XOTXhusgFiCVGq8e54rsW_LJL0sGZNxvo%3DhHTA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] Reference Node Attribute Unlocking

2014-03-20 Thread Kurian O.S
Thanks Paul, yeah that's bit sad :(


On Thu, Mar 20, 2014 at 2:55 PM, Paul Molodowitch elron...@gmail.comwrote:

 import pymel.core as pm
 pm.Attribute('persp.tx').__apimplug__().setLocked(False)

 Like I said though... just be aware that any changes won't be saved

 On Thu, Mar 20, 2014 at 2:51 PM, Kurian O.S kuria...@gmail.com wrote:

 We using maya 2012 :( do you have any quick snippet with api ?

 Thanks Paul


 On Thu, Mar 20, 2014 at 2:50 PM, Paul Molodowitch elron...@gmail.comwrote:

 There's two ways - in maya 2014 and up there's now an option to let you
 do that; and you can also use the maya api to unlock even referenced
 attributes.

 Be careful, though, as it will then let you make changes to that
 attribute, but I don't think it saves those changes...


 On Thu, Mar 20, 2014 at 2:47 PM, Kurian O.S kuria...@gmail.com wrote:

 Hey Guys,

 Any one was able to unlock a attribute from a reference node ?, I have
 a scene and it has some referenced geo and those geo has some texture
 applied on it. I want to change the texture path. But fileTextureName
 attribute is lock. Is there any way to unlock this attribute without going
 and editing the original reference file ?

 Thanks


 --
 --:: Kurian ::--

 --
 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/CANEMyhPxDAT9aCeRSK1KnEko_aOyAmbP34vE%2BnnOGKkyQ0Ldgw%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CANEMyhPxDAT9aCeRSK1KnEko_aOyAmbP34vE%2BnnOGKkyQ0Ldgw%40mail.gmail.com?utm_medium=emailutm_source=footer
 .
 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/CAAssL7Y_o-To0erwNWok%3DYoUhMi093jhJfdoPLjaNFk4C3h30g%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CAAssL7Y_o-To0erwNWok%3DYoUhMi093jhJfdoPLjaNFk4C3h30g%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




 --
 --:: Kurian ::--

 --
 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/CANEMyhM-3%3D62XOTXhusgFiCVGq8e54rsW_LJL0sGZNxvo%3DhHTA%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CANEMyhM-3%3D62XOTXhusgFiCVGq8e54rsW_LJL0sGZNxvo%3DhHTA%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 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/CAAssL7ZoZ3Z1eJh_reqDnYa3S7MVP3E43sUj4q_Gy2dk%3DjbgDg%40mail.gmail.comhttps://groups.google.com/d/msgid/python_inside_maya/CAAssL7ZoZ3Z1eJh_reqDnYa3S7MVP3E43sUj4q_Gy2dk%3DjbgDg%40mail.gmail.com?utm_medium=emailutm_source=footer
 .

 For more options, visit https://groups.google.com/d/optout.




-- 
--:: Kurian ::--

-- 
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/CANEMyhPktq9PY%2BzVfL%3Dv%3D5ynOLtRqQOz0XqCT498LD-pGdf5TQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Maya-Python] path.py: isdir() not working with python27

2014-01-09 Thread Kurian O.S
path = 'path/to/file'

if os.path.isdir(path):
 print Yes it is ! 

This didnt work for you ?


On Thu, Jan 9, 2014 at 1:47 PM, Jesse Capper jesse.cap...@gmail.com wrote:

 Loading the same path.py module into a 2.6.4 and 2.7.3 session produces
 different results when calling Path(path/to/file).isdir()

 2.6.4 works as expected - outputs True or False
 2.7.3 raises a TypeError: *TypeError: _isdir() takes exactly 1 argument
 (0 given)*

 Anyone know why the behavior changed?

 This is an easy manual fix except that we also use pymel which ships with
 its own path.py module that pymel calls return. Replacing that on each
 user's machine is more involved and I was hoping for an easier solution.

 --
 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/7fe466f0-9628-4b31-8ed8-0e872a94974d%40googlegroups.com
 .
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
--:: Kurian ::--

-- 
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/CANEMyhPz0BGWnU78tuY9Q-2VPcYC_i7pHkBtERkQgbBzBmgk4Q%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Maya-Python] HyperShade dragger context question. TextField under pointer querry possible?!

2014-01-09 Thread Kurian O.S
-Another way around this would be to querry the textField under pointer,
but i dont think that's possible, or?!-

If yopu are using pyqt then Natan got some ideas
http://nathanhorne.com/?p=298

import sip
import maya.cmds as cmds
import maya.OpenMayaUI as apiUI
from PyQt4 import QtGui, QtCore

def getMayaWindow():
 'Get the maya main window as a QMainWindow instance'
ptr = apiUI.MQtUtil.mainWindow()
 return sip.wrapinstance(long(ptr), QtCore.QObject)
def getFocusWidget():
'Get the currently focused widget'
 return QtGui.qApp.focusWidget()

def getWidgetAtMouse():
'Get the widget under the mouse'
 currentPos = QtGui.QCursor().pos()
widget = QtGui.qApp.widgetAt(currentPos)
return widget


On Thu, Jan 9, 2014 at 6:05 PM, Ævar Guðmundsson 
aevar.gudmunds...@gmail.com wrote:

 I'm no expert on the matter but I'd guess there is a dragEnter event and
 presumably, as long as your drag content is plain text you should be able
 to query the mimetext from that event as it's open...

   Hope that helps, if there are no other suggestions I'll try throwing up
 a practical case tomorrow, if you don't mind me asking though, since it's a
 really interesting problem you have, what would you do with the text once
 you have it queried while it's floating? Display it somewhere if just
 making sure it's copied to a separate clipboard?

 --
 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/adbee889-b1c1-4be9-8e5a-c72cd31171d1%40googlegroups.com
 .
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
--:: Kurian ::--

-- 
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/CANEMyhOWX3SAGqkni-nQXbFafhtJDnSi%3DN-Y-TDQH_RPWdGaaw%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Maya-Python] setPlaceholderText for QLineEdit in maya

2013-08-23 Thread Kurian O.S
lwww.lmgtfy.com/?q=setplaceholdertext+qlineedit#seen

On Friday, August 23, 2013, Arjun Thekkummadathil 3dar...@gmail.com wrote:

 Hi
am trying to make a UI for a small tool i developed and i use PyQt and
 i use a Input Widget called QLineEdit and use a feature for that called
 placeHoldetText to put up a temp text in my text field.

 This tool works fine if i open it standalone. But when i open from maya
 interface it gives me a Attribute Error that 'QLineEdit' object has no
 attribute 'setPlaceholderText'

 Now is this bcoz am doing something wrong or this feature is not supported
 in maya

 --
 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.comjavascript:_e({}, 
 'cvml',
 'python_inside_maya%2bunsubscr...@googlegroups.com');.
 To post to this group, send email to 
 python_inside_maya@googlegroups.comjavascript:_e({}, 'cvml', 
 'python_inside_maya@googlegroups.com');
 .
 For more options, visit https://groups.google.com/groups/opt_out.



-- 
--:: Kurian ::--

-- 
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 post to this group, send email to python_inside_maya@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Maya-Python] setPlaceholderText for QLineEdit in maya

2013-08-23 Thread Kurian O.S
Its pyqt version issue. Just google it you will get the answer.

On Friday, August 23, 2013, Justin Israel wrote:

 Sorry. Was late on the updates. Maya 2012.
 On Aug 23, 2013 8:27 PM, Justin Israel 
 justinisr...@gmail.comjavascript:_e({}, 'cvml', 'justinisr...@gmail.com');
 wrote:

 What version of maya/pyqt4?
  On Aug 23, 2013 8:01 PM, Arjun Thekkummadathil 
 3dar...@gmail.comjavascript:_e({}, 'cvml', '3dar...@gmail.com');
 wrote:

 Hi
am trying to make a UI for a small tool i developed and i use PyQt
 and i use a Input Widget called QLineEdit and use a feature for that called
 placeHoldetText to put up a temp text in my text field.

 This tool works fine if i open it standalone. But when i open from maya
 interface it gives me a Attribute Error that 'QLineEdit' object has no
 attribute 'setPlaceholderText'

 Now is this bcoz am doing something wrong or this feature is not
 supported in maya

 --
 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.comjavascript:_e({}, 'cvml',
 'python_inside_maya%2bunsubscr...@googlegroups.com');.
 To post to this group, send email to 
 python_inside_maya@googlegroups.comjavascript:_e({}, 'cvml', 
 'python_inside_maya@googlegroups.com');
 .
 For more options, visit https://groups.google.com/groups/opt_out.

  --
 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.comjavascript:_e({}, 
 'cvml',
 'python_inside_maya%2bunsubscr...@googlegroups.com');.
 To post to this group, send email to 
 python_inside_maya@googlegroups.comjavascript:_e({}, 'cvml', 
 'python_inside_maya@googlegroups.com');
 .
 For more options, visit https://groups.google.com/groups/opt_out.



-- 
--:: Kurian ::--

-- 
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 post to this group, send email to python_inside_maya@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [Maya-Python] How to set StatusBar() message when hover mouse over some widget ?

2012-12-07 Thread Kurian O.S
For Directory you want to use exec so you need to change your code like this

def showDirDialog(self):
directory=os.path.expanduser('~')
dirPath=QtGui.QFileDialog(self,Select Render Directory,directory)
dirPath.setFileMode(QtGui.QFileDialog.DirectoryOnly)
if dirPath.exec_() == 1:
fname_list = str(dirPath.selectedFiles()[0])
print fname_list

For changing the statusBar text you need to implement focusIn and out Event
and Justin already mention about that in reimplement QPlainText’s
focusInEvent in another source file ,how to ? thread.


On Fri, Dec 7, 2012 at 6:25 AM, san niceguy...@gmail.com wrote:

 as a part of my learning PyQt4 I started making a gui(see attachment)
 where I implement all the examples I learn from video tuts or book I am
 referring,

 however I count figure out how should I implement the method to show text
 message on the status bar when user hover mouse over a widget[link to pastebin
 http://pastebin.com/9gfYaWRV]

 and secondly I dont understand how come this method to select Directory is
 not working?

 def showDirDialog(self):
 directory=os.path.expanduser('~')
 dirPath=QtGui.QFileDialog(self,Select Render Directory,directory
 )
 dirPath.setFileMode(QtGui.QFileDialog.DirectoryOnly)

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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] Multiple Qpush Btn selection of Character UI

2012-12-07 Thread Kurian O.S
http://www.diotavelli.net/PyQtWiki/Selecting%20a%20region%20of%20a%20widget
hope
this help at some point.


On Fri, Dec 7, 2012 at 11:25 AM, Justin Israel justinisr...@gmail.comwrote:

 Take a look at the 
 QRubberbandhttp://qt-project.org/doc/qt-4.8/qrubberband.html.
 It lets you draw bounding rectangles around an area. You can then use that
 bounding rect to ask your widget about which children are inside the rect.



 On Fri, Dec 7, 2012 at 11:10 AM, Rishis3D rishis...@gmail.com wrote:

 Yes ,  to activate or select the buttons  especially Fingers region
 in ui.. like if they want to select only two finger controls(each three,
 totally 6 controls). it could be easy to select instead of shift selecting
 bunch of buttons that closest to each other

 --
 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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] hot to get vertex list

2012-08-24 Thread Kurian O.S
srcVts=mc.ls((selObjs[0]+'.vtx[*]'),fl=True)

in mel you passing * in  and in python its already inside ' :)

On Fri, Aug 24, 2012 at 7:23 AM, zevs92 zev...@gmail.com wrote:

 selObjs=mc.ls(sl=True)
 srcVts=mc.ls((selObjs[0]+'.vtx[*]'),fl=True




-- 
--:: Kurian ::--

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


Re: [Maya-Python] Use a variable with setAttr ?

2012-08-10 Thread Kurian O.S
try this

def L_arm_FK(self,ctrlselected ,*args ):
#so I want something like : boby:L_Arm_CtrlShape.FKIK_Blend
for each_ctrl in ctrlselected:
setAttr = cmds.setAttr('%s.FKIK_Blend' % each_ctrl, 0, edit=True)



On Fri, Aug 10, 2012 at 4:50 AM, Florian Croquet fcroq...@gmail.com wrote:

 def L_arm_FK(self,ctrlselected ,*args ):


   #so I want something like : boby:L_Arm_CtrlShape.FKIK_Blend
   setAttr = cmds.setAttr(ctrlselected + '.FKIK_Blend', 0, edit=True)




-- 
--:: Kurian ::--

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


Re: [Maya-Python] Use a variable with setAttr ?

2012-08-10 Thread Kurian O.S
most probably ctrlselected is list http://effbot.org/zone/python-list.htm
so thats why you getting that error. if you using cmds.ls(sl=True) to get
ctrlselected then ls will always return a list ie :

import maya.cmds as cmds
cmds.ls(sl=True)
# Result: [u'pSphere1'] #

so a for loop will help you in this case :)

On Fri, Aug 10, 2012 at 10:52 AM, Florian Croquet fcroq...@gmail.comwrote:

 Thank you Kurian,

 Unfortunately, I forgot my file at work so I will try monday, I hope it
 will work

 PS: dear admin, sorry for my triple post but I had an issue with chrome :/

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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] New powerful code editor

2012-07-04 Thread Kurian O.S
But you need SilverCity installed in your system for SublimeCodeIntel,
otherwise CodeIntel will fail for loading autocompletion.

On Wed, Jul 4, 2012 at 10:08 AM, Justin Israel justinisr...@gmail.comwrote:

 I just did a clean install to check the steps. Here is the easiest way
 from a fresh SublimeText2 install:
 (Note: When I refer to the super key on mac, the equiv on win/linux is
 the ctrl key)

 1. Install the Package Manager to make subsequent installs easy, and it
 will keep them up to date:
 a. Open up the Command Console: View - Show Console
 b. Paste this python snippet which will install Package Manager, from
 this link: http://wbond.net/sublime_packages/package_control/installation
c. Restart Sublime

 2. Install SublimeCodeIntel
 a. Open the command palette (super+shift+p on mac), and type Install
 Package; hit enter
 b. Now search: CodeIntel; choose it and it will install.
 c. Restart Sublime

 3. Test CodeIntel: The first time you start using CodeIntel, it will need
 to build an index of your pythonpath to find everything.
 a. open up a python script (something saved with a .py so sublime
 knows what language it is)
 b. import sys
 c. on a new line, start typing: sys.
 d. after the period, hit the manual completion hotkey. on mac its
 super+j
 e. You will see the status at the bottom telling you CodeIntel is
 scanning all your paths. When it is done, it will show the completion. And
 now autocompletion will be working right away.

 Personally, I turn off autocompletion in the settings and just use the
 hotkey when I want completion. I don't like it constantly popping up for
 everything I type.

 With this working, you could proceed to add more paths to your config, as
 listed in my previous reply.

 let me know if this stats working for ya.



 On Jul 3, 2012, at 9:00 PM, Ollarin wrote:

 Hey Justin,

 I've been trying to set up SublimeCodeIntel but I can't get it to work,
 according to ST2 it's installed. I've added the paths to the config file,
 though I don't get any auto completion. Even ctrl+shift+space doesn't work
 for bringing up the code completion manually.

 Would you happen to know what might cause something like that?


 On Tuesday, 3 July 2012 14:10:36 UTC-4, Justin Israel wrote:

 For anyone that ends up using SublimeCodeIntel, I just got completion
 working fine with the maya commands and api.

 (adjust paths for your platform)

 In your ~/.codeintel/config, add this path to your pythonExtraPaths
  python entry:

 ...
 Python: {
 python: '/usr/local/bin/python',
 pythonExtraPaths: [
 ...
 '/Applications/Autodesk/**maya2012/devkit/devkit/other/**
 pymel/extras/completion/py'
 ]
 }
 ...

 The next time you do a completion, it will want to scan that location
 which might take a few seconds the first time:

 import maya.OpenMaya as om
 om.completion


 On Mon, Jul 2, 2012 at 8:13 PM, Justin Israel justinisr...@gmail.comwrote:

 Read up to my previous reply about installing CodeIntel, to get code
 completion for general python standard lib.
 I can't remember if it works for the maya commands module though.
 CodeIntel would have to be able to load the .so like Eclipse does, as
 opposed to how other completers just parse an AST from the source files.



 On Jul 2, 2012, at 8:01 PM, Kurian O.S kuria...@gmail.com wrote:

 code complete is working for anyone ? I tries some thing like os.path.
 but no compete window or do we need any plugin ? I am really looking
 for maya commands complete :)

 On Mon, Jul 2, 2012 at 7:34 PM, Justin Israel justinisr...@gmail.comwrote:

 Unfortunately its not free. But its also not really expensive.

 I decided to throw something together today for being able to send
 commands from SublimeText2 - Maya:
 https://github.com/justinfx/**MayaSublimehttps://github.com/justinfx/MayaSublime
 Its a start, and works for the simple tests I have done so far.



 If someone ever decides to write a syntax file for MEL, I could include
 that as well.

 On Mon, Jul 2, 2012 at 7:32 PM, Kurian O.S kuria...@gmail.com wrote:

 Is it free like scite ? because I saw a menu for Enter License.


 On Mon, Jul 2, 2012 at 3:00 PM, Justin Israel 
 justinisr...@gmail.comwrote:

 @Jesse
 SublimeCodeIntel - 
 https://github.com/Kronuz/**SublimeCodeIntelhttps://github.com/Kronuz/SublimeCodeIntel

 @PixelMucher
 I don't think there is an existing plugin, from what I have searched,
 but the editor allows for it by writing a python plugin:
 http://www.sublimetext.com/**docs/api-referencehttp://www.sublimetext.com/docs/api-reference
 You could make it something that fires on File Save, or an
 application command that maybe binds to a hotkey for Send To maya


 On Mon, Jul 2, 2012 at 2:32 PM, PixelMuncher pixeldr...@gmail.comwrote:

 Is there an easy way to connect to Maya so it can send commands?
 Thx.


 --
 view archives: 
 http://groups.google.com/**group/python_inside_mayahttp

Re: [Maya-Python] New powerful code editor

2012-07-04 Thread Kurian O.S
http://pypi.python.org/pypi/SilverCity

On Wed, Jul 4, 2012 at 10:17 AM, Kurian O.S kuria...@gmail.com wrote:

 But you need SilverCity installed in your system for SublimeCodeIntel,
 otherwise CodeIntel will fail for loading autocompletion.


 On Wed, Jul 4, 2012 at 10:08 AM, Justin Israel justinisr...@gmail.comwrote:

 I just did a clean install to check the steps. Here is the easiest way
 from a fresh SublimeText2 install:
 (Note: When I refer to the super key on mac, the equiv on win/linux is
 the ctrl key)

 1. Install the Package Manager to make subsequent installs easy, and it
 will keep them up to date:
 a. Open up the Command Console: View - Show Console
 b. Paste this python snippet which will install Package Manager, from
 this link: http://wbond.net/sublime_packages/package_control/installation
c. Restart Sublime

 2. Install SublimeCodeIntel
 a. Open the command palette (super+shift+p on mac), and type Install
 Package; hit enter
 b. Now search: CodeIntel; choose it and it will install.
 c. Restart Sublime

 3. Test CodeIntel: The first time you start using CodeIntel, it will need
 to build an index of your pythonpath to find everything.
 a. open up a python script (something saved with a .py so sublime
 knows what language it is)
 b. import sys
 c. on a new line, start typing: sys.
 d. after the period, hit the manual completion hotkey. on mac its
 super+j
 e. You will see the status at the bottom telling you CodeIntel is
 scanning all your paths. When it is done, it will show the completion. And
 now autocompletion will be working right away.

 Personally, I turn off autocompletion in the settings and just use the
 hotkey when I want completion. I don't like it constantly popping up for
 everything I type.

 With this working, you could proceed to add more paths to your config, as
 listed in my previous reply.

 let me know if this stats working for ya.



 On Jul 3, 2012, at 9:00 PM, Ollarin wrote:

 Hey Justin,

 I've been trying to set up SublimeCodeIntel but I can't get it to work,
 according to ST2 it's installed. I've added the paths to the config file,
 though I don't get any auto completion. Even ctrl+shift+space doesn't work
 for bringing up the code completion manually.

 Would you happen to know what might cause something like that?


 On Tuesday, 3 July 2012 14:10:36 UTC-4, Justin Israel wrote:

 For anyone that ends up using SublimeCodeIntel, I just got completion
 working fine with the maya commands and api.

 (adjust paths for your platform)

 In your ~/.codeintel/config, add this path to your pythonExtraPaths
  python entry:

 ...
 Python: {
 python: '/usr/local/bin/python',
 pythonExtraPaths: [
 ...
 '/Applications/Autodesk/**maya2012/devkit/devkit/other/**
 pymel/extras/completion/py'
 ]
 }
 ...

 The next time you do a completion, it will want to scan that location
 which might take a few seconds the first time:

 import maya.OpenMaya as om
 om.completion


 On Mon, Jul 2, 2012 at 8:13 PM, Justin Israel justinisr...@gmail.comwrote:

 Read up to my previous reply about installing CodeIntel, to get code
 completion for general python standard lib.
 I can't remember if it works for the maya commands module though.
 CodeIntel would have to be able to load the .so like Eclipse does, as
 opposed to how other completers just parse an AST from the source files.



 On Jul 2, 2012, at 8:01 PM, Kurian O.S kuria...@gmail.com wrote:

 code complete is working for anyone ? I tries some thing like os.path.
 but no compete window or do we need any plugin ? I am really looking
 for maya commands complete :)

 On Mon, Jul 2, 2012 at 7:34 PM, Justin Israel 
 justinisr...@gmail.comwrote:

 Unfortunately its not free. But its also not really expensive.

 I decided to throw something together today for being able to send
 commands from SublimeText2 - Maya:
 https://github.com/justinfx/**MayaSublimehttps://github.com/justinfx/MayaSublime
 Its a start, and works for the simple tests I have done so far.



 If someone ever decides to write a syntax file for MEL, I could
 include that as well.

 On Mon, Jul 2, 2012 at 7:32 PM, Kurian O.S kuria...@gmail.com wrote:

 Is it free like scite ? because I saw a menu for Enter License.


 On Mon, Jul 2, 2012 at 3:00 PM, Justin Israel justinisr...@gmail.com
  wrote:

 @Jesse
 SublimeCodeIntel - 
 https://github.com/Kronuz/**SublimeCodeIntelhttps://github.com/Kronuz/SublimeCodeIntel

 @PixelMucher
 I don't think there is an existing plugin, from what I have
 searched, but the editor allows for it by writing a python plugin:
 http://www.sublimetext.com/**docs/api-referencehttp://www.sublimetext.com/docs/api-reference
 You could make it something that fires on File Save, or an
 application command that maybe binds to a hotkey for Send To maya


 On Mon, Jul 2, 2012 at 2:32 PM, PixelMuncher 
 pixeldr...@gmail.comwrote:

 Is there an easy way to connect to Maya

Re: [Maya-Python] New powerful code editor

2012-07-04 Thread Kurian O.S
Ah thats a typo,

I just cleaned everything and I installed everything from scratch, now
codeIntel is working for me.

But still I have errors

Traceback (most recent call last):
  File ./sublime_plugin.py, line 272, in is_enabled_
  File ./SublimeCodeIntel.py, line 1070, in is_enabled
  File ./SublimeCodeIntel.py, line 1050, in is_enabled
  File ./SublimeCodeIntel.py, line 214, in guess_lang
AttributeError: 'NoneType' object has no attribute 'settings'

not sure but I am happy with maya autocomplete :)

On Wed, Jul 4, 2012 at 12:42 PM, Dean Warren deanare...@gmail.com wrote:

 Is that error message exact? I ask because it says:

 SilverScity

 ...but the module is called:

 SilverCity

 ...maybe a typo in common.py?

 On 7/4/12, Kurian O.S kuria...@gmail.com wrote:
  but for some reason in linux I am getting
 
  ImportError: No module named SilverScity
 
  from
  .config/sublime-text-2/Packages/SublimeCodeIntel/libs/codeintel2/common.
  py

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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] Re: New powerful code editor

2012-07-02 Thread Kurian O.S
Is it free like scite ? because I saw a menu for Enter License.

On Mon, Jul 2, 2012 at 3:00 PM, Justin Israel justinisr...@gmail.comwrote:

 @Jesse
 SublimeCodeIntel - https://github.com/Kronuz/SublimeCodeIntel

 @PixelMucher
 I don't think there is an existing plugin, from what I have searched, but
 the editor allows for it by writing a python plugin:
 http://www.sublimetext.com/docs/api-reference
 You could make it something that fires on File Save, or an application
 command that maybe binds to a hotkey for Send To maya


 On Mon, Jul 2, 2012 at 2:32 PM, PixelMuncher pixeldr...@gmail.com wrote:

 Is there an easy way to connect to Maya so it can send commands?
 Thx.

  --
 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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] Re: New powerful code editor

2012-07-02 Thread Kurian O.S
code complete is working for anyone ? I tries some thing like os.path.
butno compete window or do we need any plugin ? I am really looking
for
maya commands complete :)

On Mon, Jul 2, 2012 at 7:34 PM, Justin Israel justinisr...@gmail.comwrote:

 Unfortunately its not free. But its also not really expensive.

 I decided to throw something together today for being able to send
 commands from SublimeText2 - Maya:
 https://github.com/justinfx/MayaSublime
 Its a start, and works for the simple tests I have done so far.



 If someone ever decides to write a syntax file for MEL, I could include
 that as well.

 On Mon, Jul 2, 2012 at 7:32 PM, Kurian O.S kuria...@gmail.com wrote:

 Is it free like scite ? because I saw a menu for Enter License.


 On Mon, Jul 2, 2012 at 3:00 PM, Justin Israel justinisr...@gmail.comwrote:

 @Jesse
 SublimeCodeIntel - https://github.com/Kronuz/SublimeCodeIntel

 @PixelMucher
 I don't think there is an existing plugin, from what I have searched,
 but the editor allows for it by writing a python plugin:
 http://www.sublimetext.com/docs/api-reference
 You could make it something that fires on File Save, or an application
 command that maybe binds to a hotkey for Send To maya


 On Mon, Jul 2, 2012 at 2:32 PM, PixelMuncher pixeldr...@gmail.comwrote:

 Is there an easy way to connect to Maya so it can send commands?
 Thx.

  --
 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




 --
 --:: Kurian ::--

  --
 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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] Re: New powerful code editor

2012-07-02 Thread Kurian O.S
aha thats a cool Idea Justin

On Mon, Jul 2, 2012 at 7:34 PM, Justin Israel justinisr...@gmail.comwrote:

 Unfortunately its not free. But its also not really expensive.

 I decided to throw something together today for being able to send
 commands from SublimeText2 - Maya:
 https://github.com/justinfx/MayaSublime
 Its a start, and works for the simple tests I have done so far.



 If someone ever decides to write a syntax file for MEL, I could include
 that as well.

 On Mon, Jul 2, 2012 at 7:32 PM, Kurian O.S kuria...@gmail.com wrote:

 Is it free like scite ? because I saw a menu for Enter License.


 On Mon, Jul 2, 2012 at 3:00 PM, Justin Israel justinisr...@gmail.comwrote:

 @Jesse
 SublimeCodeIntel - https://github.com/Kronuz/SublimeCodeIntel

 @PixelMucher
 I don't think there is an existing plugin, from what I have searched,
 but the editor allows for it by writing a python plugin:
 http://www.sublimetext.com/docs/api-reference
 You could make it something that fires on File Save, or an application
 command that maybe binds to a hotkey for Send To maya


 On Mon, Jul 2, 2012 at 2:32 PM, PixelMuncher pixeldr...@gmail.comwrote:

 Is there an easy way to connect to Maya so it can send commands?
 Thx.

  --
 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




 --
 --:: Kurian ::--

  --
 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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] Re: New powerful code editor

2012-07-02 Thread Kurian O.S
I found another one https://github.com/JulianEberius/SublimeRope works nice
:)

On Mon, Jul 2, 2012 at 8:13 PM, Justin Israel justinisr...@gmail.comwrote:

 Read up to my previous reply about installing CodeIntel, to get code
 completion for general python standard lib.
 I can't remember if it works for the maya commands module though.
 CodeIntel would have to be able to load the .so like Eclipse does, as
 opposed to how other completers just parse an AST from the source files.



 On Jul 2, 2012, at 8:01 PM, Kurian O.S kuria...@gmail.com wrote:

 code complete is working for anyone ? I tries some thing like os.path. butno 
 compete window or do we need any plugin ? I am really looking for
 maya commands complete :)

 On Mon, Jul 2, 2012 at 7:34 PM, Justin Israel justinisr...@gmail.comwrote:

 Unfortunately its not free. But its also not really expensive.

 I decided to throw something together today for being able to send
 commands from SublimeText2 - Maya:
 https://github.com/justinfx/MayaSublime
 Its a start, and works for the simple tests I have done so far.



 If someone ever decides to write a syntax file for MEL, I could include
 that as well.

 On Mon, Jul 2, 2012 at 7:32 PM, Kurian O.S kuria...@gmail.com wrote:

 Is it free like scite ? because I saw a menu for Enter License.


 On Mon, Jul 2, 2012 at 3:00 PM, Justin Israel justinisr...@gmail.comwrote:

 @Jesse
 SublimeCodeIntel - https://github.com/Kronuz/SublimeCodeIntel

 @PixelMucher
 I don't think there is an existing plugin, from what I have searched,
 but the editor allows for it by writing a python plugin:
 http://www.sublimetext.com/docs/api-reference
 You could make it something that fires on File Save, or an application
 command that maybe binds to a hotkey for Send To maya


 On Mon, Jul 2, 2012 at 2:32 PM, PixelMuncher pixeldr...@gmail.comwrote:

 Is there an easy way to connect to Maya so it can send commands?
 Thx.

  --
 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




 --
 --:: Kurian ::--

  --
 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




 --
 --:: Kurian ::--

  --
 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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] Maya PYQT Installation Problem

2012-06-14 Thread Kurian O.S
If you are just looking for PyQt for maya then download the 2012 pack from
http://www.kurianos.com/wordpress/?p=551 and copy to  /usr/autodesk
/maya_2013/lib/python_version/site-packages.

And the issue step 7 didn't make the make file for you because its end's
with a exception , so there is no point going to step 8 anyway. Can you
post the terminal output of step 8 ?

On Sat, Jun 9, 2012 at 6:56 PM, GWinters glenn.j.wint...@gmail.com wrote:

 Hi everyone
 I was hoping someone may be able to help me out. Im trying to install
 pyqt.  Im currently at the building pyqt part. All my paths have been
 adjust to where I configured.and I get to step 8. When I try to input make
 -j8 i get the following error: make: *** No targets specified and no
 makefile found.  Stop.

 I really have no idea what to do at this point. Everything has been
 installed correctly. The only change I made was on the Sip instaill and
 removed the -arch tag because it was giving me problems. Anyone have any
 ideas. They would be greatly appreciated.

 Thanks

 Glenn

 1. tar ‐zxvf PyQt‐mac‐gpl‐4.9.1.tar.gz
 2. cd PyQt‐mac‐gpl‐4.9.1
 3. export QTDIR=/usr/local/Trolltech/Qt‐4.7.1
 4. export PATH=/usr/local/Trolltech/Qt‐4.7.1/bin:$PATH
 5. export QMAKESPEC=/usr/local/Trolltech/Qt‐4.7.1/mkspecs/macx‐g++
 6. export DYLD_LIBRARY_PATH=/usr/local/Trolltech/Qt‐4.7.1/lib
 7. /Applications/Autodesk/maya2013/Maya.app/Contents/bin/mayapy
 configure.py
 LIBDIR_QT=/usr/local/Trolltech/Qt‐4.7.1/lib
 INCDIR_QT=/usr/local/Trolltech/Qt‐4.7.1/include
 MOC=/usr/local/Trolltech/Qt‐4.7.1/bin/moc ‐w ‐‐no‐designer‐plugin he
 following message may be printed by the configure process:
 Creating pyqtconfig.py...
 Exception TypeError: TypeError('NoneType' object is not callable,) in
 bound method Popen.__del__ of
 subprocess.Popen object at 0x1004ab7d0 ignored
 8.  make ‐j8
 9.  sudo make install


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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] How to find constrained parent of an object in mayapy standalone.

2012-06-14 Thread Kurian O.S
If you can show your code snippet then it will be easy for to debug. The
issue can be solved using long names.

On Thu, Jun 14, 2012 at 12:35 PM, Sudeepth Patinjarayil
ammu0...@gmail.comwrote:

 Hi Justin,

 Thank you for your code. But i wrote the same code but i was not getting
 the result in mayapy. i am using maya 2011 hotfix 3. my script is for
 getting the parent node(if any) of the scene referenced camera and to get
 the position of the camera. i got the position but unable to find the
 parent. But if i paste the same code in maya script editor i am getting the
 result. i think you understand what i want.

 Thanks and Regards,
 Sudeepth Patinjarayi.


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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] import PyQt4.phonon dll error in Maya 2012

2012-06-04 Thread Kurian O.S
Maya 2012 is using Qt 4.7.1 and you need to puild pyqt with qt 4.7.1 I
think.

On Mon, Jun 4, 2012 at 2:08 PM, loked judd...@gmail.com wrote:

 Hey, I'm getting this error:

 # ImportError: DLL load failed: The specified procedure could not be
 found. #

 When I try to execute this in Maya 2012

 import PyQt4.phonon

 It works fine in 2011.

 Here are the versions I'm using:
 QtCore.QT_VERSION
 # Result: 263427 #
 QtCore.PYQT_VERSION_STR
 # Result: '4.7.3' #

 Also, is there any other good alternatives to Phonon?

 Any help is appreciated!

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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] PyQt stub modules?

2012-05-23 Thread Kurian O.S
You may try this http://stackoverflow.com
/questions/10407886/how-to-let-yasnippet-support-pyqt-in-emacs

On Wed, May 23, 2012 at 12:10 PM, Justin Israel justinisr...@gmail.comwrote:

 Yea I have been using SublimeEdit2 lately, which does not code complete
 for PyQt (though I am so engrained with having the docs open in a browser
 anyways). But when I used to use eclipse, it did work great for me as well.
 Unfortunately eclipse was always super heavy on the system and kind of
 unstable for me.


 On Wed, May 23, 2012 at 11:25 AM, John Patrick jspatr...@gmail.comwrote:

 Yep, the way I've seen this working is through editors that run a python
 process that imports and inspects the modules, like Eclipse can.

 I did a little more Googling and found that rope has an 'extention
 modules' preference that can be configured - these modules are imported and
 inspected.

 Not familiar with PyCharm, but maybe there's something similar?


 On Wed, May 23, 2012 at 10:32 AM, David Moulder da...@thirstydevil.co.uk
  wrote:

 I would also be interested in this.  I use PyCharm and have partial
 completion working.  PyCharm is meant to import any *.pyd modules it can as
 a background task, then produce internal stub files.

 I'm yet to get completion working in any editor correctly for PyQt.


 On Wed, May 23, 2012 at 5:42 PM, JP jspatr...@gmail.com wrote:

 Hey All,

 Was wondering if any emacs users had PyQt completion working.  The
 completion mechanism many seem to use in emacs is pymacs+rope/ropemacs/
 ropemode, but as far as I can tell, it doesn't work with the binary
 files installed in the PyQt4 package.  I've been using the stub
 modules for Maya, which has seemed to work alright - maybe someone has
 already gone to the trouble of generating stub modules for PyQt?

 Thanks,
 JP

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




 --
 David Moulder
 http://www.google.com/profiles/squish3d

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




 --
 John Patrick
 404-242-2675
 jspatr...@gmail.com
 http://www.canyourigit.com

  --
 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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] PyQt - how to check if UI is already running?

2012-01-09 Thread Kurian O.S
you can use

class MyApp (QApplication):
 

if __name__ == '__main__':
app = MyApp( sys.argv)
if app.isRunning():
... do whatevr u want


On Mon, Jan 9, 2012 at 5:30 PM, Ricardo Viana cgolhei...@gmail.com wrote:

 Humm. It should. Check you have your naming right on the .ui for window
 widget.

 Best regards
 Ricardo Viana

 On Jan 9, 2012, at 11:56 AM, Panupat Chongstitwattana panup...@gmail.com
 wrote:

 Hi Kamil.

 Thanks for suggestion. But the cmds deleteUI/window modules can't seem to
 detect the PyQt window's titles :(


 On Mon, Jan 9, 2012 at 5:31 PM, Kamil Hepner hektor1...@gmail.com wrote:

 It's very simple:


 winName = myWindow
 if pm.windows.window(winName, exists=True):
pm.windows.deleteUI(winName)


 2012/1/9 Panupat Chongstitwattana panup...@gmail.com

 In Maya 2010, if I run the script to start a UI that is already running,
 it would crash Maya D: How can I check if the UI is already running and
 close it?

 --
 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


  --
 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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] PyQt - how to check if UI is already running?

2012-01-09 Thread Kurian O.S
O otherwise you can try using this

import sip
import maya.OpenMayaUI as mui
from PyQt4.QtCore import *
from PyQt4.QtQtGui import *

def getMayaWindow():
ptr = mui.MQtUtil.mainWindow()
return sip.wrapinstance(long(ptr), QObject)

class Form(QDialog):
def __init__(self, parent=None):
super(Form, self).__init__(parent)
self.setObjectName('mainUI')
self.mainLayout = QVBoxLayout(self)
self.myButton = QPushButton('myButton')
self.mainLayout.addWidget(self.myButton)

global app
global form
app = qApp
form = Form(getMayaWindow())
form.show()

PS :  PyQt4.QtCore import * is not really a good idea at all.

On Mon, Jan 9, 2012 at 9:01 AM, Panupat Chongstitwattana panup...@gmail.com
 wrote:

 David - does pumpThread come with Maya 2010?

 I'll try it out once I get to my studio tomorrow, thanks :)



 On Mon, Jan 9, 2012 at 7:57 PM, David Moulder da...@thirstydevil.co.ukwrote:

 You are using pumpThread right?

 If so you shouldn't do sys.exit(app.exec_())

 just myapp.show()

 If your not using pumpThread you have to in Maya 2010.

 You can find pumpThread in the sdk folder.  From memory you need to
 import it and initialize it before any Qt Gui is created.

 import pumpThread as pt
 pt.initializePumpThread()

 -Dave


 On Mon, Jan 9, 2012 at 12:31 PM, Panupat Chongstitwattana 
 panup...@gmail.com wrote:

 Kamil

 The UI class is Ui_AddPlayblast.py. The set title line looks like this

 AddPlayblast.setWindowTitle(QtGui.QApplication.translate(AddPlayblast,
 Manual Add Playblast, None, QtGui.QApplication.UnicodeUTF8))

 I tried using both AddPlayblast and Manual Add Playblast to no
 avail. Is there anything else I should try?


 Kurian - the UI script will be run exclusively in Maya. As I understand,
 the __name__ = __main__ only works if you run the py file
 directly? Initally I'm launching the UI with these commands

 app = QtGui.QApplication(sys.argv)
 myapp = AddPlayblast()
 myapp.show()
 sys.exit(app.exec_())

 I tested it out in another function, and it is this line that freezes
 Maya

 myapp = AddPlayblast()


 best regard,
 Panupat C.


 On Mon, Jan 9, 2012 at 7:04 PM, Kurian O.S kuria...@gmail.com wrote:

 you can use

 class MyApp (QApplication):
  

 if __name__ == '__main__':
 app = MyApp( sys.argv)
 if app.isRunning():
 ... do whatevr u want


 On Mon, Jan 9, 2012 at 5:30 PM, Ricardo Viana cgolhei...@gmail.comwrote:

 Humm. It should. Check you have your naming right on the .ui for
 window widget.

 Best regards
 Ricardo Viana

 On Jan 9, 2012, at 11:56 AM, Panupat Chongstitwattana 
 panup...@gmail.com wrote:

  Hi Kamil.

 Thanks for suggestion. But the cmds deleteUI/window modules can't seem
 to detect the PyQt window's titles :(


 On Mon, Jan 9, 2012 at 5:31 PM, Kamil Hepner hektor1...@gmail.comwrote:

 It's very simple:


 winName = myWindow
 if pm.windows.window(winName, exists=True):
pm.windows.deleteUI(winName)


 2012/1/9 Panupat Chongstitwattana panup...@gmail.com

 In Maya 2010, if I run the script to start a UI that is already
 running, it would crash Maya D: How can I check if the UI is already
 running and close it?

 --
 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


  --
 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




 --
 --:: Kurian ::--

  --
 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




 --
 David Moulder
 http://www.google.com/profiles/squish3d

 --
 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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] PyQt - how to check if UI is already running?

2012-01-09 Thread Kurian O.S
Aha I didnt see that and it wont work previous version and he should use
pumbthread in that case ..

On Mon, Jan 9, 2012 at 11:19 AM, Justin Israel justinisr...@gmail.comwrote:

 It should be in the sdk directory and not in your path just yet. But if
 you cant find it:
 http://code.google.com/p/svnformaya/source/browse/trunk/pumpThread.py?r=3



 On Jan 9, 2012, at 8:14 AM, Justin Israel justinisr...@gmail.com wrote:

 Kurian, he is using maya 2010 before they rewrote it in qt. so I don't
 believe MQtUtil even exists. The pumpThread utility is what he needs. It
 creates a fakey event loop that keeps processing events from qt as they
 stack up and also takes care of the global qapp that will be shared. There
 is actually no global qapp being used by maya.



 On Jan 9, 2012, at 6:07 AM, Kurian O.S kuria...@gmail.com wrote:

 O otherwise you can try using this

 import sip
 import maya.OpenMayaUI as mui
 from PyQt4.QtCore import *
 from PyQt4.QtQtGui import *

 def getMayaWindow():
 ptr = mui.MQtUtil.mainWindow()
 return sip.wrapinstance(long(ptr), QObject)

 class Form(QDialog):
 def __init__(self, parent=None):
 super(Form, self).__init__(parent)
 self.setObjectName('mainUI')
 self.mainLayout = QVBoxLayout(self)
 self.myButton = QPushButton('myButton')
 self.mainLayout.addWidget(self.myButton)

 global app
 global form
 app = qApp
 form = Form(getMayaWindow())
 form.show()

 PS :  PyQt4.QtCore import * is not really a good idea at all.

 On Mon, Jan 9, 2012 at 9:01 AM, Panupat Chongstitwattana 
 panup...@gmail.com wrote:

 David - does pumpThread come with Maya 2010?

 I'll try it out once I get to my studio tomorrow, thanks :)



 On Mon, Jan 9, 2012 at 7:57 PM, David Moulder 
 da...@thirstydevil.co.ukwrote:

 You are using pumpThread right?

 If so you shouldn't do sys.exit(app.exec_())

 just myapp.show()

 If your not using pumpThread you have to in Maya 2010.

 You can find pumpThread in the sdk folder.  From memory you need to
 import it and initialize it before any Qt Gui is created.

 import pumpThread as pt
 pt.initializePumpThread()

 -Dave


 On Mon, Jan 9, 2012 at 12:31 PM, Panupat Chongstitwattana 
 panup...@gmail.com wrote:

 Kamil

 The UI class is Ui_AddPlayblast.py. The set title line looks like this

 AddPlayblast.setWindowTitle(QtGui.QApplication.translate(AddPlayblast,
 Manual Add Playblast, None, QtGui.QApplication.UnicodeUTF8))

 I tried using both AddPlayblast and Manual Add Playblast to no
 avail. Is there anything else I should try?


 Kurian - the UI script will be run exclusively in Maya. As I
 understand, the __name__ = __main__ only works if you run the py file
 directly? Initally I'm launching the UI with these commands

 app = QtGui.QApplication(sys.argv)
 myapp = AddPlayblast()
 myapp.show()
 sys.exit(app.exec_())

 I tested it out in another function, and it is this line that freezes
 Maya

 myapp = AddPlayblast()


 best regard,
 Panupat C.


 On Mon, Jan 9, 2012 at 7:04 PM, Kurian O.S kuria...@gmail.com wrote:

 you can use

 class MyApp (QApplication):
  

 if __name__ == '__main__':
 app = MyApp( sys.argv)
 if app.isRunning():
 ... do whatevr u want


 On Mon, Jan 9, 2012 at 5:30 PM, Ricardo Viana cgolhei...@gmail.comwrote:

 Humm. It should. Check you have your naming right on the .ui for
 window widget.

 Best regards
 Ricardo Viana

 On Jan 9, 2012, at 11:56 AM, Panupat Chongstitwattana 
 panup...@gmail.com wrote:

  Hi Kamil.

 Thanks for suggestion. But the cmds deleteUI/window modules can't
 seem to detect the PyQt window's titles :(


 On Mon, Jan 9, 2012 at 5:31 PM, Kamil Hepner hektor1...@gmail.comwrote:

 It's very simple:


 winName = myWindow
 if pm.windows.window(winName, exists=True):
pm.windows.deleteUI(winName)


 2012/1/9 Panupat Chongstitwattana panup...@gmail.com

 In Maya 2010, if I run the script to start a UI that is already
 running, it would crash Maya D: How can I check if the UI is already
 running and close it?

 --
 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


  --
 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




 --
 --:: Kurian ::--

  --
 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

Re: [Maya-Python] getting Maya's version with python

2011-12-09 Thread Kurian O.S
cmds.about(version=true)

On Friday, December 9, 2011, Panupat Chongstitwattana panup...@gmail.com
wrote:
 Thanks!

 I also found sys.argv[0] which contains the path to maya.exe. It
 depends on where you install your Maya, but the default location will
 have 2011, 2012 in the string we can check also.



 On Fri, Dec 9, 2011 at 3:35 PM, 张宇 1988he...@gmail.com wrote:
 from pymel import versions

 versions.current()


 2011/12/9 Panupat Chongstitwattana panup...@gmail.com

 This one seems to give me a pop up window. Is there a to get the
 version into a string without the pop up?



 On Fri, Dec 9, 2011 at 2:56 PM, Kurian O.S kuria...@gmail.com wrote:
  cmds.about() ?
 
 
  On Friday, December 9, 2011, Panupat Chongstitwattana
  panup...@gmail.com
  wrote:
  Is there a Python command I can use to get the version of Maya it's
  running in? 2010, 2011, 2012 etc.
 
  --
  view archives: http://groups.google.com/group/python_inside_maya
  change your subscription settings:
  http://groups.google.com/group/python_inside_maya/subscribe
 
 
  --
  --:: Kurian ::--
 
  --
  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




 --
 http://thatboy.me


 --
 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


-- 
--:: Kurian ::--

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


Re: [Maya-Python] getting Maya's version with python

2011-12-09 Thread Kurian O.S
import maya.cmds as cmds

v = cmds.about(version=True)

print v


please check the about command help from maya you can get a lot of data
from the help

On Fri, Dec 9, 2011 at 2:54 PM, Kurian O.S kuria...@gmail.com wrote:

 cmds.about(version=true)

 On Friday, December 9, 2011, Panupat Chongstitwattana panup...@gmail.com
 wrote:
  Thanks!
 
  I also found sys.argv[0] which contains the path to maya.exe. It
  depends on where you install your Maya, but the default location will
  have 2011, 2012 in the string we can check also.
 
 
 
  On Fri, Dec 9, 2011 at 3:35 PM, 张宇 1988he...@gmail.com wrote:
  from pymel import versions
 
  versions.current()
 
 
  2011/12/9 Panupat Chongstitwattana panup...@gmail.com
 
  This one seems to give me a pop up window. Is there a to get the
  version into a string without the pop up?
 
 
 
  On Fri, Dec 9, 2011 at 2:56 PM, Kurian O.S kuria...@gmail.com wrote:
   cmds.about() ?
  
  
   On Friday, December 9, 2011, Panupat Chongstitwattana
   panup...@gmail.com
   wrote:
   Is there a Python command I can use to get the version of Maya it's
   running in? 2010, 2011, 2012 etc.
  
   --
   view archives: http://groups.google.com/group/python_inside_maya
   change your subscription settings:
   http://groups.google.com/group/python_inside_maya/subscribe
  
  
   --
   --:: Kurian ::--
  
   --
   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
 
 
 
 
  --
  http://thatboy.me
 
 
  --
  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
 

 --
 --:: Kurian ::--




-- 
--:: Kurian ::--

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


Re: [Maya-Python] getting Maya's version with python

2011-12-08 Thread Kurian O.S
cmds.about() ?

On Friday, December 9, 2011, Panupat Chongstitwattana panup...@gmail.com
wrote:
 Is there a Python command I can use to get the version of Maya it's
 running in? 2010, 2011, 2012 etc.

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


-- 
--:: Kurian ::--

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


Re: [Maya-Python] How to embed a modelPanel into a Qt Layout

2011-11-20 Thread Kurian O.S
Hi Justin,

thanks for the example man , this is so cool and when I try to run , I got
this

# Error: 'parent' is not a Qt property or a signal

# Traceback (most recent call last):

# File maya console, line 9, in module

# File maya console, line 14, in __init__

# AttributeError: 'parent' is not a Qt property or a signal #


any idea ?

On Mon, Nov 21, 2011 at 9:45 AM, Panupat Chongstitwattana 
panup...@gmail.com wrote:

 Wow Justin. Thanks for showing us that example. It's great reference.
 Do you cover that in your cmiVFX tutorial too?

 Panupat C.

 On Mon, Nov 21, 2011 at 10:07 AM, Justin Israel justinisr...@gmail.com
 wrote:
  Hah, ya I had a feeling.
  Now that I am home, I was able to write out an example:
  https://gist.github.com/1381489
  Its more complicated because you have to use sip and the MQtUtil
 function to
  translate between maya node paths, and QObjects/QWidgets
  Here is what the script is doing:
  1. Create the layout in PyQt
  2. Unwrap it from python into a pointer using sip
  3. use the pointer to get the full maya node path
  4. set it as the UI parent
  Then you create the model panel using the commands module
  1. Get a pointer to the underlying widget of the model panel
  2. wrap that into a python QObject using sip
  3. Add that new object into your layout.
  I also added a repaint in the show() method for the QDialog because maya
  likes to really lag in repainting its interface sometimes, so you wouldnt
  see the camera redrawn until you interacted with it otherwise.
  Let me know if any of that example is unclear. Maybe there is a better
 way
  to do this, but this way works fine.
  -- justin
 
 
  On Nov 20, 2011, at 6:18 PM, 张宇 wrote:
 
  Thanks for your reply Justin, I am using pyqt not just the qtDesigner,
 how
  to do that with pyqt?
 
  Http://zhangyu.me
 
  在 2011-11-21,4:38,Justin Israel justinisr...@gmail.com 写道:
 
  Hey there,
 
  You didn't specify if you were actually using PyQt or not. I'm going to
  assume you want to just use Qt Designer,
 
  and then be able to add your modelPanel to the window. There really isnt
  much different from creating this purely in the maya ui commands.
 
  win = cmds.loadUI(f=windowTest.ui)
 
  cmds.setParent(win)
 
  cmds.paneLayout()
 
  m = cmds.modelPanel()
 
  cmds.modelPanel(m, e=True, cam=myCamera)
 
  cmds.showWindow( win )
 
  cmds.refresh(f=True)
 
  In my windowTest.ui file, I simply created a dialog with nothing in it.
  And I have a camera in my scene called myCamera
 
  Sometimes the new maya ui kinda lags in refreshing itself, so you would
 have
  to interact with the new dialog sometimes to
 
  get the camera to redraw.
 
  Are you trying to do this via PyQt? That would have a few more steps
 since
  you need to translate between maya node paths and actual Qt widgets.
 
  -- justin
 
 
 
  On Nov 20, 2011, at 9:08 AM, 宇 wrote:
 
  I want to embed a maya's modelPanel to a Qt's Layout, but i don't know
 
  how?
 
  I just know you can create a window and layouts in QtDesigner and
 
  create the buttons or other controls with coding by PyQt.
 
  But if i want to create a modelPanel with my own camera embed to the
 
  widow created by qt, how?
 
  My english is not good, if you know what i mean, please give me an
 
  answer .
 
  --
 
  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
 
  --
  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
 

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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] How to embed a modelPanel into a Qt Layout

2011-11-20 Thread Kurian O.S
Yeah Justin thats what the issue , i updated with code like this

def __init__(self, parent=None, **kwargs):

super(MyDialog, self).__init__(parent, **kwargs)


then its working and I am using 4.6

On Mon, Nov 21, 2011 at 1:08 PM, jo benayoun jobenay...@gmail.com wrote:

 Hi Justin,

 Actually, I just wrote the function from scratch. Didn't try your
 implementation. Did it now. It works fine, for me on 2012 (don't have 2011
 too).
 To be sure my code always run, I call baseclasses with the oldstyle and
 never make a use of keyword args (to be compatible with older versions of
 sip).
 The super call was mainly designed to resolve baseclasses conflicts in a
 multiple inheritance case and bringing more features to the metaclass
 concept.
 I make a cast to QWidget, since this is something I probably do in cpp.


 http://www.riverbankcomputing.co.uk/static/Docs/PyQt4/html/keyword_arguments.html

 jo

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




-- 
--:: Kurian ::--

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


Re: [Maya-Python] PyQt4 for Maya2012 OSX installer

2011-11-10 Thread Kurian O.S
dont have any make file but maybe some one can make it
http://www.kurianos.com/wordpress/?p=551

On Thu, Nov 10, 2011 at 12:14 PM, Justin justinisr...@gmail.com wrote:

 Hey Everyone,

 I was just wrapping up my next tutorial video, and was doing a bit on
 PyQt4 at the end. I have seen people hosting precompiled windows
 installers but I didnt see one for OSX. I put together a builder:

 http://www.justinfx.com/2011/11/09/installing-pyqt4-for-maya-2012-osx/

 If you use linux and are Makefile savvy, please contribute a linux
 version on github! :-)

 -- justin


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




-- 
--:: Kurian ::--

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