Types

Caution

API Docs are a work in progress, expect them to improve over time.

LoggingLevel

enum OpenColorIO::LoggingLevel

Values:

enumerator LOGGING_LEVEL_NONE = 0
enumerator LOGGING_LEVEL_WARNING = 1
enumerator LOGGING_LEVEL_INFO = 2
enumerator LOGGING_LEVEL_DEBUG = 3
enumerator LOGGING_LEVEL_UNKNOWN = 255
enumerator LOGGING_LEVEL_DEFAULT = `LOGGING_LEVEL_INFO`_
class PyOpenColorIO.LoggingLevel

Members:

  • LOGGING_LEVEL_NONE

  • LOGGING_LEVEL_WARNING

  • LOGGING_LEVEL_INFO

  • LOGGING_LEVEL_DEBUG

  • LOGGING_LEVEL_UNKNOWN

ReferenceSpaceType

enum OpenColorIO::ReferenceSpaceType

OCIO does not mandate the image state of the main reference space and it is not required to be scene-referred. This enum is used in connection with the display color space and view transform features which do assume that the main reference space is scene-referred and the display reference space is display-referred. If a config used a non-scene-referred reference space, presumably it would not use either display color spaces or view transforms, so this enum becomes irrelevant.

Values:

enumerator REFERENCE_SPACE_SCENE = 0

the main scene reference space

enumerator REFERENCE_SPACE_DISPLAY

the reference space for display color spaces

class PyOpenColorIO.ReferenceSpaceType

Members:

  • REFERENCE_SPACE_SCENE

  • REFERENCE_SPACE_DISPLAY

SearchReferenceSpaceType

enum OpenColorIO::SearchReferenceSpaceType

Values:

enumerator SEARCH_REFERENCE_SPACE_SCENE = 0
enumerator SEARCH_REFERENCE_SPACE_DISPLAY
enumerator SEARCH_REFERENCE_SPACE_ALL
class PyOpenColorIO.SearchReferenceSpaceType

Members:

  • SEARCH_REFERENCE_SPACE_SCENE

  • SEARCH_REFERENCE_SPACE_DISPLAY

  • SEARCH_REFERENCE_SPACE_ALL

ColorSpaceVisibility

enum OpenColorIO::ColorSpaceVisibility

Values:

enumerator COLORSPACE_ACTIVE = 0
enumerator COLORSPACE_INACTIVE
enumerator COLORSPACE_ALL
class PyOpenColorIO.ColorSpaceVisibility

Members:

  • COLORSPACE_ACTIVE

  • COLORSPACE_INACTIVE

  • COLORSPACE_ALL

ColorSpaceDirection

enum OpenColorIO::ColorSpaceDirection

Values:

enumerator COLORSPACE_DIR_UNKNOWN = 0
enumerator COLORSPACE_DIR_TO_REFERENCE
enumerator COLORSPACE_DIR_FROM_REFERENCE
class PyOpenColorIO.ColorSpaceDirection

Members:

  • COLORSPACE_DIR_UNKNOWN

  • COLORSPACE_DIR_TO_REFERENCE

  • COLORSPACE_DIR_FROM_REFERENCE

ViewTransformDirection

enum OpenColorIO::ViewTransformDirection

Values:

enumerator VIEWTRANSFORM_DIR_UNKNOWN = 0
enumerator VIEWTRANSFORM_DIR_TO_REFERENCE
enumerator VIEWTRANSFORM_DIR_FROM_REFERENCE
class PyOpenColorIO.ViewTransformDirection

Members:

  • VIEWTRANSFORM_DIR_UNKNOWN

  • VIEWTRANSFORM_DIR_TO_REFERENCE

  • VIEWTRANSFORM_DIR_FROM_REFERENCE

TransformDirection

enum OpenColorIO::TransformDirection

Values:

enumerator TRANSFORM_DIR_UNKNOWN = 0
enumerator TRANSFORM_DIR_FORWARD
enumerator TRANSFORM_DIR_INVERSE
class PyOpenColorIO.TransformDirection

Members:

  • TRANSFORM_DIR_UNKNOWN

  • TRANSFORM_DIR_FORWARD

  • TRANSFORM_DIR_INVERSE

Interpolation

enum OpenColorIO::Interpolation

Specify the interpolation type to use If the specified interpolation type is not supported in the requested context (for example, using tetrahedral interpolationon 1D LUTs) an exception will be thrown.

INTERP_DEFAULT will choose the default interpolation type for the requested context:

1D LUT INTERP_DEFAULT: LINEAR 3D LUT INTERP_DEFAULT: LINEAR

INTERP_BEST will choose the best interpolation type for the requested context:

1D LUT INTERP_BEST: LINEAR 3D LUT INTERP_BEST: TETRAHEDRAL

Note: INTERP_BEST and INTERP_DEFAULT are subject to change in minor releases, so if you care about locking off on a specific interpolation type, we’d recommend directly specifying it.

Values:

enumerator INTERP_UNKNOWN = 0
enumerator INTERP_NEAREST = 1

nearest neighbor

enumerator INTERP_LINEAR = 2

linear interpolation (trilinear for Lut3D)

enumerator INTERP_TETRAHEDRAL = 3

tetrahedral interpolation (Lut3D only)

enumerator INTERP_CUBIC = 4

cubic interpolation (not supported)

enumerator INTERP_DEFAULT = 254

the default interpolation type

enumerator INTERP_BEST = 255

the ‘best’ suitable interpolation type

class PyOpenColorIO.Interpolation

Members:

  • INTERP_UNKNOWN

  • INTERP_NEAREST

  • INTERP_LINEAR

  • INTERP_TETRAHEDRAL

  • INTERP_CUBIC

  • INTERP_DEFAULT

  • INTERP_BEST

BitDepth

enum OpenColorIO::BitDepth

Used in a configuration file to indicate the bit-depth of a color space, and by the Processor to specify the input and output bit-depths of images to process. Note that Processor only supports: UINT8, UINT10, UINT12, UINT16, F16 and F32.

Values:

enumerator BIT_DEPTH_UNKNOWN = 0
enumerator BIT_DEPTH_UINT8
enumerator BIT_DEPTH_UINT10
enumerator BIT_DEPTH_UINT12
enumerator BIT_DEPTH_UINT14
enumerator BIT_DEPTH_UINT16
enumerator BIT_DEPTH_UINT32
enumerator BIT_DEPTH_F16
enumerator BIT_DEPTH_F32
class PyOpenColorIO.BitDepth

Members:

  • BIT_DEPTH_UNKNOWN

  • BIT_DEPTH_UINT8

  • BIT_DEPTH_UINT10

  • BIT_DEPTH_UINT12

  • BIT_DEPTH_UINT14

  • BIT_DEPTH_UINT16

  • BIT_DEPTH_UINT32

  • BIT_DEPTH_F16

  • BIT_DEPTH_F32

Lut1DHueAdjust

enum OpenColorIO::Lut1DHueAdjust

Used by :cpp:classLut1DTransform to control optional hue restoration algorithm.

Values:

enumerator HUE_NONE = 0
enumerator HUE_DW3
class PyOpenColorIO.Lut1DHueAdjust

Members:

  • HUE_NONE

  • HUE_DW3

ChannelOrdering

enum OpenColorIO::ChannelOrdering

Used by PackedImageDesc to indicate the channel ordering of the image to process.

Values:

enumerator CHANNEL_ORDERING_RGBA = 0
enumerator CHANNEL_ORDERING_BGRA
enumerator CHANNEL_ORDERING_ABGR
enumerator CHANNEL_ORDERING_RGB
enumerator CHANNEL_ORDERING_BGR
class PyOpenColorIO.ChannelOrdering

Members:

  • CHANNEL_ORDERING_RGBA

  • CHANNEL_ORDERING_BGRA

  • CHANNEL_ORDERING_ABGR

  • CHANNEL_ORDERING_RGB

  • CHANNEL_ORDERING_BGR

Allocation

enum OpenColorIO::Allocation

Values:

enumerator ALLOCATION_UNKNOWN = 0
enumerator ALLOCATION_UNIFORM
enumerator ALLOCATION_LG2
class PyOpenColorIO.Allocation

Members:

  • ALLOCATION_UNKNOWN

  • ALLOCATION_UNIFORM

  • ALLOCATION_LG2

GpuLanguage

enum OpenColorIO::GpuLanguage

Used when there is a choice of hardware shader language.

Values:

enumerator GPU_LANGUAGE_UNKNOWN = 0
enumerator GPU_LANGUAGE_CG

Nvidia Cg shader.

enumerator GPU_LANGUAGE_GLSL_1_0

OpenGL Shading Language.

enumerator GPU_LANGUAGE_GLSL_1_3

OpenGL Shading Language.

enumerator GPU_LANGUAGE_GLSL_4_0

OpenGL Shading Language.

enumerator GPU_LANGUAGE_HLSL_DX11

DirectX Shading Language.

class PyOpenColorIO.GpuLanguage

Members:

  • GPU_LANGUAGE_UNKNOWN

  • GPU_LANGUAGE_CG

  • GPU_LANGUAGE_GLSL_1_0

  • GPU_LANGUAGE_GLSL_1_3

  • GPU_LANGUAGE_GLSL_4_0

  • GPU_LANGUAGE_HLSL_DX11

EnvironmentMode

enum OpenColorIO::EnvironmentMode

Values:

enumerator ENV_ENVIRONMENT_UNKNOWN = 0
enumerator ENV_ENVIRONMENT_LOAD_PREDEFINED
enumerator ENV_ENVIRONMENT_LOAD_ALL
class PyOpenColorIO.EnvironmentMode

Members:

  • ENV_ENVIRONMENT_UNKNOWN

  • ENV_ENVIRONMENT_LOAD_PREDEFINED

  • ENV_ENVIRONMENT_LOAD_ALL

RangeStyle

enum OpenColorIO::RangeStyle

A RangeTransform may be set to clamp the values, or not.

Values:

enumerator RANGE_NO_CLAMP = 0
enumerator RANGE_CLAMP
class PyOpenColorIO.RangeStyle

Members:

  • RANGE_NO_CLAMP

  • RANGE_CLAMP

FixedFunctionStyle

enum OpenColorIO::FixedFunctionStyle

Enumeration of the :cpp:class:FixedFunctionTransform transform algorithms.

Values:

enumerator FIXED_FUNCTION_ACES_RED_MOD_03 = 0

Red modifier (ACES 0.3/0.7)

enumerator FIXED_FUNCTION_ACES_RED_MOD_10

Red modifier (ACES 1.0)

enumerator FIXED_FUNCTION_ACES_GLOW_03

Glow function (ACES 0.3/0.7)

enumerator FIXED_FUNCTION_ACES_GLOW_10

Glow function (ACES 1.0)

enumerator FIXED_FUNCTION_ACES_DARK_TO_DIM_10

Dark to dim surround correction (ACES 1.0)

enumerator FIXED_FUNCTION_REC2100_SURROUND

Rec.2100 surround correction (takes one double for the gamma param)

enumerator FIXED_FUNCTION_RGB_TO_HSV

Classic RGB to HSV function.

enumerator FIXED_FUNCTION_XYZ_TO_xyY

CIE XYZ to 1931 xy chromaticity coordinates.

enumerator FIXED_FUNCTION_XYZ_TO_uvY

CIE XYZ to 1976 u’v’ chromaticity coordinates.

enumerator FIXED_FUNCTION_XYZ_TO_LUV

CIE XYZ to 1976 CIELUV colour space (D65 white)

class PyOpenColorIO.FixedFunctionStyle

Members:

  • FIXED_FUNCTION_ACES_RED_MOD_03

  • FIXED_FUNCTION_ACES_RED_MOD_10

  • FIXED_FUNCTION_ACES_GLOW_03

  • FIXED_FUNCTION_ACES_GLOW_10

  • FIXED_FUNCTION_ACES_DARK_TO_DIM_10

  • FIXED_FUNCTION_REC2100_SURROUND

  • FIXED_FUNCTION_RGB_TO_HSV

  • FIXED_FUNCTION_XYZ_TO_xyY

  • FIXED_FUNCTION_XYZ_TO_uvY

  • FIXED_FUNCTION_XYZ_TO_LUV

ExposureContrastStyle

enum OpenColorIO::ExposureContrastStyle

Enumeration of the :cpp:class:ExposureContrastTransform transform algorithms.

Values:

enumerator EXPOSURE_CONTRAST_LINEAR = 0

E/C to be applied to a linear space image.

enumerator EXPOSURE_CONTRAST_VIDEO

E/C to be applied to a video space image.

enumerator EXPOSURE_CONTRAST_LOGARITHMIC

E/C to be applied to a log space image.

class PyOpenColorIO.ExposureContrastStyle

Members:

  • EXPOSURE_CONTRAST_LINEAR

  • EXPOSURE_CONTRAST_VIDEO

  • EXPOSURE_CONTRAST_LOGARITHMIC

CDLStyle

enum OpenColorIO::CDLStyle

Enumeration of the :cpp:class:CDLTransform transform algorithms.

Note

The default for reading .cc/.ccc/.cdl files, config file YAML, and CDLTransform is no-clamp, since that is what is primarily desired in VFX. However, the CLF format default is ASC.

Values:

enumerator CDL_ASC = 0

ASC CDL specification v1.2.

enumerator CDL_NO_CLAMP

CDL that does not clamp.

enumerator CDL_TRANSFORM_DEFAULT = `CDL_NO_CLAMP`_
class PyOpenColorIO.CDLStyle

Members:

  • CDL_ASC

  • CDL_NO_CLAMP

  • CDL_TRANSFORM_DEFAULT

NegativeStyle

enum OpenColorIO::NegativeStyle

Negative values handling style for ExponentTransform and ExponentWithLinearTransform transform algorithms.

Values:

enumerator NEGATIVE_CLAMP = 0

Clamp negative values.

enumerator NEGATIVE_MIRROR

Positive curve is rotated 180 degrees around the origin to handle negatives.

enumerator NEGATIVE_PASS_THRU

Negative values are passed through unchanged.

enumerator NEGATIVE_LINEAR

Linearly extrapolate the curve for negative values.

class PyOpenColorIO.NegativeStyle

Members:

  • NEGATIVE_CLAMP

  • NEGATIVE_MIRROR

  • NEGATIVE_PASS_THRU

  • NEGATIVE_LINEAR

DynamicPropertyType

enum OpenColorIO::DynamicPropertyType

Values:

enumerator DYNAMIC_PROPERTY_EXPOSURE = 0

Image exposure value (double floating point value)

enumerator DYNAMIC_PROPERTY_CONTRAST

Image contrast value (double floating point value)

enumerator DYNAMIC_PROPERTY_GAMMA

Image gamma value (double floating point value)

class PyOpenColorIO.DynamicPropertyType

Members:

  • DYNAMIC_PROPERTY_EXPOSURE

  • DYNAMIC_PROPERTY_CONTRAST

  • DYNAMIC_PROPERTY_GAMMA

OptimizationFlags

enum OpenColorIO::OptimizationFlags

Provides control over how the ops in a Processor are combined in order to improve performance.

Values:

enumerator OPTIMIZATION_NONE = 0x00000000

Do not optimize.

enumerator OPTIMIZATION_IDENTITY = 0x00000001

Replace identity ops (other than gamma).

enumerator OPTIMIZATION_IDENTITY_GAMMA = 0x00000002

Replace identity gamma ops.

enumerator OPTIMIZATION_PAIR_IDENTITY_CDL = 0x00000004

Replace a pair of ops where one is the inverse of the other.

enumerator OPTIMIZATION_PAIR_IDENTITY_EXPOSURE_CONTRAST =

0x00000008

enumerator OPTIMIZATION_PAIR_IDENTITY_FIXED_FUNCTION = 0x00000010
enumerator OPTIMIZATION_PAIR_IDENTITY_GAMMA = 0x00000020
enumerator OPTIMIZATION_PAIR_IDENTITY_LUT1D = 0x00000040
enumerator OPTIMIZATION_PAIR_IDENTITY_LUT3D = 0x00000080
enumerator OPTIMIZATION_PAIR_IDENTITY_LOG = 0x00000100
enumerator OPTIMIZATION_COMP_EXPONENT = 0x00000200

Compose a pair of ops into a single op.

enumerator OPTIMIZATION_COMP_GAMMA = 0x00000400
enumerator OPTIMIZATION_COMP_MATRIX = 0x00000800
enumerator OPTIMIZATION_COMP_LUT1D = 0x00001000
enumerator OPTIMIZATION_COMP_LUT3D = 0x00002000
enumerator OPTIMIZATION_COMP_RANGE = 0x00004000
enumerator OPTIMIZATION_COMP_SEPARABLE_PREFIX = 0x00008000

For integer and half bit-depths only, replace separable ops (i.e. no channel crosstalk ops) by a single 1D LUT of input bit-depth domain.

enumerator OPTIMIZATION_LUT_INV_FAST = 0x00010000

Implement inverse Lut1D and Lut3D evaluations using a a forward LUT (faster but less accurate). Note that GPU evals always do FAST.

enumerator OPTIMIZATION_NO_DYNAMIC_PROPERTIES = 0x00020000

Turn off dynamic control of any ops that offer adjustment of parameter values after finalization (e.g. ExposureContrast).

enumerator OPTIMIZATION_ALL = 0xFFFFFFFF

Apply all possible optimizations.

enumerator OPTIMIZATION_LOSSLESS = (`OPTIMIZATION_IDENTITY`_ | `OPTIMIZATION_IDENTITY_GAMMA`_ | `OPTIMIZATION_PAIR_IDENTITY_CDL`_ | `OPTIMIZATION_PAIR_IDENTITY_EXPOSURE_CONTRAST`_ | `OPTIMIZATION_PAIR_IDENTITY_FIXED_FUNCTION`_ | `OPTIMIZATION_PAIR_IDENTITY_GAMMA`_ | `OPTIMIZATION_PAIR_IDENTITY_LOG`_ | `OPTIMIZATION_PAIR_IDENTITY_LUT1D`_ | `OPTIMIZATION_PAIR_IDENTITY_LUT3D`_ | `OPTIMIZATION_COMP_EXPONENT`_ | `OPTIMIZATION_COMP_GAMMA`_ | `OPTIMIZATION_COMP_MATRIX`_ | `OPTIMIZATION_COMP_RANGE`_)
enumerator OPTIMIZATION_VERY_GOOD = (`OPTIMIZATION_LOSSLESS`_ | `OPTIMIZATION_COMP_LUT1D`_ | `OPTIMIZATION_LUT_INV_FAST`_ | `OPTIMIZATION_COMP_SEPARABLE_PREFIX`_)
enumerator OPTIMIZATION_GOOD = `OPTIMIZATION_VERY_GOOD`_ | `OPTIMIZATION_COMP_LUT3D`_
enumerator OPTIMIZATION_DRAFT = `OPTIMIZATION_ALL`_

For quite lossy optimizations.

enumerator OPTIMIZATION_DEFAULT = `OPTIMIZATION_VERY_GOOD`_
class PyOpenColorIO.OptimizationFlags

Members:

  • OPTIMIZATION_NONE

  • OPTIMIZATION_IDENTITY

  • OPTIMIZATION_IDENTITY_GAMMA

  • OPTIMIZATION_PAIR_IDENTITY_CDL

  • OPTIMIZATION_PAIR_IDENTITY_EXPOSURE_CONTRAST

  • OPTIMIZATION_PAIR_IDENTITY_FIXED_FUNCTION

  • OPTIMIZATION_PAIR_IDENTITY_GAMMA

  • OPTIMIZATION_PAIR_IDENTITY_LUT1D

  • OPTIMIZATION_PAIR_IDENTITY_LUT3D

  • OPTIMIZATION_PAIR_IDENTITY_LOG

  • OPTIMIZATION_COMP_EXPONENT

  • OPTIMIZATION_COMP_GAMMA

  • OPTIMIZATION_COMP_MATRIX

  • OPTIMIZATION_COMP_LUT1D

  • OPTIMIZATION_COMP_LUT3D

  • OPTIMIZATION_COMP_RANGE

  • OPTIMIZATION_COMP_SEPARABLE_PREFIX

  • OPTIMIZATION_LUT_INV_FAST

  • OPTIMIZATION_NO_DYNAMIC_PROPERTIES

  • OPTIMIZATION_ALL

  • OPTIMIZATION_LOSSLESS

  • OPTIMIZATION_VERY_GOOD

  • OPTIMIZATION_GOOD

  • OPTIMIZATION_DRAFT

  • OPTIMIZATION_DEFAULT