Hello everyone,
I am trying to retrieve a position of a uv nurbssurface from a point in space.
For this I use the Maya API.
I tried with a mesh and it works very well. The problem I have with the nurbssurface is that when I run my script Maya plant ...
Is someone already had this problem?
That's the code:
------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------
shape = 'nurbsSphereShape1'
dag_path = maya_api_utils.get_dag_path(shape)
mfn_nurbs = OpenMaya.MFnNurbsSurface(dag_path )
point = OpenMaya.MPoint(0.0, 3.116, 4.508)
u = MScriptUtil().asDoublePtr()
v = MScriptUtil().asDoublePtr()
toto = mfn_nurbs.getParamAtPoint(point, u, v, False)
------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------