Hello,
I've received a problem from a user with an object that our modifier is not translating correctly. What's unique about this setup is that contains "a spline wrap using an external spline to modify a sweep's input spline". Sounds ugly, better to open the attached project. The object we need to cache is Reep, and somewhere inside it there's the Reep-Wrap-03 modifier ( a Spline Wrap). It's strength is 100%, and it cancels out the generator's transform. Any translation and rotation have no effect on the final polygon.
I'using the MCOMMAND_JOIN
modeling command to get a copy of Reep of an object for later processing but the resulting polygon is always offset by the original generator's current transform. If I execute the Make Editable or Current State To Object commands on it, the result is correct, but not using the Join command.
As an example, I'm using this script in Python that gives me the same result as the C++ API. Running it the joined polygon will be offset from the original generator cache. The same script using MCOMMAND_CURRENTSTATETOOBJECT
does not generate the offset.
import c4d
def main() :
olist = [ doc.SearchObject("Reep") ]
settings = c4d.BaseContainer()
res = c4d.utils.SendModelingCommand(command = c4d.MCOMMAND_JOIN, list = olist, bc = settings, doc = doc)
doc.InsertObject(res[0].GetClone())
c4d.EventAdd()
if __name__=='__main__':
main()
Is there anything I can do to get the same result from the JOIN command, without that offset?