Re: [Maya-Python] Re: [ANN] Plow: Open Source Render Farm Software for VFX

2014-01-22 Thread Justin Israel
Hey Marcus, While I would be more than happy to write a post-mortem on the topic, to be honest it is actually not dead. The open source project is coming back around summer time. The reasons behind why it disappeared are related to employment contract issues, and stuff that I can't get too detail

Re: [Maya-Python] Re: [ANN] Plow: Open Source Render Farm Software for VFX

2014-01-22 Thread Justin Israel
was surprised to see it gone. > > Looking forward to reading more about it this summer. > > > On 23 January 2014 03:08, Justin Israel wrote: > >> Hey Marcus, >> >> While I would be more than happy to write a post-mortem on the topic, to >> be honest it is act

Re: [Maya-Python] Remaping 3 dimensional vector to 255 rgb

2014-01-24 Thread Justin Israel
Yea at first I was going to suggest a fit function, because it seemed you wanted to remap your float 0-1 values to a new range between 0-255 ( or 20-235, etc). But towards the end of your later reply it does seem like you need to take a LUT into consideration. If your float values are already mappe

Re: [Maya-Python] Remaping 3 dimensional vector to 255 rgb

2014-01-24 Thread Justin Israel
[170]: fit_b([.33, .45, .785736]).round().astype(int) Out[170]: array([159, 184, 229]) On Sat, Jan 25, 2014 at 9:16 AM, Justin Israel wrote: > Yea at first I was going to suggest a fit function, because it seemed you > wanted to remap your float 0-1 values to a new range between 0-255 (

Re: [Maya-Python] Re: Noob question - trying to delete all faces in -x

2014-01-27 Thread Justin Israel
Nice work Pedro. And just to nitpick a little on it, I might suggest a few tweaks: ##=== sel = cmds.ls(sl=1) # save this so we don't have to constantly # index into the array firstItem = sel[0] faceCount = cmds.polyEvaluate(firstItem, face=1) negativeFaces = [] # xrange instead of range in cas

Re: [Maya-Python] Re: Noob question - trying to delete all faces in -x

2014-01-28 Thread Justin Israel
Do you want to know if the center is positive X or if any part of the face is positive X? If you just want to know if a face crosses or is in negative x then you could get the boundingBox with polyEvaluate, and check if the minX is negative. If you want the center, the Maya API can tell you it (is

Re: [Maya-Python] Sphinx help

2014-01-28 Thread Justin Israel
Hey Mark, Can you post some examples of both your .rst and a class + docstring? I'm using sphinx for a few projects as well, and will use a mixture of both the autodoc features, and the manual stuff. The autodoc module/class features have properties that can control what it documents. In one of m

Re: [Maya-Python] QTreeView and QStandardItem row height

2014-01-30 Thread Justin Israel
Hey Robert, When using a QTreeView, you have to control the row height by setting a custom QItemDelegate on the view: http://qt-project.org/doc/qt-4.8/qabstractitemview.html#setItemDelegate This QItemDelegate can have a custom sizeHint which let's you choose how big it should be given a current s

Re: [Maya-Python] mayaPy does not find mel procedure

2014-01-30 Thread Justin Israel
Did you initialize maya standalone? import maya.standalone maya.standalone.initialize() Also, do you need to be able to call the mel command, or can you use the maya cmds module? http://download.autodesk.com/global/docs/maya2014/en_us/CommandsPython/batchRender.html On Fri, Jan 31, 2014 at 8:

Re: [Maya-Python] Re: "optionVar" of python ???

2014-02-04 Thread Justin Israel
A few more bits about shelve vs json. shelve is actually not a serialization format specifically, but rather a key-value store that serializes its values using pickle. It stores like a database and has the added benefit of letting you modify in-memory, piecemeal over time, until it gets flushed to

Re: [Maya-Python] python DLLs

2014-02-06 Thread Justin Israel
I don't know much about windows + python extension but it seems strange that it would work when they are placed in system32. Is system32 part of the pythonpath? These are definitely python extensions? On Feb 7, 2014 12:32 PM, "Todd Widup" wrote: > so we are setting some paths in a powershell befo

Re: [Maya-Python] PySide Maya 2014 - QTableWidget not showing Header Labels

2014-02-07 Thread Justin Israel
Are you calling listWidget.clear() somewhere before adding your items? If so, try replacing that with clearContent(). It won't clear your headers. Otherwise can you post a small runnable example that exhibits the problem so we can reproduce it and debug? On Feb 8, 2014 8:43 AM, "olheiros" wrote:

Re: [Maya-Python] PySide Maya 2014 - QTableWidget not showing Header Labels

2014-02-07 Thread Justin Israel
On Sat, Feb 8, 2014 at 10:25 AM, Ricardo Viana wrote: > aaahhh dead on justin. as always:) > > thank you so much. > > > On Friday, February 7, 2014, Justin Israel wrote: > >> Are you calling listWidget.clear() somewhere before adding your items? If >> so, try r

Re: [Maya-Python] PySide Maya 2014 - QTableWidget not showing Header Labels

2014-02-07 Thread Justin Israel
at, Feb 8, 2014 at 9:10 AM, Ricardo Viana wrote: > >> lol. :) >> >> >> >> >> >> On Friday, February 7, 2014, Justin Israel >> wrote: >> >>> Confession. I actually don't know how to code. I have another secret >>> forum that I fo

Re: [Maya-Python] Passing variables (inheritance?) between classes

2014-02-08 Thread Justin Israel
What you have here is a base class, called Connector, and a subclass called Spring. When you create a subclass, it inherits all of the superclass functionality. Additionally, when you implement your constructor on the Spring class, and call super(), you are triggering the superclass constructor. I

Re: [Maya-Python] Re: Passing variables (inheritance?) between classes

2014-02-08 Thread Justin Israel
Sure. Feel free to update with more questions as you explore. On Feb 9, 2014 11:47 AM, "flaye" wrote: > @Justin...Thank you very much for your detailed and informative reply. > It's greatly appreciated. > Cheers! > > > > On Saturday, February 8, 2014 4:05:01 PM UTC-5, flaye wrote: >> >> >> Hi, >>

Re: [Maya-Python] OOP / PySide question

2014-02-10 Thread Justin Israel
Hey, Your QtCore.Qt.DisplayRole is just, as it says, for displaying the value, which would be a string. You can actually store any custom amount of roles you want by using: thisRole = QtCore.Qt.UserRole thatRole = QtCore.Qt.UserRole + 1 So that means you can easily store complex objects in one r

Re: [Maya-Python] pyside issue

2014-02-10 Thread Justin Israel
I forget. Do they include shiboken Python libs with 2014 or did you have to build them? Does it do this directly from the script editor when you just import PySide and Shiboken, and try to wrap the Maya main window? On Feb 11, 2014 1:19 PM, "Todd Widup" wrote: > # return shiboken.wrapInstan

Re: [Maya-Python] pyside issue

2014-02-10 Thread Justin Israel
Todd Widup" wrote: > Doesn't error on import so assuming its included. > > Directly in the script editor or on import > > Sent from my tiny iPad with big fingers > > > On Feb 10, 2014, at 9:45 PM, Justin Israel wrote: > > I forget. Do they include shiboken Pyt

Re: [Maya-Python] pyside issue

2014-02-11 Thread Justin Israel
Yea im just lobbing Hail Mary guesses. On Feb 11, 2014 9:14 PM, "Todd Widup" wrote: > Ill check it once I'm in the office tomorrow. > > They should be. I can't think of any place it might get them from > > Sent from my tiny iPad with big fingers > > >

Re: [Maya-Python] OOP / PySide question

2014-02-12 Thread Justin Israel
t; Any ideas? >> >> I have looked into QItemDelegate and for now it seems a bit too much sand >> for my wagon. >> Have to investigate it better. MVC was already a big step for me. >> >> you can see pic of what i mean attached. >> >> h

Re: [Maya-Python] open txt - string conversion issue

2014-02-12 Thread Justin Israel
Well lets break down the steps of what you are doing in that one-liner when you read the file: 1. # open the file for reading open("D:\Store\Maya\Globals.txt","r") 2. # reads the entire file at once and splits into lines, retaining the trailing newline character .readlines() 3

Re: [Maya-Python] Creating dynamic tabs in UI

2014-02-13 Thread Justin Israel
Did you mean to keep the second half of your layout code indented in the for loop or is that a typo? Starting with self.mainForm=mc.formLayout() That happens once for every loop, replacing the references from the last iteration. On Feb 14, 2014 6:18 AM, "flaye" wrote: > Hi, > > I'm trying

Re: [Maya-Python] OOP / PySide question

2014-02-14 Thread Justin Israel
Ya nice work! For the checkbox, if you are only concerned with on/off, then use isChecked(). Like Marcus said, checkState() would be relevant if you were also considering half checked and you would want to use the constants to test it instead of int/bool A couple notes on your gist: - 34: I

Re: [Maya-Python] Need direction; renderview

2014-02-15 Thread Justin Israel
I've taken viewports and embedded them into my own Qt app to provide independent scene navigation. If the renderview is a Singleton instance, then it wouldn't work the same way that I have done it. My approach has been to create a new viewport to embed. On Feb 16, 2014 1:50 AM, "Mark Serena" wrot

Re: [Maya-Python] Need direction; renderview

2014-02-15 Thread Justin Israel
on your website to embed Maya windows in > qt, but changing the modelpanel from persp/camera to renderview threw an > error line 1 with no other info. > On Feb 16, 2014 9:35 AM, Justin Israel wrote: > > I've taken viewports and embedded them into my own Qt app to provide

Re: [Maya-Python] Need direction; renderview

2014-02-15 Thread Justin Israel
o one else is viewing it you could grab it back automatically. On Sun, Feb 16, 2014 at 12:08 PM, Justin Israel wrote: > I can give it a test later today and report back. > On Feb 16, 2014 12:01 PM, "Mark Serena" wrote: > >> Yeah, doing it once it's rendered and

Re: [Maya-Python] Need direction; renderview

2014-02-15 Thread Justin Israel
Hah, ya no worries. This wasn't the type of question I had posted about. It was based on my existing previous example, and more theoretical about how much could be done with the render view panel. I was interested in testing it. Technically mostly everything in the Maya UI can be hijacked to some

Re: [Maya-Python] Need direction; renderview

2014-02-15 Thread Justin Israel
; watching your cmiVFX vid on PyQt and also got the one off CGSociety, so > hopefully I'll feel less lost soon. > Thanks again Justin. > > > On Sun, Feb 16, 2014 at 12:35 PM, Justin Israel wrote: > >> Hah, ya no worries. This wasn't the type of question I had posted

Re: [Maya-Python] Re: open txt - string conversion issue

2014-02-16 Thread Justin Israel
CPython does close the file when it gets garbage collected, so it depends how long you hold on to the references, if at all. But closing it explicitly (or by the with context) does give you precise control of when you are freeing that resource. And it is apparently not guaranteed to close during ga

Re: [Maya-Python] Version control in production

2014-02-16 Thread Justin Israel
> > Most of the production application files are binary, and popular version >> control solutions/ideas are code/ascii-oriected, >> > git tracks ascii or binary files by hashing their content. If the file is ascii, then it can provide the extra tools for diff, merge, changes, ... > which make the

Re: [Maya-Python] Re: Creating dynamic tabs in UI

2014-02-16 Thread Justin Israel
Sure you can make the tabs build their functionality dynamically. It just depends on what criteria they base their decisions. If you have N number of "types" of tabs then you can make different builder functions for each, and map them to their "type" in a dict. Or if it is even more dynamic, like b

Re: [Maya-Python] Need direction; renderview

2014-02-16 Thread Justin Israel
on the right track with >> that one. >> >> Best of luck, >> >> Joe >> >> >> On 2/15/2014 5:39 PM, Mark Serena wrote: >> >> Cool, well there's a lot of new territory for me to cover, I'm >> currently watching your cmiVFX vid on PyQt a

Re: [Maya-Python] Need direction; renderview

2014-02-16 Thread Justin Israel
m pyside. I figured more examples for pyqt and later I'll > swap over if necessary. > Have seen some convert scripts to change it over. > Is it easy enough to change it over later? > > Thanks guys > > On Feb 17, 2014 9:06 AM, Justin Israel wrote: > > > > Also i

Re: [Maya-Python] Item Delegates in a QAbtstractItemModel ...

2014-02-17 Thread Justin Israel
Maybe olheiros could share his code for a full example. Did you implement the methods described in the previous thread, and then call openPersistentEditor() on the cells in your column? On Tue, Feb 18, 2014 at 9:23 AM, Geoff Harvey wrote: > This is actually kind of a follow-up to olheiros' ques

Re: [Maya-Python] Re: Item Delegates in a QAbtstractItemModel ...

2014-02-18 Thread Justin Israel
You might want to test that theory. I would think a QLineEdit painting itself in C++ as a persistent editor might be faster than you painting the look of a QLineEdit in python. If your goal is to indicate which cells are editable, I am sure you could use some other decoration approach like slightly

Re: [Maya-Python] Re: Creating dynamic tabs in UI

2014-02-18 Thread Justin Israel
seUI class, it had the window/showWindow commands. If I modify only one > variable in it, shouldn't it display the window along with the updated > variable? > I hope that makes sense. > > Thanks! > > > > > On Sunday, February 16, 2014 2:44:24 PM UTC-5, Justin Israel wro

Re: [Maya-Python] Simple question - hyperShade command

2014-02-19 Thread Justin Israel
Ya, they take the name of a node, and also the hyperShade command doesn't use an argument. Just keyword params: http://download.autodesk.com/global/docs/maya2012/en_us/CommandsPython/hyperShade.html If you want the textures connected to the shader, then maybe you actually want the upstream nodes?

Re: [Maya-Python] Simple question - hyperShade command

2014-02-19 Thread Justin Israel
: >> >> You're right - that'll teach me to pay more attention to the flags. And >> you're correct Justin, I should have used the lun flag to get the rest of >> the network. >> >> Thank you both! >> >> On Wednesday, February 19, 2014

Re: [Maya-Python] OOP / PySide question

2014-02-20 Thread Justin Israel
It is probably because when its not a persistent editor, the view triggers the completion of the edit as each cell loses focus and the editor goes away. But when you are using persistent editors, the widget is always there. The delegate/model never see any interaction. Only the check box is seeing

Re: [Maya-Python] OOP / PySide question

2014-02-20 Thread Justin Israel
What version of Qt are you using? I typed that from my phone :-) On Feb 21, 2014 8:09 AM, "Ricardo Viana" wrote: > Its strange because i thought that could be a pyside thing but in the docs > > they document it as a method which takes the editor widget. > > PySide.QtGui.QAbstractItemDelegate.comm

Re: [Maya-Python] OOP / PySide question

2014-02-20 Thread Justin Israel
because I was using partial() here as a wrapper, it was literally trying to call the signal like a function. It needed the explicit emit() to be wrapped. On Fri, Feb 21, 2014 at 1:31 PM, Justin Israel wrote: > What version of Qt are you using? I typed that from my phone :-) > On Feb 21, 2014 8

Re: [Maya-Python] OOP / PySide question

2014-02-21 Thread Justin Israel
It's trying to pass the toggled bool value as an extra argument. Probably should be more like this: def createEditor(self, parent , option, index): container = QtGui.QWidget(parent) layout = QtGui.QHBoxLayout() layout.setAlignment(QtCore.Qt.AlignCenter | QtCore.Qt.AlignCenter) layo

Re: [Maya-Python] OOP / PySide question

2014-02-21 Thread Justin Israel
e working with > tens or hundreds, I would recommend going with plain widgets. > > > On 21 February 2014 19:36, Justin Israel wrote: > >> It's trying to pass the toggled bool value as an extra argument. Probably >> should be more like this: >> >> def cre

[Maya-Python] MayaSublime: fix for MEL comments

2014-02-22 Thread Justin Israel
Hey all, Someone posted an issue regarding my MayaSublime plugin for SublimeText, in how it handles MEL source code that contains lines with trailing comments, and also with multi-line comments. https://github.com/justinfx/MayaSublime/issues/21 I committed a change in how I format and send the M

Re: [Maya-Python] PyQt/Pyside

2014-02-23 Thread Justin Israel
se days" list for me. My tool is for my Master's > Thesis, and part of the original specification was that it would run on any > version of Maya that supports Python. I got an adjustment to allow for > PyQt, but if I moved to PySide I'd at the very least have to set up dual

Re: [Maya-Python] PyQt/Pyside

2014-02-24 Thread Justin Israel
ut >> that adds other issues with some of my rigs. >> >> >> On Mon, Feb 24, 2014 at 5:42 AM, David Moulder >> wrote: >> >>> I've had this in 2014 a few times. Just one UI didn't respond to >>> signals. Then every now and again it woul

Re: [Maya-Python] object1.f[38] in [object2.f[38]] == True?

2014-02-25 Thread Justin Israel
I don't know much about the PyMel class structures, but it seems something is not defined properly for the __eq__ or __cmp__ methods of the base class, to reflect that they are different objects. There is a lot of inheritance in there so I am not really sure where to trace it back to f1 = pm.MeshF

Re: [Maya-Python] whats your approach for integrating Qt Designer files in your workflow

2014-02-28 Thread Justin Israel
cmds.loadUI() is a really limited approach to loading Qt Designer UI files. It immediately converts everything to Maya controls and gives you back a path. This approach kind of expects that you will do the thing where you create dynamic properties inside of Designer, on your widgets, that will be t

Re: [Maya-Python] Re: whats your approach for integrating Qt Designer files in your workflow

2014-03-02 Thread Justin Israel
The tool flag for the window is only one part of what you need. The other part is that you have to tell your window to use the Maya main window as its parent. Otherwise the tool window you create doesn't know what to remain on top of. #- import maya.OpenMayaUI as mui import sip def getMayaWin

Re: [Maya-Python] shiboken.getCppPointer() crashes Maya

2014-03-06 Thread Justin Israel
I had to correct the syntax to: as_ptr = long(shiboken.getCppPointer(orig)[0]) But it didn't crash for me. This is with the latest brew install of PySide on osx On Fri, Mar 7, 2014 at 6:45 AM, Danny Wynne wrote: > I'm wondering if anyone else has experienced this and has a work around? > May

Re: [Maya-Python] shiboken.getCppPointer() crashes Maya

2014-03-06 Thread Justin Israel
7, maya 2014) > > Danny Wynne > www.dannywynne.com > > > On Thu, Mar 6, 2014 at 11:51 AM, Justin Israel wrote: > >> I had to correct the syntax to: >> >> as_ptr = long(shiboken.getCppPointer(orig)[0]) >> >> But it didn't crash for me. This is with the latest br

Re: [Maya-Python] shiboken.getCppPointer() crashes Maya

2014-03-06 Thread Justin Israel
ost by Nathan Horne says you have to modify the > shiboken method to get the right pointer ( to get the equivalent of what > sip would return to you): > http://nathanhorne.com/?p=485 > > > On Thu, Mar 6, 2014 at 5:42 PM, Justin Israel wrote: > >> I don't have a Maya 20

Re: [Maya-Python] Maya cmds ui item parented to pyside

2014-03-09 Thread Justin Israel
Yes you could get the reference to the widget using maya.OpenMayaUI.MQtUtil, and shiboken. But that does still leave you with a sort of black hole beneath it. Does it gain you much? On Mar 10, 2014 8:19 AM, "Johan Forsgren" wrote: > Hi list, sorry for this, I know this has been covered before som

Re: [Maya-Python] Making a variable with a variable in the name.

2014-03-12 Thread Justin Israel
I have seen this similar question come up a few times via stackoverflow. Its is basically someone wanting to make "dynamically named variables". And it usually results in the same answer: There are usually better ways to solve the problem, and a dict is commonly one of them. You pretty much never w

Re: [Maya-Python] Re: I install pyqtx on lion but still can't find pyqt4

2014-03-12 Thread Justin Israel
I'm not sure what you don't have as a windows user... but if you are using a standard python intepreter in a shell to test this, then you must create a QApplication before creating widgets app = QtGui.QApplication([]) In my tutorials when I use ipython --gui, it will create one for you and start

Re: [Maya-Python] Re: creating object of QtGui.QWidget() throws me out of python iterpreter

2014-03-12 Thread Justin Israel
This is a duplicate of the other thread you posted, but ipython is not a requirement. It is available on win/Mac/Linux and just makes it easier to play around with Qt from the command line because it can start the event loop for you. See other thread for more details. On Mar 13, 2014 4:03 AM, "Malc

Re: [Maya-Python] stdout/stderr, logging, & maya's script editor

2014-03-12 Thread Justin Israel
The comment on that answer seems to answer your or problem here. While you are changing the sys.stdout reference you are only doing it at a point in time. Any module that gets loaded earlier and grabs a reference will have the original. I thought there were already some Maya utilities for interfaci

Re: [Maya-Python] Drawing/Adding QWidgets on top of Maya's Viewport

2014-03-12 Thread Justin Israel
There was a question like this a while back, and I think the conclusion was that it is a bit more complicated: https://groups.google.com/d/msg/python_inside_maya/Ti0KFJivDuQ/xIhVWF2DCgEJ On Tue, Mar 11, 2014 at 6:39 AM, wrote: > Hello, > > I am currently trying to add QWidgets on to Maya's vi

Re: [Maya-Python] PyQT and Parenting Issue

2014-03-16 Thread Justin Israel
) -- justin On Mon, Mar 17, 2014 at 6:06 AM, David Martinez < david.martinez.a...@gmail.com> wrote: > Hello there, > > I'm watching *Justin Israel'*s video on PyQT and I have the following > question: > > Why is it that if a 'QPushbutton' is created w

Re: [Maya-Python] ZeroMQ for RPC

2014-03-17 Thread Justin Israel
I threw that code together when I was first learning ZeroMQ and wanted to play with the idea of making it a simple RPC mechanism. Turned out some guys at RedHat were using it and asked for some more thing, so I expanded it a bit more. I really like ZeroMQ. Its a lot of lower level elements that al

Re: [Maya-Python] ZeroMQ for RPC

2014-03-17 Thread Justin Israel
s what RPC is > all about? RPyC (my only other experience) uses the same concept, except it > publishes them to a separate class (a "Service") that gets passed into the > server upon instantiation. What are you using for RPC currently? > > > On 17 March 2014 18:33, Ju

Re: [Maya-Python] ZeroMQ for RPC

2014-03-17 Thread Justin Israel
t other languages do you find it > useful to bridge with RPC at the moment, and for what? > > > On 17 March 2014 19:33, Justin Israel wrote: > >> I'm not sure what inspired me specifically to do that. It just seemed >> appropriate to make it easy to export functions as ser

Re: [Maya-Python] SublimeText Syntax highlighting?

2014-03-17 Thread Justin Israel
My MayaSublime plugin does include the MEL syntax highlighting. On Tue, Mar 18, 2014 at 12:53 PM, Eric Thivierge wrote: > thanks will give it a shot. > > > Eric Thivierge > http://www.ethivierge.com > > > On Mon, Mar 17, 2014 at 7:32 PM, Fredrik Averp

Re: [Maya-Python] ZeroMQ for RPC

2014-03-18 Thread Justin Israel
r to what ZMQ > does, although ZMQ seems rather closer to the metal and would need more > work to get going. > > Having worked with ZMQ before, what made you switch to Thrift? > > > On 18 March 2014 00:15, Justin Israel wrote: > >> I've never tried to use i

Re: [Maya-Python] ZeroMQ for RPC

2014-03-18 Thread Justin Israel
ttribute of type string, would have to return string and nothing else. > Great in cases where the request and response are known, but for RPC, where > some requests might return a list and others a bool.. I got into trouble. > > Does that sound similar to IDL and if so how does it

Re: [Maya-Python] Why Arts appears in white without maya rendering

2014-03-18 Thread Justin Israel
What do you mean by having the render appear in the Maya graphical interface, and being rendered immediately? Are you saying that after you import your FBX, you don't even see the model in your viewport? Or are you saying that you see it but it is not being displayed live in your viewport the way y

Re: [Maya-Python] ZeroMQ for RPC

2014-03-18 Thread Justin Israel
Report back with your experience with Thrift, since you are able to make comparisons to RPyc. Would be interested to know your impression. On Mar 19, 2014 2:04 AM, "Marcus Ottosson" wrote: > Thanks Justin, things are a lot clearer now. > > > On 18 March 2014 10:43

Re: [Maya-Python] Why Arts appears in white without maya rendering

2014-03-19 Thread Justin Israel
gt; appears in white too. > I have taken it from the Unity asset store, i see that all object taken > from there have this problem. > I have attacched one example. > Thanks. > > > > On Tuesday, March 18, 2014 8:51:45 PM UTC+1, Justin Israel wrote: > >> What do y

Re: [Maya-Python] PyQt and QGridLayout

2014-03-19 Thread Justin Israel
I think you are reinventing the wheel. The PyQt4 source comes with a flowlayout in its example directory: https://github.com/Werkov/PyQt4/blob/master/examples/layouts/flowlayout.py I actually ported that to a QGraphicsLayout and use it for images in a grid. Works great. On Thu, Mar 20, 2014 at 1

Re: [Maya-Python] PyQt and QGridLayout

2014-03-19 Thread Justin Israel
@David, my implementation was a direct port of the example flowlayout.py from a QLayout -> QGraphicsLayout so that I could use it in a QGraphicsScene. I do all of my image result listing there instead of a QWidget system On Thu, Mar 20, 2014 at 12:16 PM, David Martinez < david.martinez.a...@gmail

Re: [Maya-Python] Finding object in scene by name

2014-03-22 Thread Justin Israel
What if you did it through the Maya API, and made use of the actual MObject knowing exactly which node it is pointing at, instead of the ambiguous maya paths? import maya.OpenMaya as om dagFn = om.MFnDagNode() group = dagFn.create("transform", "testGRP") dagFn.setObject(group) groupPath = dagFn.fu

Re: [Maya-Python] Maya PresetPath

2014-03-22 Thread Justin Israel
MAYA_PRESET_PATH ? http://download.autodesk.com/global/docs/maya2014/en_us/index.html?url=files/Environment_Variables_File_path_variables.htm,topicNumber=d30e149667 On Mar 23, 2014 6:05 PM, "illunara" wrote: > Hi everybody > How can i change the Maya's Env to load preset from another folder, >

Re: [Maya-Python] Maya PresetPath

2014-03-23 Thread Justin Israel
Then it would appear that Maya only considers the environment variable once on launch. On Mar 24, 2014 12:06 AM, "Tuan Nguyen" wrote: > Hi Marcus > getEnv and putEnv is Mel command, you can also use Pymel.Util.setEnv and > getEnv, which had same effect as your method. > > However, Maya only find

Re: [Maya-Python] ZeroMQ for RPC

2014-03-24 Thread Justin Israel
. >>> On Mar 19, 2014 2:04 AM, "Marcus Ottosson" >>> wrote: >>> >>>> Thanks Justin, things are a lot clearer now. >>>> >>>> >>>> On 18 March 2014 10:43, Justin Israel wrote: >>>> >>>>> Pr

Re: [Maya-Python] PyQt and QGridLayout

2014-03-24 Thread Justin Israel
Animator > > Email: david.martinez.a...@gmail.com > Website: http://www.elusiveideas.com > > > > > On Thu, Mar 20, 2014 at 12:52 AM, Justin Israel wrote: > >> @David, my implementation was a direct port of the example flowlayout.py >> from a QLayout -> QGra

Re: [Maya-Python] PyQt and QGridLayout

2014-03-25 Thread Justin Israel
ocumentation is, I want > to make sure that I'm looking at the correct elements to get the whole > thing working. > > Cheers > > > -- > David Martinez - Technical Animator > > Email: david.martinez.a...@gmail.com > Website: http://www.elusiveideas.com > >

Re: [Maya-Python] Delete Event after run once

2014-03-31 Thread Justin Israel
If you only want it to capture the mouse click once after you have told it to attach to the widget, then you can try calling removeEventFilter(obj) in the eventFilter() after you have handled the mouse release. That way it will only fire once and not continue processing events. Some other suggesti

Re: [Maya-Python] Delete Event after run once

2014-04-01 Thread Justin Israel
I didn't have time to really test this, but it would be something like this: http://pastebin.com/dWFee2xT It gets rid of the globals inside of Region and just uses my previous suggestion of storing the coordinates locally on the region instance. And it disables itself my removing the event filter

Re: [Maya-Python] Select object to import

2014-04-02 Thread Justin Israel
I think your only option is to import the scene file, move out the things you want to keep, and then delete the rest. On Wed, Apr 2, 2014 at 3:21 PM, illunara wrote: > Hi everybody > I wonder if we can select objects from maya scene to import, instead of > import the whole scene? > Thanks > > -

Re: [Maya-Python] Select object to import

2014-04-02 Thread Justin Israel
+1 to Fredrik's suggestion of loading it in a headless Maya standalone to export what you want. That way your process doesn't have to rely on parsing the scene file format and making assumptions. On Apr 3, 2014 4:15 AM, "Tuan Nguyen" wrote: > To Fredrik > Yeah, i'm working on mayapy too, much ea

Re: [Maya-Python] Select object to import

2014-04-02 Thread Justin Israel
. Header, with versioning and references > 2. Creating nodes > 3. Connecting nodes > 4. Setting attributes > > Any and all of these can be modified without heading into Maya. It's a > convenience not many programs share, can only think of Nuke at the moment, > and one that

Re: [Maya-Python] Select object to import

2014-04-03 Thread Justin Israel
hould have been more clear. I meant that Nuke shared the >> convenience of Maya's .ma files in that they are also easily manipulated as >> strings of text. >> >> >> On 2 April 2014 21:15, Justin Israel wrote: >> >>> But the process limits you t

Re: [Maya-Python] MEL Autocompletion for Sublime and MayaSublime

2014-04-03 Thread Justin Israel
On Fri, Apr 4, 2014 at 8:20 AM, Jan: wrote: > note* by default this file should live here: > > C:\Users\\AppData\Roaming\Sublime Text 3\Packages\MayaSublime > > > 2014-04-03 20:12 GMT+01:00 Jan: : > > Hi All, >> >> Justin Israel made an awesome extension f

Re: [Maya-Python] MEL Autocompletion for Sublime and MayaSublime

2014-04-03 Thread Justin Israel
nly take global procs. > > Also ill add an argument to just do the commands that maya returns with > its help function. This should create a file that resembles the commands > that are listed in the documentation. > > Cheers for the feedback! > Jan. > On 3 Apr 2014 21:00, &quo

Re: [Maya-Python] getting the correct vray.exe from maya.env

2014-04-07 Thread Justin Israel
Also a side note: I've used the userSetup.py as well and actually just hade it run an environment module that was maintained in a central network location. That way the logic could easily be updated and picked up by new launches of Maya without being disted to any user preference locations. This wa

Re: [Maya-Python] RGB, Float values under pointer

2014-04-07 Thread Justin Israel
For all areas of the application that are not the 3D viewport, you can render the widget to an image in memory and then query the color under the cursor: #--- globalPos = QtGui.QCursor.pos() widget = QtGui.QApplication.widgetAt(globalPos) img = QtGui.QImage(widget.size(), QtGui.QImage.Format_

Re: [Maya-Python] Re: [ANN] Plow: Open Source Render Farm Software for VFX

2014-04-08 Thread Justin Israel
> >> Hey Justin, >> >> I'd be interested in contributing whenever the project starts back up. >> >> Chad >> >> >> On Wednesday, January 22, 2014 10:26:42 PM UTC-8, Justin Israel wrote: >> >>> Thanks! Would be cool if you were

Re: [Maya-Python] nested tabLayout refresh problem

2014-04-09 Thread Justin Israel
Ok, don't ask me why this this is really needed, but obviously there is some kind of refresh issue with the nested tabs, and if you make it switch tabs and back programmatically, then it works. This small snippet at the end of your function fixes it with a hack. Note, the commented parts are only n

Re: [Maya-Python] The Request Pattern

2014-04-16 Thread Justin Israel
Just wondering, are you developing a completely new framework based on new concepts, or are you abstracting a layer over existing frameworks with existing concepts? In your diagrams they seem to imply that it is an asynchronous request-reply, but in your code examples they imply a synchronous call

Re: [Maya-Python] The Request Pattern

2014-04-17 Thread Justin Israel
I'm just finding the diagrams don't seem to match the code examples. The examples do suggest a 100% synchronous call. You make the function call and block until you have a result. In that case, what you have is basically an abstraction over one function calling and returning the value of another fu

Re: [Maya-Python] qlistview giving error in maya for windows but working fine on linux

2014-04-17 Thread Justin Israel
Hi I you want to use either pastebin or gist to share code, and provide the URL, that will be helpful. Makes it easy for everyone to look at the code in any environment. If you can, try to share just the simple example that reproduces your problem as opposed to an entire script or application -

Re: [Maya-Python] The Request Pattern

2014-04-18 Thread Justin Israel
In an attempt to reinterpret Matt's comments to reflect my own thoughts, the way it appears to me is that the RFC is a very abstract description of an implementation that wraps existing concepts. It positions itself as if it is proposing something new, but I am not clear on the existing problems th

Re: [Maya-Python] Another set of newbie questions....

2014-04-21 Thread Justin Israel
On Apr 22, 2014 3:49 AM, "Tim Crowson" wrote: > > I've got another set of questions here as I try to wrap my head around how Maya does things. I'm sure these are fairly mundane things in the end... > > 1. I know how to create my own custom menu at launch via userSetup.py, but I'm having trouble un

Re: [Maya-Python] Trouble with adding a command to a menu item

2014-04-22 Thread Justin Israel
Although I am not really sure why you would want to use a callback in the form of instantiating a class. On Wed, Apr 23, 2014 at 9:25 AM, Tony Barbieri wrote: > Sorry, that should read: > > *cmds.menuItem(p=shotsMenu, l='Shot Setup', command=lambda *args, > **kwargs: myTestClass.test())* > > >

Re: [Maya-Python] Trouble with adding a command to a menu item

2014-04-23 Thread Justin Israel
ed, Apr 23, 2014 at 5:48 PM, Marcus Ottosson wrote: > Seems slightly unconventional yes. You would have no way to reference that > class afterwards (unless its a singleton) so why not simply use a function? > > > On 23 April 2014 04:32, Justin Israel wrote: > >> Although

Re: [Maya-Python] Trouble with adding a command to a menu item

2014-04-23 Thread Justin Israel
The problem with lamdas though is they don't create a closure. So they will execute using the scope in which they run, which means if the function you are calling in there is not global then it might not be reachable. It just depends where you have defined that function. On Apr 24, 2014 2:04 AM, "

Re: [Maya-Python] Re: Loading ui files, addItems in QListWidgets

2014-04-27 Thread Justin Israel
Hey Stefan, Are you sure that is the right syntax to be using? a = QtGui.QListWidget(self.listCategory.addItems( category)) This is adding your items to and existing list widget from your UI file, and then creating a new list widget with the None return value. This widget will then most likely b

Re: [Maya-Python] Re: Loading ui files, addItems in QListWidgets

2014-04-27 Thread Justin Israel
self.infoBoxAsset.setTitle("INFO:")) > self.ui_signals() > > def ui_signals(self): > self.btnGather.clicked.connect(self.on_btnGather_clicked) > self.listCategory.itemClicked.connect(self.on_listCategory_clicked) > self.listName.it

Re: [Maya-Python] Re: Loading ui files, addItems in QListWidgets

2014-04-27 Thread Justin Israel
gt; Thanks for the tip. > > Regards > Stefan > > > -- Sent from a phone booth in purgatory > > On Apr 27, 2014, at 23:49, Justin Israel wrote: > > I like Swedish meatballs. Its my favorite reason to go to IKEA. > > Ya you are creating local qwidgets for no reas

<    1   2   3   4   5   6   7   8   9   10   >