Python - How to Get Deformed Point Position?


In a Python Effector, I’m grabbing some point positions from a series of splines.

for i in xrange(0, splinecount):
        new_pos = splines[i].GetPoint(ptnum)
        marr[i].off = new_pos 

All good! Except the splines are deformed, and GetPoint() doesn’t retrieve deformed points. Alas.

I tried this code snippet from 2013, but it seems to only incorporate the object’s matrix rather than deformers (was getting wonky results regardless.)

Any thoughts?




You need to retrieve cache from splines.
need to test


That does seem to be involved, but this thread at the plugin cafe reveals how kludgy it is in reality. Ugh.

Even in some brief tests here, sometimes it returns “None”, other times it gets a result - but the result isn’t the deformed spline. Sigh…

It’s annoying in general, because in Xpresso the Point node just has a toggle for getting deformed points.


Hah, looks like I can now accomplish my needs for the project just by cloning onto the spline. :smiley:


This new example was added in R21 and should covers your needs.

For any further questions, please contact us on


Thanks for sharing. I realize that that sample is accomplishing many things unrelated to this specific task, but it shouldn’t take that many line of code just to get the position of a single point. As much as some cringe at the complexity of Houdini, this task requires just a short snippet of code in that program:


Perhaps a similar function could be implemented such as: GetPosition(ptnum,1) - with the the latter digit being 0 for local and 1 for global.

It’s these sorts of things that encourage/discourage people from creating more complex setups in Cinema.


op.GetDeformCache().GetPoint(ptIndex) should do what you want, unfortunately it will not works in any case as Cinema 4D is a bit more context specific than Houdini.

E.g. a cloner and a cube is an object generator, but they are different, since a cube creates only a cube, while a cloner create a whole hierarchy. So is not the same things, the previous example take care of all of this, but if you read the previous example most of stuff are useless for you special needs.



Thanks Maxime for the info!