Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

If you want to manipulate these attributes from script, you need to first ensure that they exist. You can use the maxwellSetCustomScalar utility function for thisThe plug-in provides a function called maxwellSetCustomScalar which creates the attribute if needed and sets it to the specified value, so use that instead of calling setAttr directly:

    maxwellSetCustomScalar("double", "cameraShape1", "mxFstop", 58.60);
    maxwellSetCustomScalar("long", "cameraShape1", "mxIso", 100200);

The first parameter specifies the type of the attribute. Valid values are "long" for integers and enums, "double" for floating point numbers and "bool" for booleans. The following parameters are the node name, attribute name and value. For the complete list of custom attribute names, see the file maxwellCustomAttrs.mel in the scripts/others subdirectory of the Maya installation path.

...