Yes, seems that older versions of maya didn't mind the lack of
createFromInt() but 2011 seems to require that. I've adjusted the tool
to work like the example below when it comes to using MScriptUtil.
create MScriptUtil
allocate space for it
point it at a data type
pass the pointer into function
get the value of what the pointer is looking at.
import maya.OpenMaya as openMaya
sel=openMaya.MSelectionList()
openMaya.MGlobal().getActiveSelectionList(sel)
path=openMaya.MDagPath()
obj=openMaya.MObject()
sel.getDagPath(0, path, obj)
compItr = openMaya.MItSurfaceCV(path, obj)
while not compItr.isDone():
u = openMaya.MScriptUtil()
u.createFromInt(100)
uPtr = u.asIntPtr()
v = openMaya.MScriptUtil()
v.createFromInt(100)
vPtr = v.asIntPtr()
compItr.getIndex(uPtr, vPtr)
print openMaya.MScriptUtil().getInt(uPtr)
print openMaya.MScriptUtil().getInt(vPtr)
compItr.next()
--
http://groups.google.com/group/python_inside_maya