Hi all!
I was testing Maya Python API 2.0 and discover what I think is a bug:
import maya.api.OpenMaya as om
import maya.OpenMaya as OpenMaya
# *Create a cube*
mSelList = om.MSelectionList()
omSelList = OpenMaya.MSelectionList()
mSelList.add(pCu*)
mSelList.length()# Result: 328L
Hey Manuel,
Have you tried using a QCompleter? You realize its provided to do this exact
functionality?
http://www.riverbankcomputing.co.uk/static/Docs/PyQt4/html/qcompleter.html
There are a couple different modes it can be set to, one of which being a popup
that narrows down the list as you
Also, the reason its not working right now in your code is because you are
using a QMenu. The default flags and usage for a QMenu are to be a popup type
which is designed to hide when it loses focus. You are calling its exec method
which will force it to act like a popup .
You would want to
Hey,
I'm creating an instance of Phonon.VideoPlayer in my UI and every time
I instantiate the player it allocates about 40mb or memory I can't
seem to get back. This is the call:
player = Phonon.VideoPlayer(Phonon.VideoCategory,self)
I've tried player.stop(), del player, I've done a sip
Report the bug?
http://usa.autodesk.com/adsk/servlet/item?id=12331406siteID=123112SelProduct=Maya
Also, the results == 2 sounds correct, but what is the actual content of the
selection list for api.OpenMaya?
What are those 328 items?
On May 7, 2012, at 3:38 AM, Narann wrote:
Hi all!
I was
Just tested in 2013:
import maya.api.OpenMaya as om
import maya.OpenMaya as OpenMaya
# *Create a cube*
mSelList = om.MSelectionList()
omSelList = OpenMaya.MSelectionList()
mSelList.add(pCu*)
print mSelList.length()
omSelList.add(pCu*)
print omSelList.length()
2
2
On May 7, 2012, at
I should also mention, I'm using Python 2.6.4, PyQt 4.4.4 and SIP
4.7.9 just in case it has any version relevance.
On May 7, 10:27 am, loked judd...@gmail.com wrote:
Hey,
I'm creating an instance of Phonon.VideoPlayer in my UI and every time
I instantiate the player it allocates about 40mb
Can you confirm those versions? They don't seem right. What version of maya?
Also, how are you verifying that the memory is a leak (and for what OS?).
Memory can still report higher and it doesn't mean its in use. The operating
system could take it back. The only way to know if its a leak is to
Using Maya 2011 X64 on Windows 7
I checked versions with
sys.version
QtCore.PYQT_VERSION_STR
sip.SIP_VERSION_STR
not sure how else to check them.
I haven't done any proper profiling (not too familiar with how to do that
in Python). I'm just looking in the task manager and Maya goes up every
QtCore.QT_VERSION_STR
QtCore.PYQT_VERSION_STR
Those versions seemed low for 2011
I would recommend:
Qt 4.5.3
Sip 4.10
PyQt 4.7.3
That aside, do you mean that every time you create a phonon object, the memory
keeps increasing by 40mb? Or is it a one time increase?
On May 7, 2012, at 11:17 AM,
Unfortunately the company I'm working for can't change the versions. It's
increasing the memory every time I create the phonon object. I have a bunch
of vids, so every time I hit play I create the object and then in the
finished() I want to release it.
On Mon, May 7, 2012 at 11:32 AM, Justin
Judd!!
are you able to hide and show the phonon object and reuse it, instead of
creating a new instance every time? This doesn't fix memory leak but stops
more memory being allocated.
On Mon, May 7, 2012 at 11:55 AM, Judd Simantov judd...@gmail.com wrote:
Unfortunately the company I'm working
Hey Damon!
I probably could do some trickery where I only ever have one player, but it
would require me to do all kinds of UI parenting, and restructuring that
will just make the code and design super ugly :) That might be a good last
resort if there is no alternative.
Does anyone know if this
I can confirm that it wasn't an issue for me probably as early as Qt 4.7 (and
possibly 4.5, I cant remember). I had an app that was constantly loading and
unloading phonon players and I watched the memory release when I cleared the
source each time.
You should probably just install a newer
Yeah, I reckon that's the easiest. I was just hoping there was something I was
missing, but this combined with old style connections and using QStrings is
enough reason to push for an upgrade :)
Thanks again for the help!
Sent via my BlackBerry from Vodacom - let your email find you!
15 matches
Mail list logo