Message 1 of 2

Not applicable
10-13-2017
05:22 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello,
I'm new to maya and I'm trying to write a script that creates a lattice deformation and deforms a mesh up until a certain point and then stops. I'm able to query the vertices of my mesh, but not sure how to get the coordinates of the deformed mesh vertices
An example of what I'm trying to do:
maya.lattice(model_name, dv=(5, 2, 5), ldv=(5, 2, 5), objectCentered=True) maya.select('ffd1Lattice.pt[0][0:1][0]') maya.move(-0.5, 0, 0, relative=True) maya.select('ffd1Lattice.pt[4][0:1][0]') maya.move(0.5, 0, 0, relative=True) children = maya.listRelatives(model_name, allDescendents=True, noIntermediate=True, fullPath=True) meshes = maya.ls(children, type="mesh") for mesh in meshes: mesh_verts = maya.xform(mesh + '.vtx[*]', ws=True, t=True)
# Not sure how to find this: deformed_verts = maya.xform(*lattice mesh output* + '.vtx[*]', ws=True, t=True)
Could anyone help me find a way to approach this?
Solved! Go to Solution.