Is it possible to change the color of a NURBS curve from the API? I know how to do it in MEL, but I'd like to know if there's a way to do it from C++ without invoking the MEL commands.
The closest I could come was the following:
MFnNurbsCurve curveFn;
int nColorNumber = someNumber;
stat = curveFn.setObject( nurbsCurveObj );
stat = curveFn.setUseObjectColor( true );
stat = curveFn.setObjectColor( nColorNumber );
stat = curveFn.updateCurve();
This is supposed to apply one of the user defined color types, but no matter what number I put in 'nColorNumber' it always applies the 'User Defined Color 1'
Any suggestions?