MCPcopy Create free account
hub / github.com/NatronGitHub/Natron / setNthControlPoint

Method setNthControlPoint

Engine/KnobTypes.cpp:2097–2118  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2095}
2096
2097StatusEnum
2098KnobParametric::setNthControlPoint(ValueChangedReasonEnum reason,
2099 int dimension,
2100 int nthCtl,
2101 double key,
2102 double value)
2103{
2104 ///Mt-safe as Curve is MT-safe
2105 if ( dimension >= (int)_curves.size() ) {
2106 return eStatusFailed;
2107 }
2108 try {
2109 _curves[dimension]->setKeyFrameValueAndTime(key, value, nthCtl);
2110 } catch (...) {
2111 return eStatusFailed;
2112 }
2113
2114 Q_EMIT curveChanged(dimension);
2115 evaluateValueChange(0, getCurrentTime(), ViewSpec::all(), reason);
2116
2117 return eStatusOK;
2118}
2119
2120StatusEnum
2121KnobParametric::setNthControlPoint(ValueChangedReasonEnum reason,

Calls 5

getCurrentTimeFunction · 0.85
allFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected