I'm wondering if anybody could shed a light on issues I'm having with setting up animCurves through the API, or more specifically the key Tangents.
Basically I've moving our animFormat into API and have pretty much got everything running but one of the regression tests is failing. It seems like the order in which you set the MFnAnimCurve tangent vars affects the resulting curve and how the tangents are built
I'm running the following for key in keys on an MFnAnimCurve to try and rebuild the tangents as per the original ....
crvFnc.setTangentsLocked(kindex, lockedTangents)
if weightedTans:
# only settable if the curve has weighted tangents
crvFnc.setWeight(kindex, iw, 1)
crvFnc.setWeight(kindex, ow, 0)
crvFnc.setWeightsLocked(kindex, wl)
crvFnc.setAngle(kindex, OpenMaya.MAngle(math.radians(inAngle)), 1)
crvFnc.setAngle(kindex, OpenMaya.MAngle(math.radians(outAngle)), 0)
crvFnc.setInTangentType(kindex, AC_TANGENT_TYPES[inTangentType])
crvFnc.setOutTangentType(kindex, AC_TANGENT_TYPES[outTangentType])
.... but it seems like the order I set this data changes the results and I'll be damned if I can get a sequence that loads everything back as intended, even though the saved data is all correct
Can anybody shed any light on this?
cheers
Mark