I got a solution from other forum. Since it's mesh data in the memory you 
can use only MDataHandle instead of MFnMesh.

hDrivers = data.inputArrayValue(MyDeformer.aDrivers)


for driverIdx in range(hDrivers.elementCount()):
    status = hDrivers.jumpToElement(driverIdx)
    if status:
        builder = hDrivers.builder()
        builder.addElement(driverIdx)
        hDrivers.setBuilder(builder)
        hDrivers.jumpToElement(driverIdx)


    hDriver = hDrivers.inputValue()
    hDriverMesh = hDriver.child(VertexSnap.aDriverMesh)


    geoIt = OpenMaya.MItGeometry(hDriverMesh)
    print geoIt.count()  # Result: 121

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to python_inside_maya+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/393bc168-9196-4810-a7d5-c70d5a12ef62%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to