43 #define PXL_LOOKUP_1D 0x3F
44 #define PXL_SEPARATE_CHANNELS 0x10
45 #define PXL_SINGLE_CHANNEL 0x20
46 #define PXL_ILLEGAL_MATCH 0x30
47 #define PXL_LOG_SAMPLE 0x100
59 static struct BuildGammaTag {} BuildGamma;
60 static struct BuildSRGBTag {} BuildSRGB;
61 static struct BuildRec709Tag {} BuildRec709;
62 static struct BuildOCIOTag {} BuildOCIO;
84 const char *src_color_space,
85 const char *dest_color_space);
90 int64 getMemoryUsage(
bool inclusive)
const;
97 void evalLUT(
float color[3])
const;
103 void set3DLUT(
int size,
float *lut);
109 float black=0.0
f,
float white=1.0
f,
110 int comp = -1)
const;
115 fpreal indexToValue(
int i)
const;
120 bool isValid()
const;
124 bool getLogSampling()
const;
125 float getLogBias()
const;
126 int getNumChannels()
const;
127 int getTableSize()
const;
128 float getBlackPoint()
const;
129 float getWhitePoint()
const;
130 void getDomain(
float &
s,
float &e)
const;
131 void getRange(
float &
s,
float &e)
const;
138 void setLogSampling(
bool log);
139 void setLogBias(
float bias);
141 void setNumChannels(
int num);
142 void setTableSize(
int size);
143 void setBlackWhitePoints(
float b,
float w);
144 void setDomain(
float s,
float e);
145 void setRange(
float s,
float e);
146 void invert(
int newsize = 0);
151 bool is3DLUT()
const {
return myCubeSize != 0; }
163 unsigned w = 0)
const;
168 float black,
float white,
169 float from = 0.0
f,
float to = 1.0
f)
const;
172 void eval1DLUT(
float color[3])
const;
173 void get1DLUT(
float *lut[4],
int size,
float b,
float w,
174 float sc,
float sh,
float gamma)
const;
180 int comp = -1)
const;
183 void eval3DLUT(
float color[3])
const;
188 void copy3DLUT(
float *lut,
float *prelut = 0)
const;
195 float black = 0.0
f,
float white = 1.0
f,
196 int component = -1)
const;
200 bool load(
const char *
filename,
bool header_only =
false);
201 bool save(
const char *
filename,
bool half_prec=
false)
const;
204 bool load(FILE *fp,
bool header_only);
205 bool loadBinary(FILE *fp,
bool header_only);
206 bool save(FILE *fp)
const;
207 bool saveBinary(FILE *fp,
bool half_prec =
false)
const;
210 bool buildGamma(
fpreal gamma,
225 bool buildOpenColorIOView(
const char *src_color_space,
226 const char *display_name,
227 const char *view_name,
228 const char *baked_display=
nullptr,
229 const char *baked_view =
nullptr,
230 bool inverse =
false);
233 bool buildOpenColorIO(
const char *src_color_space,
234 const char *dest_color_space);
240 getCineonLUT(
bool forward,
250 void *getTextureID()
const;
251 void clearTextureID();
254 void *getPreLutID()
const;
261 inline void lerpPreLUT(
float &
color,
float prelut_scale,
262 const fpreal *prelut,
int prelut_last)
const;
264 void save1D(FILE *fp,
bool bin,
bool half =
false)
const;
265 void save3D(FILE *fp,
bool bin,
bool half =
false)
const;
273 void prep1DLUT(
float *
data,
int size,
GLboolean GLboolean GLboolean b
GT_API const UT_StringHolder filename
imath_half_bits_t half
if we're in a C-only context, alias the half bits type to half
float getPreShift() const
void setPreLutID(void *id)
std::unique_ptr< T, Deleter > UT_UniquePtr
A smart pointer for unique ownership of dynamically allocated objects.
GLubyte GLubyte GLubyte GLubyte w
HUSD_API const char * raster()
void setTextureID(void *id)
GLint GLint GLsizei GLint GLenum format
class OCIOEXPORT ColorSpace
OIIO_FORCEINLINE T log(const T &v)
IMATH_INTERNAL_NAMESPACE_HEADER_ENTER IMATH_HOSTDEVICE IMATH_CONSTEXPR14 T clip(const T &p, const Box< T > &box) IMATH_NOEXCEPT