HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
PXL_OCIO Class Reference

Abstract interface to OpenColorIO. More...

#include <PXL_OCIO.h>

Static Public Member Functions

static bool isOCIOEnvSet (bool check_for_active_vars=true)
 
static const char * getDefaultDisplay ()
 Returns the current color space name. More...
 
static const char * getDefaultView (const char *display=NULL)
 Returns the current color space name. More...
 
static void getViewsForDisplay (const char *display, UT_StringArray &view_names)
 Return the list of views for a given display. More...
 
static void getActiveDisplays (UT_StringArray &names)
 Returns the list of active displays. More...
 
static void getActiveViews (UT_StringArray &names)
 Returns the list of active views. More...
 
static void getColorSpaces (UT_StringArray &names)
 Returns a list of the supported color spaces. More...
 
static void getRoles (UT_StringArray &names)
 Returns a list of the supported roles. More...
 
static const char * getDefaultRole ()
 
static const char * getReferenceRole ()
 
static const char * getDataRole ()
 
static const char * getSceneLinearRole ()
 
static const char * getCompLogRole ()
 
static const char * getColorPickingRole ()
 
static const char * getsRGBColorSpace (const char *display=nullptr)
 
static const char * getColorSpaceForDisplayView (const char *display_name, const char *view_name)
 Return the colorspace defined by the view for a given display. More...
 
static const char * getLooksForDisplayView (const char *display_name, const char *view_name)
 Return the looks attached to the view for a given display. More...
 
static const char * parseColorSpaceFromString (const char *string)
 
static const ColorSpace * lookupSpace (const UT_StringHolder &name)
 
static const char * getName (const ColorSpace *space)
 Return the name of the color space. More...
 
static const char * getDescription (const ColorSpace *space)
 Return the description of the color space. More...
 
static bool getAllocationVars (const ColorSpace *space, bool &uniform, fpreal &min, fpreal &max, fpreal &offset)
 Return the allocation variable meta data about the color space. More...
 
static bool isFloatPointSpace (const ColorSpace *space, bool &fp)
 Set 'fp' to true if the color space is defined for FP, false for uint. More...
 
static bool getInfo (const ColorSpace *space, UT_Options &info)
 
static bool transformToView (const UT_StringHolder &src, const UT_StringHolder &display, const UT_StringHolder &view, fpreal32 *data, int npixels, int nchannels)
 Transform from a colorspace to a display/view, including looks. More...
 
static bool transform (const UT_StringHolder &src, const UT_StringHolder &dest, const UT_StringHolder &looks, fpreal32 *data, int npixels, int nchannels)
 
static bool transform (const ColorSpace *src, const ColorSpace *dest, const UT_StringHolder &looks, fpreal32 *data, int npixels, int nchannels)
 

Detailed Description

Abstract interface to OpenColorIO.

Definition at line 22 of file PXL_OCIO.h.

Member Function Documentation

static void PXL_OCIO::getActiveDisplays ( UT_StringArray names)
static

Returns the list of active displays.

static void PXL_OCIO::getActiveViews ( UT_StringArray names)
static

Returns the list of active views.

static bool PXL_OCIO::getAllocationVars ( const ColorSpace *  space,
bool &  uniform,
fpreal min,
fpreal max,
fpreal offset 
)
static

Return the allocation variable meta data about the color space.

static const char* PXL_OCIO::getColorPickingRole ( )
static
static const char* PXL_OCIO::getColorSpaceForDisplayView ( const char *  display_name,
const char *  view_name 
)
static

Return the colorspace defined by the view for a given display.

static void PXL_OCIO::getColorSpaces ( UT_StringArray names)
static

Returns a list of the supported color spaces.

static const char* PXL_OCIO::getCompLogRole ( )
static
static const char* PXL_OCIO::getDataRole ( )
static
static const char* PXL_OCIO::getDefaultDisplay ( )
static

Returns the current color space name.

static const char* PXL_OCIO::getDefaultRole ( )
static
static const char* PXL_OCIO::getDefaultView ( const char *  display = NULL)
static

Returns the current color space name.

static const char* PXL_OCIO::getDescription ( const ColorSpace *  space)
static

Return the description of the color space.

static bool PXL_OCIO::getInfo ( const ColorSpace *  space,
UT_Options info 
)
static

Fill out metadata for color space in a UT_Options Keys are the tokens in the config.ocio file:

  • name
  • family
  • equalitygroup
  • bitdepth
  • description
  • isdata
  • allocation
  • allocationvars
static const char* PXL_OCIO::getLooksForDisplayView ( const char *  display_name,
const char *  view_name 
)
static

Return the looks attached to the view for a given display.

static const char* PXL_OCIO::getName ( const ColorSpace *  space)
static

Return the name of the color space.

static const char* PXL_OCIO::getReferenceRole ( )
static
static void PXL_OCIO::getRoles ( UT_StringArray names)
static

Returns a list of the supported roles.

static const char* PXL_OCIO::getSceneLinearRole ( )
static
static const char* PXL_OCIO::getsRGBColorSpace ( const char *  display = nullptr)
static
static void PXL_OCIO::getViewsForDisplay ( const char *  display,
UT_StringArray view_names 
)
static

Return the list of views for a given display.

static bool PXL_OCIO::isFloatPointSpace ( const ColorSpace *  space,
bool &  fp 
)
static

Set 'fp' to true if the color space is defined for FP, false for uint.

static bool PXL_OCIO::isOCIOEnvSet ( bool  check_for_active_vars = true)
static

Returns whether the user has set $OCIO, $OCIO_ACTIVE_DISPLAYS or $OCIO_ACTIVE_VIEWS is set. If there's an error loading the configuration, this method will return false.

static const ColorSpace* PXL_OCIO::lookupSpace ( const UT_StringHolder name)
static

Return a color space handle given a name. The name may be a color space name or prefixed with "role:" to specify a color space role.

static const char* PXL_OCIO::parseColorSpaceFromString ( const char *  string)
static

Guess at the colorspace using the rightmost colorspace found, or NULL if none are found.

static bool PXL_OCIO::transform ( const UT_StringHolder src,
const UT_StringHolder dest,
const UT_StringHolder looks,
fpreal32 data,
int  npixels,
int  nchannels 
)
static

Transform color data from one color space to another color space. The color space names may either refer to a color space name, or it can also be prefixed with "role:" and refer to a color space role. The 'looks' is a comma separated list of color gradings (aka looks)

static bool PXL_OCIO::transform ( const ColorSpace *  src,
const ColorSpace *  dest,
const UT_StringHolder looks,
fpreal32 data,
int  npixels,
int  nchannels 
)
static

Transform color data from one color space to another color space. The color space names may either refer to a color space name, or it can also be prefixed with "role:" and refer to a color space role. The 'looks' is a comma separated list of color gradings (aka looks)

static bool PXL_OCIO::transformToView ( const UT_StringHolder src,
const UT_StringHolder display,
const UT_StringHolder view,
fpreal32 data,
int  npixels,
int  nchannels 
)
static

Transform from a colorspace to a display/view, including looks.


The documentation for this class was generated from the following file: