Restore the original colors of animation curves


Sometimes the colors of the animation curves in the graph editor are not in RGB anymore, either it was changed by a tool or by another human, it’s hard for you to work with those weird colors. Here is the little quick tip.

To restore the original color of a curve, select a node curve by right clicking on a red field in the Attribute Editor and uncheck ‘Use Curve Color’ in the ‘Anim Curve Attributes’ section, or use this script to do it for every animation curve in a scene:

objList = cmds.ls(type="animCurve")
for objName in objList:
    cmds.setAttr(objName + ".useCurveColor", 0)
string $objList[] = `ls -type "animCurve"`;
string $objName;
for ($objName in $objList) {
    setAttr ($objName + ".useCurveColor") 0;
}

Rainbow!
Because... why not?