Bugfix #4516: Allow ipo.addCurve() to create Key IPO curve for a
corresponding keyblock.
This commit is contained in:
@@ -941,7 +941,14 @@ static PyObject *Ipo_addCurve( BPy_Ipo * self, PyObject * args )
|
||||
* param = -1.
|
||||
*/
|
||||
|
||||
param = lookup_curve_name( cur_name, ipo->blocktype, self->mtex );
|
||||
if( ipo->blocktype != ID_KE ) {
|
||||
param = lookup_curve_name( cur_name, ipo->blocktype, self->mtex );
|
||||
} else {
|
||||
param = lookup_curve_key( cur_name, ipo );
|
||||
if( param == -2 )
|
||||
return EXPP_ReturnPyObjError( PyExc_RuntimeError,
|
||||
"unable to find matching key data for Ipo" );
|
||||
}
|
||||
|
||||
if( param == -1 )
|
||||
return EXPP_ReturnPyObjError( PyExc_NameError,
|
||||
|
||||
Reference in New Issue
Block a user