Inherits DD::Image::ProxyContext.
Public Types | |
enum | LineReadPreference { eScanlineAlways, ePreferScanline, ePreferAllLines } |
typedef ProxyContext::ProxySetting | ProxySetting |
Public Member Functions | |
double | frame () const |
void | setFrame (double v) |
mFnDeprecatedInNuke10Func ("Use OutputContext::setFrame() instead", void frame(double v);) int view() const | |
void | setView (int v) |
void | view (int v) |
void | setLineReadPreference (LineReadPreference linePreference) |
LineReadPreference | lineReadPreference () const |
void | append (Hash &) const |
bool | operator== (const OutputContext &other) const |
bool | operator!= (const OutputContext &other) const |
bool | operator< (const OutputContext &other) const |
bool | operator> (const OutputContext &other) const |
const std::string & | viewname () const |
const Format * | to_proxy_rel (const Format &from, Format &to, const OutputContext &rel) const |
bool | sameProxy (const DD::Image::OutputContext &other) const |
Static Public Member Functions | |
static const OutputContext & | defaultContext () |
static const std::string & | viewname (int v) |
static const std::string & | viewshort (int v) |
static int | viewcount () |
static bool | MultiView () |
static int | lookup_view (const std::string &viewname) |
static void | set_viewnames (const std::string &s) |
Static Public Attributes | |
static const OutputContext | default_ |
static void(* | create_view )(const std::string &s) |
static int(* | viewIndex )(const std::string &viewName, Op *op) |
static void(* | createView )(const std::string &viewName, const std::string &color, Op *op) |
static const std::string &(* | viewName )(int index, Op *op) |
static std::string(* | viewShortName )(int index, Op *op) |
static void(* | setViewNames )(const std::vector< std::string > &viewNames, Op *op) |
Sets the op's root node to have view's named viewNames. | |
static int(* | viewCount )(Op *op) |
Returns the number of views on the op's root node. | |
static bool(* | hasMultipleViews )(Op *op) |
Returns true if op's root node has more than one view. | |
Friends | |
std::ostream & | operator<< (std::ostream &o, const OutputContext &) |
This is a block of data that is passed *up* the Op tree. The context modifies the values that are stored by knobs. An Op can further use information from it (such as the frame number) to modify it's behavior, by implementing Op::setOutputContext(). And an Op can modify the context that is used by each input, by implementing Op::inputContext().
Preferences which can be used to influence how files are read by Readers. eScanlineAlways - upstream Reader should always read frames line by line. ePreferScanline - prefer line-by-line reads, but allow other nodes upstream to override this preference. ePreferAllLines - prefer to read the whole of the requested area at once, but allow other nodes upstream to override this preference.
void OutputContext::setLineReadPreference | ( | LineReadPreference | linePreference | ) |
By default readers read frames line by line (ePreferScanline). Some formats support reading the entire frame in one go. Setting the lineReadPreference can be used to switch between the two modes for these formats.
Referenced by DD::Image::Write::inputContext().
void OutputContext::append | ( | Hash & | hash | ) | const |
Add the contents of this to the hash, thus producing a different hash for any different setting of OutputContext.
int OutputContext::viewcount | ( | ) | [static] |
how many views exist. View 0 is always an extra view called 'default'. If there is one view, this is will be view 1.
Referenced by MultiView().
bool OutputContext::MultiView | ( | ) | [static] |
whether or not there are more than one actual view (not counting the hidden 'default' view)
References viewcount().
int(* OutputContext::viewIndex)(const std::string &viewName, Op *op) [static] |
If a view exists with name viewName on op's root node then that view's index is returned, otherwise -1 is returned.
void(* OutputContext::createView)(const std::string &viewName, const std::string &color, Op *op) [static] |
Creates a new view with name viewName and color on op's root node.
const std::string &(* OutputContext::viewName)(int index, Op *op) [static] |
If a view exists at index on op's root node then that view's name is returned, otherwise an empty string is returned.
std::string(* OutputContext::viewShortName)(int index, Op *op) [static] |
If a view exists at index on op's root node then that view's short name is returned, otherwise an empty string is returned.