5 #ifndef INCLUDED_OCIO_OPENCOLORIO_H
6 #define INCLUDED_OCIO_OPENCOLORIO_H
67 #pragma warning( push )
68 #pragma warning( disable : 4275 )
112 #pragma warning( pop )
223 const char * archivePath,
224 const char * destinationDir
366 unsigned int getMajorVersion()
const;
373 void setMajorVersion(
unsigned int major);
376 unsigned int getMinorVersion()
const;
379 void setMinorVersion(
unsigned int minor);
382 void setVersion(
unsigned int major,
unsigned int minor);
385 void upgradeToLatestVersion() noexcept;
394 void validate()
const;
403 const char *
getName()
const noexcept;
404 void setName(
const char *
name) noexcept;
412 char getFamilySeparator()
const;
414 static char GetDefaultFamilySeparator() noexcept;
421 void setFamilySeparator(
char separator);
424 void setDescription(
const char * description);
432 void serialize(std::ostream & os)
const;
445 const char * getCacheID()
const;
456 void addEnvironmentVar(
const char * name,
const char * defaultValue);
457 int getNumEnvironmentVars()
const;
458 const char * getEnvironmentVarNameByIndex(
int index)
const;
459 const char * getEnvironmentVarDefault(
const char * name)
const;
460 void clearEnvironmentVars();
476 void loadEnvironment() noexcept;
478 const char * getSearchPath()
const;
485 void setSearchPath(
const char *
path);
487 int getNumSearchPaths()
const;
494 const char * getSearchPath(
int index)
const;
495 void clearSearchPaths();
504 void addSearchPath(
const char * path);
506 const char * getWorkingDir()
const;
516 void setWorkingDir(
const char * dirname);
561 int getNumColorSpaces()
const;
569 const char * getColorSpaceNameByIndex(
int index)
const;
579 int getIndexForColorSpace(
const char * name)
const;
595 const char * getCanonicalName(
const char * name)
const;
620 void removeColorSpace(
const char * name);
628 bool isColorSpaceUsed(
const char * name)
const noexcept;
637 void clearColorSpaces();
653 void setInactiveColorSpaces(
const char * inactiveColorSpaces);
654 const char * getInactiveColorSpaces()
const;
691 bool isColorSpaceLinear(
const char * colorSpace,
ReferenceSpaceType referenceSpaceType)
const;
706 void setRole(
const char * role,
const char * colorSpaceName);
707 int getNumRoles()
const;
709 bool hasRole(
const char * role)
const;
716 const char * getRoleName(
int index)
const;
722 const char * getRoleColorSpace(
int index)
const;
752 void addSharedView(
const char *
view,
const char * viewTransformName,
753 const char * colorSpaceName,
const char * looks,
754 const char * ruleName,
const char * description);
756 void removeSharedView(
const char * view);
759 int getNumDisplays()
const;
761 const char * getDisplay(
int index)
const;
766 const char *
getDefaultView(
const char * display,
const char * colorspaceName)
const;
772 int getNumViews(
const char * display)
const;
773 const char * getView(
const char * display,
int index)
const;
779 int getNumViews(
const char * display,
const char * colorspaceName)
const;
780 const char * getView(
const char * display,
const char * colorspaceName,
int index)
const;
786 const char * getDisplayViewTransformName(
const char * display,
const char * view)
const;
791 const char * getDisplayViewColorSpaceName(
const char * display,
const char * view)
const;
793 const char * getDisplayViewLooks(
const char * display,
const char * view)
const;
795 const char * getDisplayViewRule(
const char * display,
const char * view)
const noexcept;
797 const char * getDisplayViewDescription(
const char * display,
const char * view)
const noexcept;
803 void addDisplayView(
const char * display,
const char * view,
804 const char * colorSpaceName,
const char * looks);
818 void addDisplayView(
const char * display,
const char * view,
const char * viewTransformName,
819 const char * colorSpaceName,
const char * looks,
820 const char * ruleName,
const char * description);
831 void addDisplaySharedView(
const char * display,
const char * sharedView);
842 void removeDisplayView(
const char * display,
const char * view);
844 void clearDisplays();
865 void addVirtualDisplayView(
const char * view,
866 const char * viewTransformName,
867 const char * colorSpaceName,
869 const char * ruleName,
870 const char * description);
872 void addVirtualDisplaySharedView(
const char * sharedView);
875 int getVirtualDisplayNumViews(
ViewType type)
const noexcept;
877 const char * getVirtualDisplayView(
ViewType type,
int index)
const noexcept;
879 const char * getVirtualDisplayViewTransformName(
const char * view)
const noexcept;
880 const char * getVirtualDisplayViewColorSpaceName(
const char * view)
const noexcept;
881 const char * getVirtualDisplayViewLooks(
const char * view)
const noexcept;
882 const char * getVirtualDisplayViewRule(
const char * view)
const noexcept;
883 const char * getVirtualDisplayViewDescription(
const char * view)
const noexcept;
886 void removeVirtualDisplayView(
const char * view) noexcept;
889 void clearVirtualDisplay() noexcept;
916 int instantiateDisplayFromMonitorName(
const char * monitorName);
928 int instantiateDisplayFromICCProfile(
const char * ICCProfileFilepath);
946 void setActiveDisplays(
const char * displays);
964 void setActiveViews(
const char * views);
968 int getNumDisplaysAll()
const noexcept;
969 const char * getDisplayAll(
int index)
const noexcept;
970 int getDisplayAllByName(
const char *)
const noexcept;
975 bool isDisplayTemporary(
int index)
const noexcept;
983 int getNumViews(
ViewType type,
const char * display)
const;
984 const char * getView(
ViewType type,
const char * display,
int index)
const;
1018 void getDefaultLumaCoefs(
double * rgb)
const;
1020 void setDefaultLumaCoefs(
const double * rgb);
1031 int getNumLooks()
const;
1033 const char * getLookNameByIndex(
int index)
const;
1046 int getNumViewTransforms()
const noexcept;
1050 const char * getViewTransformNameByIndex(
int i)
const noexcept;
1072 const char * getDefaultViewTransformName()
const noexcept;
1073 void setDefaultViewTransformName(
const char * defaultName) noexcept;
1076 void clearViewTransforms();
1094 int index)
const noexcept;
1097 int getNumNamedTransforms()
const noexcept;
1100 const char * getNamedTransformNameByIndex(
int index)
const noexcept;
1103 int getIndexForNamedTransform(
const char * name)
const noexcept;
1121 void clearNamedTransforms();
1142 const char * getColorSpaceFromFilepath(
const char * filePath)
const;
1150 const char * getColorSpaceFromFilepath(
const char * filePath,
size_t & ruleIndex)
const;
1159 bool filepathOnlyMatchesDefaultRule(
const char * filePath)
const;
1170 OCIO_DEPRECATED(
"This was marked as deprecated starting in v2.0, please use Config::getColorSpaceFromFilepath().")
1173 bool isStrictParsingEnabled()
const;
1174 void setStrictParsingEnabled(
bool enabled);
1199 const char * dstColorSpaceName)
const;
1201 const char * srcColorSpaceName,
1202 const char * dstColorSpaceName)
const;
1207 const char * display,
1212 const char * srcColorSpaceName,
1213 const char * display,
1227 const char * namedTransformName,
1269 const char * srcColorSpaceName,
1270 const char * builtinColorSpaceName);
1279 const char * builtinColorSpaceName,
1281 const char * srcColorSpaceName);
1292 const char * srcColorSpaceName,
1294 const char * dstColorSpaceName);
1297 const char * srcColorSpaceName,
1300 const char * dstColorSpaceName);
1307 const char * srcColorSpaceName,
1308 const char * srcInterchangeName,
1310 const char * dstColorSpaceName,
1311 const char * dstInterchangeName);
1315 const char * srcColorSpaceName,
1316 const char * srcInterchangeName,
1319 const char * dstColorSpaceName,
1320 const char * dstInterchangeName);
1350 bool isArchivable()
const;
1376 void archive(std::ostream & ostream)
const;
1392 static void deleter(
Config* c);
1396 Impl * getImpl() {
return m_impl; }
1397 const Impl * getImpl()
const {
return m_impl; }
1473 size_t getNumEntries()
const noexcept;
1476 size_t getIndexForRule(
const char * ruleName)
const;
1479 const
char *
getName(
size_t ruleIndex) const;
1482 const
char * getPattern(
size_t ruleIndex) const;
1483 void setPattern(
size_t ruleIndex, const
char *
pattern);
1486 const
char * getExtension(
size_t ruleIndex) const;
1487 void setExtension(
size_t ruleIndex, const
char *
extension);
1490 const
char * getRegex(
size_t ruleIndex) const;
1491 void setRegex(
size_t ruleIndex, const
char * regex);
1494 const
char * getColorSpace(
size_t ruleIndex) const;
1495 void setColorSpace(
size_t ruleIndex, const
char * colorSpace);
1498 size_t getNumCustomKeys(
size_t ruleIndex) const;
1500 const
char * getCustomKeyName(
size_t ruleIndex,
size_t key) const;
1502 const
char * getCustomKeyValue(
size_t ruleIndex,
size_t key) const;
1507 void setCustomKey(
size_t ruleIndex, const
char * key, const
char *
value);
1523 void insertRule(
size_t ruleIndex, const
char *
name, const
char * colorSpace,
1524 const
char * pattern, const
char * extension);
1525 void insertRule(
size_t ruleIndex, const
char * name, const
char * colorSpace,
1526 const
char * regex);
1533 void insertPathSearchRule(
size_t ruleIndex);
1535 void setDefaultRuleColorSpace(const
char * colorSpace);
1544 void removeRule(
size_t ruleIndex);
1547 void increaseRulePriority(
size_t ruleIndex);
1550 void decreaseRulePriority(
size_t ruleIndex);
1556 bool isDefault() const noexcept;
1567 static
void deleter(FileRules* c);
1573 Impl * getImpl() {
return m_impl; }
1574 const Impl * getImpl()
const {
return m_impl; }
1612 size_t getNumEntries()
const noexcept;
1618 size_t getIndexForRule(
const char * ruleName)
const;
1621 const char *
getName(
size_t ruleIndex)
const;
1624 size_t getNumColorSpaces(
size_t ruleIndex)
const;
1626 const char * getColorSpace(
size_t ruleIndex,
size_t colorSpaceIndex)
const;
1634 void addColorSpace(
size_t ruleIndex,
const char * colorSpace);
1636 void removeColorSpace(
size_t ruleIndex,
size_t colorSpaceIndex);
1639 size_t getNumEncodings(
size_t ruleIndex)
const;
1641 const char * getEncoding(
size_t ruleIndex,
size_t encodingIndex)
const;
1649 void addEncoding(
size_t ruleIndex,
const char * encoding);
1651 void removeEncoding(
size_t ruleIndex,
size_t encodingIndex);
1654 size_t getNumCustomKeys(
size_t ruleIndex)
const;
1656 const char * getCustomKeyName(
size_t ruleIndex,
size_t keyIndex)
const;
1658 const char * getCustomKeyValue(
size_t ruleIndex,
size_t keyIndex)
const;
1663 void setCustomKey(
size_t ruleIndex,
const char * key,
const char *
value);
1674 void insertRule(
size_t ruleIndex,
const char * ruleName);
1677 void removeRule(
size_t ruleIndex);
1693 Impl * getImpl() {
return m_impl; }
1694 const Impl * getImpl()
const {
return m_impl; }
1721 const char *
getName()
const noexcept;
1723 void setName(
const char *
name) noexcept;
1725 size_t getNumAliases()
const noexcept;
1727 const char * getAlias(
size_t idx)
const noexcept;
1735 void addAlias(
const char * alias) noexcept;
1737 void removeAlias(
const char * alias) noexcept;
1738 void clearAliases() noexcept;
1745 const char * getFamily()
const noexcept;
1747 void setFamily(
const char * family);
1756 const char * getEqualityGroup()
const noexcept;
1757 void setEqualityGroup(
const char * equalityGroup);
1760 void setDescription(
const char * description);
1762 BitDepth getBitDepth()
const noexcept;
1763 void setBitDepth(
BitDepth bitDepth);
1792 bool hasCategory(
const char * category)
const;
1799 void addCategory(
const char * category);
1806 void removeCategory(
const char * category);
1808 int getNumCategories()
const;
1815 const char * getCategory(
int index)
const;
1817 void clearCategories();
1837 const char * getEncoding()
const noexcept;
1838 void setEncoding(
const char * encoding);
1852 bool isData()
const noexcept;
1853 void setIsData(
bool isData) noexcept;
1863 void setAllocation(
Allocation allocation) noexcept;
1878 int getAllocationNumVars()
const;
1880 void setAllocationVars(
int numvars,
const float * vars);
1908 Impl * getImpl() {
return m_impl; }
1909 const Impl * getImpl()
const {
return m_impl; }
1953 int getNumColorSpaces()
const;
1958 const char * getColorSpaceNameByIndex(
int index)
const;
1980 int getColorSpaceIndex(
const char * name)
const;
1991 bool hasColorSpace(
const char * name)
const;
2011 void removeColorSpace(
const char * name);
2015 void clearColorSpaces();
2030 Impl * getImpl() {
return m_impl; }
2031 const Impl * getImpl()
const {
return m_impl; }
2096 void setName(
const char *
name);
2098 const char * getProcessSpace()
const;
2099 void setProcessSpace(
const char * processSpace);
2110 void setDescription(
const char * description);
2113 Look& operator= (
const Look &) =
delete;
2120 static void deleter(
Look* c);
2124 Impl * getImpl() {
return m_impl; }
2125 const Impl * getImpl()
const {
return m_impl; }
2146 virtual const char *
getName()
const noexcept = 0;
2147 virtual void setName(
const char *
name) noexcept = 0;
2150 virtual size_t getNumAliases()
const noexcept = 0;
2152 virtual const char * getAlias(
size_t idx)
const noexcept = 0;
2157 virtual void addAlias(
const char * alias) noexcept = 0;
2159 virtual void removeAlias(
const char * alias) noexcept = 0;
2160 virtual void clearAliases() noexcept = 0;
2163 virtual const char * getFamily()
const noexcept = 0;
2165 virtual void setFamily(
const char * family) noexcept = 0;
2168 virtual void setDescription(
const char * description) noexcept = 0;
2171 virtual bool hasCategory(
const char * category)
const noexcept = 0;
2173 virtual void addCategory(
const char * category) noexcept = 0;
2175 virtual void removeCategory(
const char * category) noexcept = 0;
2177 virtual int getNumCategories()
const noexcept = 0;
2179 virtual const char * getCategory(
int index)
const noexcept = 0;
2181 virtual void clearCategories() noexcept = 0;
2188 virtual const char * getEncoding()
const noexcept = 0;
2189 virtual void setEncoding(
const char * encoding) noexcept = 0;
2234 const char *
getName()
const noexcept;
2235 void setName(
const char *
name) noexcept;
2238 const char * getFamily()
const noexcept;
2240 void setFamily(
const char * family);
2243 void setDescription(
const char * description);
2246 bool hasCategory(
const char * category)
const;
2248 void addCategory(
const char * category);
2250 void removeCategory(
const char * category);
2252 int getNumCategories()
const;
2254 const char * getCategory(
int index)
const;
2256 void clearCategories();
2285 Impl * getImpl() {
return m_impl; }
2286 const Impl * getImpl()
const {
return m_impl; }
2303 bool isNoOp()
const;
2309 bool hasChannelCrosstalk()
const;
2311 const char * getCacheID()
const;
2330 int getNumTransforms()
const;
2368 bool isDynamic()
const noexcept;
2399 unsigned edgelen)
const;
2455 Impl * getImpl() {
return m_impl; }
2456 const Impl * getImpl()
const {
return m_impl; }
2467 bool isNoOp()
const;
2475 bool hasChannelCrosstalk()
const;
2477 const char * getCacheID()
const;
2482 BitDepth getOutputBitDepth()
const;
2499 void apply(
const ImageDesc & imgDesc)
const;
2511 void applyRGB(
float * pixel)
const;
2512 void applyRGBA(
float * pixel)
const;
2528 Impl * getImpl() {
return m_impl; }
2529 const Impl * getImpl()
const {
return m_impl; }
2539 bool isNoOp()
const;
2541 bool hasChannelCrosstalk()
const;
2543 const char * getCacheID()
const;
2565 Impl * getImpl() {
return m_impl; }
2566 const Impl * getImpl()
const {
return m_impl; }
2582 int getNumFiles()
const;
2583 const char * getFile(
int index)
const;
2585 int getNumLooks()
const;
2586 const char * getLook(
int index)
const;
2588 void addFile(
const char * fname);
2589 void addLook(
const char * look);
2603 Impl * getImpl() {
return m_impl; }
2604 const Impl * getImpl()
const {
return m_impl; }
2647 const char * getFormat()
const;
2649 void setFormat(
const char * formatName);
2662 const char * getInputSpace()
const;
2664 void setInputSpace(
const char * inputSpace);
2666 const char * getShaperSpace()
const;
2673 void setShaperSpace(
const char * shaperSpace);
2682 void setLooks(
const char * looks);
2684 const char * getTargetSpace()
const;
2686 void setTargetSpace(
const char * targetSpace);
2688 const char * getDisplay()
const;
2689 const char * getView()
const;
2691 void setDisplayView(
const char * display,
const char *
view);
2693 int getShaperSize()
const;
2699 void setShaperSize(
int shapersize);
2701 int getCubeSize()
const;
2706 void setCubeSize(
int cubesize);
2709 void bake(std::ostream & os)
const;
2712 static int getNumFormats();
2718 static const char * getFormatNameByIndex(
int index);
2723 static const char * getFormatExtensionByIndex(
int index);
2733 static void deleter(
Baker* o);
2737 Impl * getImpl() {
return m_impl; }
2738 const Impl * getImpl()
const {
return m_impl; }
2760 virtual void * getRData()
const = 0;
2762 virtual void * getGData()
const = 0;
2764 virtual void * getBData()
const = 0;
2769 virtual void * getAData()
const = 0;
2772 virtual BitDepth getBitDepth()
const = 0;
2775 virtual long getWidth()
const = 0;
2777 virtual long getHeight()
const = 0;
2780 virtual ptrdiff_t getXStrideBytes()
const = 0;
2785 virtual ptrdiff_t getYStrideBytes()
const = 0;
2792 virtual bool isRGBAPacked()
const = 0;
2794 virtual bool isFloat()
const = 0;
2835 long width,
long height,
2838 ptrdiff_t chanStrideBytes,
2839 ptrdiff_t xStrideBytes,
2840 ptrdiff_t yStrideBytes);
2843 long width,
long height,
2847 long width,
long height,
2850 ptrdiff_t chanStrideBytes,
2851 ptrdiff_t xStrideBytes,
2852 ptrdiff_t yStrideBytes);
2860 BitDepth getBitDepth()
const override;
2863 void * getData()
const;
2865 void * getRData()
const override;
2866 void * getGData()
const override;
2867 void * getBData()
const override;
2868 void * getAData()
const override;
2870 long getWidth()
const override;
2871 long getHeight()
const override;
2872 long getNumChannels()
const;
2874 ptrdiff_t getChanStrideBytes()
const;
2875 ptrdiff_t getXStrideBytes()
const override;
2876 ptrdiff_t getYStrideBytes()
const override;
2878 bool isRGBAPacked()
const override;
2879 bool isFloat()
const override;
2884 Impl * getImpl() {
return m_impl; }
2885 const Impl * getImpl()
const {
return m_impl; }
2909 PlanarImageDesc(
void * rData,
void * gData,
void * bData,
void * aData,
2919 PlanarImageDesc(
void * rData,
void * gData,
void * bData,
void * aData,
2920 long width,
long height,
2922 ptrdiff_t xStrideBytes,
2923 ptrdiff_t yStrideBytes);
2927 void * getRData()
const override;
2928 void * getGData()
const override;
2929 void * getBData()
const override;
2930 void * getAData()
const override;
2933 BitDepth getBitDepth()
const override;
2935 long getWidth()
const override;
2936 long getHeight()
const override;
2938 ptrdiff_t getXStrideBytes()
const override;
2939 ptrdiff_t getYStrideBytes()
const override;
2941 bool isRGBAPacked()
const override;
2942 bool isFloat()
const override;
2947 Impl * getImpl() {
return m_impl; }
2948 const Impl * getImpl()
const {
return m_impl; }
3020 const char * getUniqueID()
const noexcept;
3021 void setUniqueID(
const char * uid) noexcept;
3027 const char * getFunctionName()
const noexcept;
3029 void setFunctionName(
const char *
name) noexcept;
3031 const char * getPixelName()
const noexcept;
3033 void setPixelName(
const char * name) noexcept;
3042 const char * getResourcePrefix()
const noexcept;
3044 void setResourcePrefix(
const char * prefix) noexcept;
3046 virtual const char * getCacheID()
const noexcept;
3049 virtual void begin(
const char * uid);
3054 virtual void setTextureMaxWidth(
unsigned maxWidth) = 0;
3055 virtual unsigned getTextureMaxWidth()
const noexcept = 0;
3061 unsigned getNextResourceIndex() noexcept;
3076 virtual bool addUniform(
const char * name,
3079 virtual bool addUniform(
const char * name,
3082 virtual bool addUniform(
const char * name,
3085 virtual bool addUniform(
const char * name,
3089 virtual bool addUniform(
const char * name,
3097 unsigned getNumDynamicProperties()
const noexcept;
3120 virtual void addTexture(
const char * textureName,
3121 const char * samplerName,
3123 TextureType channel,
3125 const float *
values) = 0;
3135 virtual void add3DTexture(
const char * textureName,
3136 const char * samplerName,
3139 const float *
values) = 0;
3142 virtual void addToDeclareShaderCode(
const char * shaderCode);
3143 virtual void addToHelperShaderCode(
const char * shaderCode);
3144 virtual void addToFunctionHeaderShaderCode(
const char * shaderCode);
3145 virtual void addToFunctionShaderCode(
const char * shaderCode);
3146 virtual void addToFunctionFooterShaderCode(
const char * shaderCode);
3156 virtual void createShaderText(
const char * shaderDeclarations,
3157 const char * shaderHelperMethods,
3158 const char * shaderFunctionHeader,
3159 const char * shaderFunctionBody,
3160 const char * shaderFunctionFooter);
3162 virtual void finalize();
3363 virtual unsigned getNumUniforms()
const noexcept = 0;
3368 virtual
unsigned getNumTextures() const noexcept = 0;
3369 virtual
void getTexture(
unsigned index,
3370 const
char *& textureName,
3371 const
char *& samplerName,
3374 TextureType & channel,
3376 virtual
void getTextureValues(
unsigned index, const
float *&
values) const = 0;
3379 virtual
unsigned getNum3DTextures() const noexcept = 0;
3380 virtual
void get3DTexture(
unsigned index,
3381 const
char *& textureName,
3382 const
char *& samplerName,
3385 virtual
void get3DTextureValues(
unsigned index, const
float *&
values) const = 0;
3388 const
char * getShaderText() const noexcept;
3444 const char * getCacheID()
const;
3446 void setSearchPath(
const char *
path);
3447 const char * getSearchPath()
const;
3449 int getNumSearchPaths()
const;
3450 const char * getSearchPath(
int index)
const;
3451 void clearSearchPaths();
3452 void addSearchPath(
const char * path);
3453 void setWorkingDir(
const char * dirname);
3454 const char * getWorkingDir()
const;
3459 void setStringVar(
const char *
name,
const char *
value) noexcept;
3462 const char * getStringVar(
const char * name)
const noexcept;
3464 int getNumStringVars()
const;
3465 const char * getStringVarNameByIndex(
int index)
const;
3467 const char * getStringVarByIndex(
int index)
const;
3469 void clearStringVars();
3479 void loadEnvironment() noexcept;
3484 const char * resolveStringVar(
const char *
string)
const noexcept;
3487 const char * resolveStringVar(
const char *
string,
ContextRcPtr & usedContextVars)
const noexcept;
3499 const char * resolveFileLocation(
const char *
filename)
const;
3502 const char * resolveFileLocation(
const char * filename,
ContextRcPtr & usedContextVars)
const;
3509 Context(
const Context &) =
delete;
3510 Context& operator= (
const Context &) =
delete;
3517 static void deleter(Context* c);
3521 Impl * getImpl() {
return m_impl; }
3522 const Impl * getImpl()
const {
return m_impl; }
3545 virtual size_t getNumBuiltins()
const noexcept = 0;
3550 virtual const char * getBuiltinStyle(
size_t index)
const = 0;
3552 virtual const char * getBuiltinDescription(
size_t index)
const = 0;
3575 virtual size_t getNumBuiltinConfigs()
const noexcept = 0;
3579 virtual const char * getBuiltinConfigName(
size_t configIndex)
const = 0;
3583 virtual const char * getBuiltinConfigUIName(
size_t configIndex)
const = 0;
3587 virtual const char * getBuiltinConfig(
size_t configIndex)
const = 0;
3591 virtual const char * getBuiltinConfigByName(
const char * configName)
const = 0;
3605 virtual bool isBuiltinConfigRecommended(
size_t configIndex)
const = 0;
3623 virtual const char * getDefaultBuiltinConfigName()
const = 0;
3649 virtual bool isSupported()
const noexcept = 0;
3657 virtual size_t getNumMonitors()
const noexcept = 0;
3666 virtual const char * getMonitorName(
size_t idx)
const = 0;
3668 virtual const char * getProfileFilepath(
size_t idx)
const = 0;
3703 virtual std::vector<uint8_t> getLutData(
const char * filepath)
const = 0;
3729 virtual std::string getFastLutFileHash(
const char * filepath)
const = 0;
3734 #endif // INCLUDED_OCIO_OPENCOLORIO_H
OCIOEXPORT ConstColorSpaceSetRcPtr operator-(const ConstColorSpaceSetRcPtr &lcss, const ConstColorSpaceSetRcPtr &rcss)
Perform the difference of two sets.
OCIOEXPORT ConstConfigRcPtr GetCurrentConfig()
Get the current configuration.
EnvironmentMode
Controls which environment variables are loaded into a Context object.
GLuint GLsizei const GLchar * message
OCIO_SHARED_PTR< const ViewTransform > ConstViewTransformRcPtr
static const char * DefaultRuleName
Reserved rule name for the default rule.
class OCIOEXPORT GpuShaderDesc
PXL_API const char * getDescription(const ColorSpace *space)
Return the description of the color space.
GT_API const UT_StringHolder filename
PXL_API void getColorSpaces(UT_StringArray &names)
Returns a list of the supported color spaces.
This class holds the GPU-related information needed to build a shader program from a specific process...
std::function< const float *()> VectorFloatGetter
Function returning a float *, used by uniforms.
class OCIOEXPORT ColorSpaceSet
OCIOEXPORT void SetLoggingLevel(LoggingLevel level)
Set the global logging level.
OCIO_SHARED_PTR< ViewingRules > ViewingRulesRcPtr
OCIOEXPORT void SetComputeHashFunction(ComputeHashFunction hashFunction)
Set the Compute Hash Function to use; otherwise, use the default.
OCIO_SHARED_PTR< GpuShaderCreator > GpuShaderCreatorRcPtr
*get result *(waiting if necessary)*A common idiom is to fire a bunch of sub tasks at the and then *wait for them to all complete We provide a helper class
PXL_API void getActiveViews(UT_StringArray &names)
Returns the list of active views.
ChannelOrdering
Used by PackedImageDesc to indicate the channel ordering of the image to process. ...
This is a light-weight wrapper around an image, that provides a context for pixel access...
OCIO_SHARED_PTR< Processor > ProcessorRcPtr
IMF_EXPORT IMATH_NAMESPACE::V3f direction(const IMATH_NAMESPACE::Box2i &dataWindow, const IMATH_NAMESPACE::V2f &pixelPosition)
GLsizei const GLchar *const * string
class OCIOEXPORT BuiltinTransformRegistry
GLsizei const GLchar *const * path
OptimizationFlags
Provides control over how the ops in a Processor are combined in order to improve performance...
const Impl * getImpl() const
class OCIOEXPORT ViewingRules
OCIO_SHARED_PTR< const Transform > ConstTransformRcPtr
bool isIdentity(const MatType &m)
Determine if a matrix is an identity matrix.
OCIO_SHARED_PTR< FileRules > FileRulesRcPtr
std::function< int()> SizeGetter
Function returning an int, used by uniforms.
An exception class to throw for errors detected at runtime.
OCIO_SHARED_PTR< const BuiltinTransformRegistry > ConstBuiltinTransformRegistryRcPtr
std::function< const Float3 &()> Float3Getter
Functions returning a Float3, used by uniforms.
OCIO_SHARED_PTR< ConfigIOProxy > ConfigIOProxyRcPtr
Only need a red channel texture.
ImageBuf OIIO_API min(Image_or_Const A, Image_or_Const B, ROI roi={}, int nthreads=0)
PXL_API const char * getDefaultView(const char *display=NULL)
Returns the current color space name.
DynamicPropertyType
Types for dynamic properties.
GLenum GLenum GLsizei const GLuint GLboolean enabled
OCIOEXPORT void LogMessage(LoggingLevel level, const char *message)
Log a message using the library logging function.
class OCIOEXPORT Exception
OCIOEXPORT int GetVersionHex()
Get the version number for the library, as a single 4-byte hex number (e.g., 0x01050200 for "1...
OCIO_SHARED_PTR< const NamedTransform > ConstNamedTransformRcPtr
static const char * FilePathSearchRuleName
Reserved rule name for the file path search rule.
std::function< const int *()> VectorIntGetter
Function returning an int *, used by uniforms.
OCIOEXPORT void ClearAllCaches()
GpuLanguage
Used when there is a choice of hardware shader language.
ProcessorCacheFlags
cpp:type:: Enum to control the behavior of the internal caches e.g. the processor cache in ...
OCIO_SHARED_PTR< Look > LookRcPtr
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
OCIO_SHARED_PTR< const ProcessorMetadata > ConstProcessorMetadataRcPtr
class OCIOEXPORT GpuShaderCreator
GLint GLsizei GLsizei height
OCIO_SHARED_PTR< const Context > ConstContextRcPtr
class OCIOEXPORT CPUProcessor
OCIO_SHARED_PTR< ProcessorMetadata > ProcessorMetadataRcPtr
OCIO_SHARED_PTR< const CPUProcessor > ConstCPUProcessorRcPtr
OCIOEXPORT void SetLoggingFunction(LoggingFunction logFunction)
Set the logging function to use; otherwise, use the default (i.e. std::cerr).
OCIOEXPORT void ResetToDefaultLoggingFunction()
class OCIOEXPORT ViewTransform
PXL_API const char * getName(const ColorSpace *space)
Return the name of the color space.
class OCIOEXPORT ConfigIOProxy
OCIO_SHARED_PTR< Baker > BakerRcPtr
OCIOEXPORT const char * GetEnvVariable(const char *name)
class OCIOEXPORT ProcessorMetadata
A config defines all the color spaces to be available at runtime.
class OCIOEXPORT GPUProcessor
PXL_API bool getAllocationVars(const ColorSpace *space, bool &uniform, fpreal &min, fpreal &max, fpreal &offset)
Return the allocation variable meta data about the color space.
OPENVDB_API void setVersion(std::ios_base &, const VersionId &libraryVersion, uint32_t fileVersion)
Associate specific file format and library version numbers with the given stream. ...
std::function< void(const char *)> LoggingFunction
Define the logging function signature.
std::function< double()> DoubleGetter
Function returning a double, used by uniforms. GPU converts double to float.
OCIOEXPORT void SetEnvVariable(const char *name, const char *value)
OCIO_SHARED_PTR< const Processor > ConstProcessorRcPtr
GLuint const GLchar * name
OCIO_SHARED_PTR< const ColorSpaceSet > ConstColorSpaceSetRcPtr
OCIO_SHARED_PTR< const FileRules > ConstFileRulesRcPtr
#define OCIO_DEPRECATED(msg)
PXL_API const char * getDefaultDisplay()
Returns the current color space name.
GA_API const UT_StringHolder transform
OCIOEXPORT void ResetComputeHashFunction()
PXL_API const char * parseColorSpaceFromString(const char *string)
OCIOEXPORT const char * GetVersion()
Get the version number for the library, as a dot-delimited string (e.g., "1.0.0").
UniformDataType
Types for uniform data.
std::function< std::string(const std::string &)> ComputeHashFunction
Define Compute Hash function signature.
OCIO_SHARED_PTR< const SystemMonitors > ConstSystemMonitorsRcPtr
std::function< bool()> BoolGetter
Function returning a bool, used by uniforms.
OCIO_SHARED_PTR< ColorSpaceSet > ColorSpaceSetRcPtr
OCIO_SHARED_PTR< const Config > ConstConfigRcPtr
OCIO_SHARED_PTR< NamedTransform > NamedTransformRcPtr
OCIOEXPORT ConstColorSpaceSetRcPtr operator&&(const ConstColorSpaceSetRcPtr &lcss, const ConstColorSpaceSetRcPtr &rcss)
Perform the intersection of two sets.
OCIO_SHARED_PTR< const Look > ConstLookRcPtr
GLenum GLsizei GLsizei GLint * values
class OCIOEXPORT Processor
class OCIOEXPORT ImageDesc
OCIO_SHARED_PTR< Config > ConfigRcPtr
class OCIOEXPORT NamedTransform
OCIO_SHARED_PTR< Context > ContextRcPtr
OCIOEXPORT void SetCurrentConfig(const ConstConfigRcPtr &config)
Set the current configuration. This will then store a copy of the specified config.
OCIOEXPORT void ExtractOCIOZArchive(const char *archivePath, const char *destinationDir)
Extract an OCIO Config archive.
OCIOEXPORT std::ostream & operator<<(std::ostream &, const ColorSpaceMenuParameters &)
OCIO_SHARED_PTR< GpuShaderDesc > GpuShaderDescRcPtr
class OCIOEXPORT FileRules
OCIOEXPORT void UnsetEnvVariable(const char *name)
OCIOEXPORT bool IsEnvVariablePresent(const char *name)
cpp:function::
OCIOEXPORT ConstColorSpaceSetRcPtr operator||(const ConstColorSpaceSetRcPtr &lcss, const ConstColorSpaceSetRcPtr &rcss)
Perform the union of two sets.
class OCIOEXPORT SystemMonitors
OCIO_SHARED_PTR< GroupTransform > GroupTransformRcPtr
class OCIOEXPORT ColorSpace
PXL_API void getLooks(UT_StringArray &looks)
Returns a list of looks (color transforms)
bool operator!=(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
const ptrdiff_t AutoStride
OCIO_SHARED_PTR< const ViewingRules > ConstViewingRulesRcPtr
PXL_API void getActiveDisplays(UT_StringArray &names)
Returns the list of active displays.
OCIO_SHARED_PTR< ColorSpace > ColorSpaceRcPtr
OCIOEXPORT LoggingLevel GetLoggingLevel()
Get the global logging level.
An exception class for errors detected at runtime.
OCIO_SHARED_PTR< const ColorSpace > ConstColorSpaceRcPtr
OIIO_UTIL_API std::string extension(string_view filepath, bool include_dot=true) noexcept
OCIO_SHARED_PTR< const GPUProcessor > ConstGPUProcessorRcPtr
The File Rules are a set of filepath to color space mappings that are evaluated from first to last...
OCIO_SHARED_PTR< ViewTransform > ViewTransformRcPtr
OCIO_SHARED_PTR< DynamicProperty > DynamicPropertyRcPtr
PcpNodeRef_ChildrenIterator begin(const PcpNodeRef::child_const_range &r)
Support for range-based for loops for PcpNodeRef children ranges.