Inherited by DD::Image::ReaderImpl, and DD::Image::WriterImpl.
Public Member Functions | |
LUTInfo (Op *pOp) | |
void | registerForCallbacks () |
This must be called after the Reader/Writer is constructed. | |
void | unregisterForCallbacks () |
LUTMapper * | mapper () const |
std::string | getBuiltinLUTName (LUTMapper *lutMapper, LUT *lut, std::string &mappedStringOut) |
void | updateColorspaceDefaultValue (Knob *k, Enumeration_KnobI *e, LUT *lut, LUTMapper *lutMapper, std::string &outDefaultLutName) |
virtual std::string | updateColorspaceDefaultValue () |
util function for calling updateColorspaceDefaultValue() | |
std::string | stripCascadingPrefix (const std::string &) const |
strip off cascading menus prefix | |
virtual LUT * | defaultLut () const =0 |
must return the LUT pointer used by the LUTInfo derived class | |
Protected Attributes | |
std::string | _overrideColorspaceName |
void LUTInfo::unregisterForCallbacks | ( | ) |
This must be called before the Reader/Writer is destructed and only if you want to unregister the callbacks earlier
References DD::Image::Knob::isCallbackRegistered(), and DD::Image::Knob::removeCallback().
std::string LUTInfo::getBuiltinLUTName | ( | LUTMapper * | lutMapper, |
LUT * | lut, | ||
std::string & | mappedStringOut | ||
) |
Get the name of the given builtin LUT. Will also use the provided writer (if any) to find the equivalent OCIO mapped name
References DD::Image::LUT::builtin_names, and DD::Image::LUT::GetBuiltinLUT().
Referenced by updateColorspaceDefaultValue().
void LUTInfo::updateColorspaceDefaultValue | ( | Knob * | k, |
Enumeration_KnobI * | e, | ||
LUT * | lut, | ||
LUTMapper * | lutMapper, | ||
std::string & | outDefaultLutName | ||
) |
updates the default LUT in the UI, that is, the first entry in the drop-down
References DD::Image::Knob::addCallback(), DD::Image::Knob::from_script(), getBuiltinLUTName(), DD::Image::Enumeration_KnobI::getError(), DD::Image::Enumeration_KnobI::getSelectedItemIndex(), DD::Image::Enumeration_KnobI::menu(), DD::Image::Knob::removeCallback(), and stripCascadingPrefix().
Referenced by DD::Image::Write::_validate(), and DD::Image::Write::updateDefaultLUT().