#include <Transform.h>
Public Member Functions | |
void | _validate (bool) override |
void | setclip (const Box &) |
void | _request (int x, int y, int r, int t, ChannelMask, int count) override |
void | engine (int y, int x, int r, ChannelMask allchan, Row &row) override |
Transform (Node *node=nullptr) | |
Transform * | getTransform () override |
void | setInputsValid (bool) override |
HandlesMode | doAnyHandles (ViewerContext *ctx) override |
void | build_handles (ViewerContext *ctx) override |
void | draw_handle (ViewerContext *ctx) override |
Matrix4 * | matrix () |
virtual void | matrix (const Matrix4 &m) |
bool | transform (double x, double y, double &X, double &Y, double &Z) |
bool | concat_transform (double x, double y, double &X, double &Y, double &Z) |
void | reset () |
void | multiply (const Matrix4 &m) |
void | multiply (const Transform &t) |
void | premultiply (const Matrix4 &m) |
void | premultiply (const Transform &t) |
void | scale (float s) |
void | scale (float x, float y, float z=1.0) |
void | rotateX (float radians) |
void | rotateY (float radians) |
void | rotateZ (float radians) |
void | rotate (float radians) |
void | rotate (float a, float x, float y, float z) |
void | skew (float a) |
void | translate (float x, float y) |
void | translate (float x, float y, float z) |
const Filter * | filter () const |
int | filter_type () const |
void | filter_type (int t) |
bool | clamp () const |
void | clamp (bool v) |
bool | black_outside () const |
void | black_outside (bool v) |
const char * | Class () const override |
const char * | node_help () const override |
unsigned | node_color () const override |
const Matrix4 & | concat_matrix () const |
Iop * | concat_input () const |
void | filter_knobs (Knob_Callback) |
void | motionblur_knobs (Knob_Callback cb) |
void | knobs (Knob_Callback) override |
float | getMotionBlur () const |
bool | isMotionBlurring () const |
float | motionBlurSample (int x, int y, RowCacheTile &i, ChannelMask iChannels, Pixel &out) |
void | sample (const Vector2 ¢er, const Vector2 &dU, const Vector2 &dV, Filter *filter, Pixel &out) override |
void | sample (float cx, float cy, float w, float h, Filter *filter, Pixel &out) override |
bool | set_texturemap (ViewerContext *, bool) override |
Op * | realParent () |
Public Member Functions inherited from DD::Image::Iop | |
void | fetchPlane (ImagePlane &imagePlane) |
virtual PlanarI * | getPlanarI () |
void | force_validate (bool for_real=true) override |
IopImpl * | pImpl () |
virtual void | engine (int y, int x, int r, ChannelMask, Row &)=0 |
Iop * | iop () override |
Cast to an Iop. This is much cheaper and safer than using dynamic_cast. | |
const Iop * | iop () const override |
~Iop () override | |
virtual bool | isBlackIop () const |
bool | test_input (int, Op *) const override |
Op * | default_input (int) const override |
Iop * | input (int n) const |
Iop * | input (int n, int m) const |
Iop & | input0 () const |
Iop & | input1 () const |
Cache * | cache () const |
bool | cached () const |
void | cached (bool b) |
virtual void | in_channels (int, ChannelSet &) const |
ChannelMask | out_channels () const |
int | raw_channels_from () const |
virtual bool | pass_transform () const |
void | request (int x, int y, int r, int t, ChannelMask channels, int count) |
void | request (DD::Image::Box box, ChannelMask channels, int count) |
void | request (ChannelMask channels, int count) |
void | _copyState (Iop *input) |
const Box & | requestedBox () const |
const Box & | unclampedRequestedBox () const |
ChannelMask | requested_channels () const |
ChannelMask | multi_requested_channels () const |
ChannelMask | unclamped_requested_channels () const |
int | requested_count () const |
virtual void | get (int y, int x, int r, ChannelMask, Row &) |
void | at (int x, int y, Pixel &out) |
float | at (int x, int y, Channel) |
ChannelSet | peek (int x, int y, int r, int t, Pixel &out) |
bool | peek (int x, int y, int w, int h, ChannelMask pixelChannels, PixelCallbackI &callback) |
virtual Transform * | getTransform () |
virtual bool | set_texturemap (ViewerContext *, bool gl=true) |
virtual TextureImage | get_texturemap (ViewerContext *ctx) |
virtual void | unset_texturemap (ViewerContext *) |
virtual bool | shade_GL (ViewerContext *, GeoInfo &) |
virtual void | vertex_shader (VertexContext &) |
virtual void | fragment_shader (const VertexContext &, Pixel &out) |
virtual void | displacement_shader (const VertexContext &vtx, VArray &out) |
virtual float | displacement_bound () const |
virtual void | blending_shader (const Pixel &in, Pixel &out) |
virtual void | render_state (GeoInfoRenderState &state) |
virtual void | sample (float cx, float cy, float w, float h, Filter *, Pixel &out) |
void | sample (float cx, float cy, float w, float h, Pixel &out) |
virtual void | sample (const Vector2 ¢er, const Vector2 &dU, const Vector2 &dV, Filter *filter, Pixel &out) |
void | sample (const Vector2 ¢er, const Vector2 &dU, const Vector2 &dV, Pixel &out) |
virtual float | sample_shadowmap (Iop *map, bool map_is_one_over_z, float cx, float cy, float W, float H, Filter *filter, float Pz) |
void | build_handles (ViewerContext *) override |
virtual void | inputsAttached () |
virtual void | gpuEngine_useTextureTransform (bool useTransform) |
GPU support code. | |
virtual void | gpuEngine_setupTextureTransform (const Matrix4 &postOpTransform) |
virtual const char * | gpuEngine_decl () const |
virtual const char * | gpuEngine_body () const |
virtual Hash | gpuEngine_shader_hash_at (double time) |
virtual int | gpuEngine_getNumRequiredTexUnits () const |
virtual void | gpuEngine_GL_begin (GPUContext *context) |
virtual void | gpuEngine_GL_end (GPUContext *context) |
virtual Iop * | viewerPassThrough () const |
OpHints | opHints () const override |
Return hints to control when and how this op will be evaluated by the top-down system. | |
virtual void | setExtendedOpProperties (std::shared_ptr< ExtendedOpProperties > extendedOpProperties) |
Sets the pointer to object implementing extended properties. | |
virtual std::shared_ptr< ExtendedOpProperties > | getExtendedOpProperties () const |
Returns the pointer to object implementing extended properties. | |
Public Member Functions inherited from DD::Image::Op | |
PrevalidateResult | preValidate (ViewerContext *ctx=nullptr, PreValidateContext *=nullptr) |
Op * | rootOp () const |
bool | preValidateAborted (int treeStartingVersion, PrevalidateResult &result) const |
const OutputSet & | getOutputs () const |
return all the outputs of this node | |
virtual void | setInputsValid (bool nowValid) |
set whether the input ops are valid (are for the right context) | |
bool | inputsValid () const |
return whether the input ops are valid (are for the right context) | |
virtual bool | can_clone () const |
returns whether or not an op can be cloned in the dag | |
bool | haveHash () const |
return true if the hash() value is meaningful and globally unique | |
bool | varyingOutputHash () const |
void | setVaryingOutputHash (bool varyingHashes) |
Set the varyingOutputHash indicator to a specific state. | |
void | enableVaryingOutputHash () |
Enable the varyingOutputHash indicator. | |
virtual Hash | editState () const |
virtual void | setEditState (const Hash &h) |
virtual std::vector< DD::Image::OutputContext > | getPrevVersionsWanted () const |
virtual const MetaData::Bundle & | _fetchMetaData (const char *keyname) |
const MetaData::Bundle & | fetchMetaData (const char *keyname) |
Node * | node () const |
DD::Image::NodeI * | getNode () const |
void | node (Node *v) |
const char * | nodeName () const |
Return NodeI::name() which is the Node's local name with no parent path. | |
std::string | nodeFullPath (char separator='.') const |
Hash | nodeTopologyHash () const |
Op * | firstOp () const |
void | firstOp (Op *v) |
Op * | parent () const |
void | parent (Op *lpOp) |
virtual void | detach () |
node has been deleted in DAG | |
virtual void | attach () |
node has been created in DAG | |
virtual void | pre_write_knobs () |
void | knobStorePrep (const OutputContext &storeContext) |
virtual void | knobs (Knob_Callback) |
void | knobStorePost (const OutputContext &storeContext, Hash &hash) |
int | replace_knobs (Knob *afterthis, int n, void(*f)(void *, Knob_Callback), void *, const char *fileExt=nullptr) |
int | add_knobs (void(*f)(void *, Knob_Callback), void *, Knob_Callback) |
void | set_unlicensed () |
Knob * | knob (const char *name) const |
Knob * | knob (int) const |
bool | pushed () const |
bool | panel_visible () const |
bool | node_disabled () const |
bool | node_selected () const |
unsigned | node_gl_color () const |
void * | field (const char *name) |
void * | field (const char *name, int &type) |
void * | set_field (const char *name, const void *source, int size) |
void * | get_field (const char *name, void *dest, int size) |
void | beginHandle (HandleType command, ViewerContext *ctx, EventCallback *cb, int index, float x=0, float y=0, float z=0, ViewerContext::Cursor cursor=ViewerContext::kNoCursor) |
void | endHandle (ViewerContext *ctx) |
virtual int | knob_changed (Knob *) |
virtual int | knob_change_finished (Knob *knob, bool changedByUser=true) |
void | addTime (OpTimer::Category category, long long microsecondsCPU, long long microsecondsWall, bool isTopLevel=true) |
void | getPerformanceInfo (OpTimer::Category category, OpTimer::PerformanceInfo &info) const |
return the amount of CPU time taken by this op | |
virtual bool | inputs_clockwise () const |
whether unconnected inputs on the DAG should be arranged clockwise or anticlockwise (default) | |
virtual std::vector< int > | input_order () const |
virtual int | inputArrows (int nodeInputs) const |
bool | script_command (const char *command, bool py=true, bool eval=true) const |
bool | script_expand (const char *str) const |
HandlesMode | anyHandles (ViewerContext *ctx) |
virtual void | build_handles (ViewerContext *) |
void | add_draw_handle (ViewerContext *) |
virtual void | draw_handle (ViewerContext *) |
virtual void | add_input_handle (int input, ViewerContext *) |
void | add_op_handle (ViewerContext *ctx) |
void | add_knob_handle (Knob *, ViewerContext *) |
virtual int | getViewableModes () const |
virtual int | optional_input () const |
virtual int | minimum_inputs () const |
virtual int | maximum_inputs () const |
virtual bool | test_input (int, Op *) const |
int | inputs () const |
int | node_inputs () const |
Op * | node_input (int, GenerateType=OUTPUT_OP) const |
Op * | node_input (int, GenerateType, const DD::Image::OutputContext *outputContext) const |
Op * | input_op (int n=0) const |
virtual void | inputs (int n) |
Op * | input (int) const |
int | inputNumber (int input, int offset) const |
Op * | input (int input, int offset) const |
Op * | input0 () const |
return the primary input | |
Op * | input1 () const |
return the second input, if it exists | |
const std::vector< Op * > & | getInputs () const |
const std::vector< Op * > & | getChildren () const |
virtual void | set_input (int i, Op *op, int input, int offset) |
void | set_input0 (Op *op) |
void | set_input (int i, Op *op) |
void | set_input (int i, Op &op) |
void | set_input (int input, int offset, Op *op) |
const OutputContext & | outputContext () const |
virtual void | setOutputContext (const OutputContext &c) |
virtual void | append (Hash &) |
virtual float | uses_input (int) const |
virtual void | build_splits () |
virtual int | split_input (int) const |
virtual const OutputContext & | inputContext (int n, int offset, OutputContext &) const |
virtual const OutputContext * | inputUIContext (int n, OutputContext &) const |
virtual Op * | default_input (int) const |
const Hash & | hash () const |
virtual bool | frameTransformImplemented () const |
virtual bool | frameTransformDownstream (const OutputContext &context, unsigned int input, float inFrame, float &outFrame) const |
virtual bool | frameTransformUpstream (const OutputContext &context, unsigned int input, float outFrame, float &inFrame) const |
virtual DopeItemFlags::Mask | getDopeItemFlags () const |
virtual bool | shouldHideInDopeSheet (Knob *knob) const |
virtual DD::Image::Knob * | getDopeItemKnob () const |
virtual ViewSet | viewsProduced () const |
virtual ViewSet | viewsWantOn (int i) const |
virtual ViewSet | splitForViews () const |
bool | requested () const |
void | setRequested () |
void | forgetRequestShallow () |
void | forget_request () |
void | forget_request (std::set< Op * > &forgotten) |
virtual const char * | node_shape () const |
DD::Image::Hash | curveHash () const |
bool | opCurrent () const |
virtual unsigned | node_color () const |
virtual const char * | node_help () const =0 |
virtual const char * | input_label (int, char *) const |
virtual std::string | input_longlabel (int) const |
void | node_redraw () |
void | print_name (std::ostream &o) const |
NodeContext | nodeContext () const |
std::string | node_name () const |
Returns the same string as printed by print_name(ostream). | |
void | invalidateSameHash () |
bool | invalidate () |
bool | invalidate (const Hash &hash) |
bool | update (const Box *=nullptr) |
void | asapUpdate () |
void | asapUpdate (const Box &box, int direction=0) |
void | validate (bool for_real=true) |
virtual void | force_validate (bool for_real=true) |
void | update_handles () const |
bool | valid () const |
Returns true if it has been validated - including if there was an error. | |
bool | real_valid () const |
Returns true if it has been real-validated - including if there was an error. | |
bool | inErrorState () const |
bool | inInvalidState () const |
bool | opened () const |
void | open () |
void | unopen () |
bool | running () const |
void | running (bool v) |
bool | not_closed () const |
void | close () |
void | callCloseAfter (double seconds) |
void | copyState (Op *input) |
bool | cached () const |
void | cached (bool b) |
virtual bool | inUse () const |
virtual Executable * | executable () |
void | setKnobsToContext (const OutputContext &, bool force=false) |
void | gotoContext (const OutputContext &, bool update) |
void | progressFraction (double fraction, StatusFlags flags=StatusNone) |
void | progressFraction (int a, int b, StatusFlags flags=StatusNone) |
void | progressMessage (const char *fmt,...) |
void | progressModalMessage (const char *fmt,...) |
void | progressDismiss () |
int | slowness () const |
void | slowness (int newval) |
virtual bool | firstEngineRendersWholeRequest () const |
virtual bool | updateUI (const OutputContext &context) |
const Format & | input_format () const |
const OutputContext & | uiContext () const |
void | error (const char *fmt,...) |
void | warning (const char *fmt,...) |
void | critical (const char *fmt,...) |
void | debug (const char *fmt,...) |
void | abort () const |
Abort all trees the op is in. | |
bool | aborted () const |
True if one of the trees the op is in was aborted; ops should check this while processing and return quickly when true. | |
void | cancel () const |
Cancel all trees the op is in. Make sure you also call abort() to stop processing. | |
bool | cancelled () const |
True if one of the trees the op is in was cancelled (by user interaction) | |
bool | addToTree (OpTree *lpTree) |
Returns true if the op was added to the tree, or false if its reference count increased. | |
bool | removeFromTree (OpTree *lpTree) |
Returns false if the op was removed from the tree, or true if its reference count decreased. | |
bool | isInTree (OpTree *lpTree) const |
Checks if an op is in a particular tree, for debugging purposes. | |
bool | isInAnyTree () const |
Checks if an op is in any tree at all. | |
OpTreeHandler * | getTreeHandler () const |
Returns the treeHandler for a given Op. | |
bool | hasError () const |
bool | opOrChildHasError () const |
const Op * | getErroredOp () const |
void | setPopUpScheme (PopUpScheme lScheme) |
PopUpScheme | getPopUpScheme () const |
bool | arePopUpsEnabled () |
Returns whether a pop-up should be enabled for the next message, modifying internal data when necessary. | |
OpMessageHandler & | getMsgHandler () |
const OpMessageHandler & | getMsgHandler () const |
std::string | getDebugInfo () const |
Returns a string of debug information about the op. For internal use. | |
std::string | getDetailedDebugInfo () const |
bool | tryValidate (bool for_real=true) |
virtual Iop * | iop () |
Cast to an Iop. This is much cheaper and safer than using dynamic_cast. | |
virtual const Iop * | iop () const |
virtual GeoOp * | geoOp () |
Cast to a GeoOp. This is much cheaper and safer than using dynamic_cast. | |
virtual const GeoOp * | geoOp () const |
virtual GeomOp * | geomOp () |
Cast to a GeomOp. This is much cheaper and safer than using dynamic_cast. | |
virtual const GeomOp * | geomOp () const |
virtual ParticleOp * | particleOp () |
Cast to a ParticleOp. This is much cheaper and safer than using dynamic_cast. | |
virtual const ParticleOp * | particleOp () const |
virtual DeepOnlyOp * | deepOnlyOp () |
Cast to a DeepOnlyOp. This is much cheaper and safer than using dynamic_cast. | |
virtual const DeepOnlyOp * | deepOnlyOp () const |
virtual AxisOp * | axisOp () |
Cast to an AxisOp. This is much cheaper and safer than using dynamic_cast. | |
virtual const AxisOp * | axisOp () const |
virtual CameraOp * | cameraOp () |
Cast to an CameraOp. This is much cheaper and safer than using dynamic_cast. | |
virtual const CameraOp * | cameraOp () const |
virtual LightOp * | lightOp () |
Cast to an LightOp. This is much cheaper and safer than using dynamic_cast. | |
virtual const LightOp * | lightOp () const |
virtual std::string | getLibraryName () const |
Return a label and version string to display library version info for the Node. | |
virtual VersionInfo | getLibraryVersion () const |
virtual OpHints | opHints () const |
Return hints to control when and how this op will be evaluated by the top-down system. | |
virtual const char * | Class () const =0 |
const std::string | libraryDisplayName () const |
virtual const char * | displayName () const |
virtual std::string | docsPath () const |
virtual bool | onAction (const ViewerContext *c, const DD::Image::Flags f, void *d) |
Op * | get (const Description *description) |
Public Member Functions inherited from DD::Image::IopInfoOwner | |
const Info & | info () const |
int | x () const |
int | y () const |
int | r () const |
int | t () const |
int | w () const |
int | h () const |
bool | is_constant () const |
int | clampx (int x) const |
int | clampy (int y) const |
const Format & | format () const |
const Format & | full_size_format () const |
int | ydirection () const |
bool | black_outside () const |
ChannelMask | channels () const |
const GeneralInfo & | generalInfo () const override |
const Info2D & | info2D () const override |
int | first_frame () const |
int | last_frame () const |
void | format (const Format &f) |
void | full_size_format (const Format &f) |
Static Public Member Functions | |
static double | mitchell (double b, double c, double x) |
Static Public Member Functions inherited from DD::Image::Iop | |
static Iop * | default_input (const OutputContext &) |
static Op * | default_input (const Op *op) |
static Channel | channel (const char *name) |
static const char * | channel_name (Channel c) |
Static Public Member Functions inherited from DD::Image::Op | |
static int | treeVersion () |
static bool | nukeBusy () |
is nuke processing something on a parallel thread? | |
static Op * | create (Node *node, const char *name, Op *p_op) |
static Op * | create (const char *name, Op *p_op) |
static void | resetTimers () |
reset all the performance timers | |
static void | setTimingEnabled (bool enabled) |
turn performance timing on or off | |
static bool | isTimingEnabled () |
return whether performance timing is on or not | |
static const char * | script_result (bool py=false) |
static void | script_unlock () |
static Op * | retrieveOp (const char *node_path, GenerateType generate_op_type, const OutputContext *generate_op_context=nullptr) |
static Op * | retrieveOp (const char *node_path, const Hash &op_hash, int tree_version) |
static void | all_forget_request () |
static void | new_request_pass () |
static double | callPendingClose (double seconds) |
static void | clearPendingClose () |
static Op * | error_op () |
static const char * | error_message () |
static void | clearAbortAndError () |
To be removed. | |
static void | SetDefaultPopUpEnable (bool lEnable) |
This is used by Nuke to indicate when ops using the default pop-up scheme should show pop-ups. Not recommended for customisation. | |
static std::string | getVersionInfoStr (const VersionInfo &versionInfo) |
Helper function to convert a VersionInfo tuple into a string. | |
static const Description * | find_description (const char *name, const Op *op_) |
static int | message_f (char t, const char *,...) |
static int | message_vf (char t, const char *, va_list) |
static void | add_timeout (float t, TimeoutHandler, void *v=nullptr) |
static void | repeat_timeout (float t, TimeoutHandler, void *=nullptr) |
static bool | has_timeout (TimeoutHandler, void *=nullptr) |
static void | remove_timeout (TimeoutHandler, void *=nullptr) |
Protected Member Functions | |
bool | degenerate () |
virtual void | matrixAt (const OutputContext &, Matrix4 &dest) |
void | concatMatrixAt (const OutputContext &, Matrix4 &dest) |
void | append (Hash &hash) override |
void | updateConcat (bool setInfo) |
update the concat_matrix_ / concat_input_ / concat_clamp_ / concat_black_outside_ | |
Protected Member Functions inherited from DD::Image::Iop | |
Iop (Node *node) | |
void | _invalidate () override |
void | _validate (bool for_real) override |
virtual void | _request (int x, int y, int r, int t, ChannelMask, int count) |
void | _open () override |
void | _close () override |
virtual void | doFetchPlane (ImagePlane &imagePlane) |
bool | inUse () const override |
void | copy_info (int input) |
void | copy_info (int input, ChannelMask) |
void | copy_info () |
void | clear_info () |
void | merge_info (int input=0) |
void | merge_info (int input, ChannelMask) |
void | mergeFrameRange (int input) |
void | set_out_channels (ChannelMask m) |
void | set_out_channels (ChannelSetInit m) |
void | set_out_channels (Channel z) |
void | raw_channels_from (int n) |
void | set_out_channels (ChannelMask m, int n) |
Iop * | asIop (Op *op) const |
Transform * | getDefaultTransform () const |
template<class TileType > | |
void | doSample (float cx, float cy, float w, float h, Filter *, Pixel &out) |
template<class TileType > | |
float | do_sample_shadowmap (Iop *map, bool map_is_one_over_z, float cx, float cy, float W, float H, Filter *filter, float Pz) |
Protected Member Functions inherited from DD::Image::Op | |
Op (Node *node) | |
The constructor is protected so only subclasses can create the base class. | |
virtual void | _knobStorePrep (const OutputContext &storeContext) |
The subclass-specific portion of knobStorePrep(). See that method for more info. | |
virtual void | _knobStorePost (const OutputContext &storeContext, Hash &hash) |
The subclass-specific portion of knobStorePost(). See that method for more info. | |
virtual void | _invalidate () |
virtual void | _validate (bool for_real) |
virtual void | _open () |
virtual void | _close () |
Op * | create (Node *node, const char *name) |
Op * | create (const char *name) |
HandlesMode | anyInputHandles (ViewerContext *) |
return if any of the inputs (recursively) wish to draw handles | |
HandlesMode | anyKnobHandles (ViewerContext *) |
return if any of the knobs on this node wish to draw handles | |
void | build_input_handles (ViewerContext *) |
void | build_knob_handles (ViewerContext *) |
void | disallowNoTrees () |
Call this to tell the op that it should always have op trees for normal behaviour (for internal use) | |
virtual HandlesMode | doAnyHandles (ViewerContext *ctx) |
virtual PrevalidateResult | doPreValidate (ViewerContext *ctx=nullptr, PreValidateContext *=nullptr) |
Protected Attributes | |
Matrix4 | matrix_ |
Matrix4 | concat_matrix_ |
Iop * | concat_input_ |
bool | clamp_ |
bool | black_outside_ |
bool | concat_clamp_ |
bool | concat_black_outside_ |
bool | can_concat |
float | _motionblur |
amount of motion blur to do, '1' being heuristically'enough' | |
ShutterControls | _shutter |
shutter controls for motion blurring | |
Filter | filter_ |
Protected Attributes inherited from DD::Image::Iop | |
ChannelSet | out_channels_ |
protected so validate() can directly modify it | |
int | raw_channels_from_ |
Protected Attributes inherited from DD::Image::Op | |
bool | _haveHash |
whether the _hash actually has been set by a call to invalidate(Hash) ever. | |
bool | _varyingOutputHash |
whether the hash value will animate over time | |
Hash | _editState |
Op's current edit state, usually the combination of input & knob edit states. | |
Protected Attributes inherited from DD::Image::IopInfoOwner | |
Info | info_ |
Friends | |
class | TransformI |
Additional Inherited Members | |
Public Types inherited from DD::Image::Op | |
enum | HandlesMode { eNoHandles , eHandlesUncooked , eHandlesCooked , eHandlesMax } |
enum | PrevalidateResult { eFinished , eCancelled , eAbandoned } |
This is a tribool return value. Do not extend. | |
enum | HandleType { eNone , eMouseLeftClick , eMouseRightClick , eMouseMove , eMouseDrag , eMouseRelease , eSelectionChanged , eSelectionChangeFinished , eHandleDragTranslate , eHandleDragRotate , eHandleDragScale , eHandleDragPivot , eAllHandles } |
enum | ViewableModes { eViewableMode2D , eViewableMode3D , eViewableMode3D_2DReference } |
enum | GenerateType { OUTPUT_OP , ANY_CONTEXT , INPUT_OP , INPUT_OP_PEEK , EXECUTABLE , EXECUTABLE_SKIP , EXECUTABLE_INPUT , UICONTEXT_ONLY } |
enum | NodeContext { eNodeGraph , eTimeline , eOpGraph } |
enum | StatusFlags { StatusNone , StatusModal , StatusUseCallback } |
enum | PopUpScheme { ePU_Never , ePU_Done , ePU_Once , ePU_Default , ePU_Always } |
Pop-up schemes determine when pop-up messages are displayed for op errors. More... | |
enum | VersionComponents { eMajor , eMinor , ePoint , eRevision } |
Enum to help get the desired version component from the VersionInfo tuple. | |
typedef std::pair< int, DD::Image::Op * > | Output |
Combination of input number and pointer to Op. | |
typedef std::set< Output > | OutputSet |
Set of all outputs from this Op. | |
typedef std::map< Hash, std::vector< unsigned int > > | ItemSelectionList |
typedef bool() | EventCallback(Op *op, EventContext eventCtx) |
using | VersionInfo = std::tuple< int, int, int, int > |
Contains version components with each index defined by the VersionComponents enum. | |
Public Types inherited from DD::Image::IopInfoOwner | |
typedef IopInfo | Info |
Public Attributes inherited from DD::Image::Op | |
const MetaData::Bundle * | metaCache |
Hash | metaCacheHash |
Static Public Attributes inherited from DD::Image::Iop | |
static bool | sPreserveCaches |
Static Public Attributes inherited from DD::Image::Op | |
static unsigned | current_request_pass |
static void(* | node_redraw_cb )(const Op *) |
static void(* | print_name_cb )(std::ostream &, const Op *) |
static void(* | status_callback )(const Op *, float, float, const char *, StatusFlags) |
static const int | kInvalidVersion |
static const VersionInfo | kUnsetVersion |
Transforms the input image by a 4x4 transformation matrix.
Transform::Transform | ( | Node * | node = nullptr | ) |
The constructor sets the transformation to the identity matrix.
References _motionblur, and DD::Image::Matrix4::makeIdentity().
|
protected |
_validate() calls this when the output image is invisible or otherwise cannot be calculated. It deletes the tp object to indicate this.
References DD::Image::IopInfo::black_outside(), DD::Image::IopInfoOwner::info_, DD::Image::Box::set(), and DD::Image::Op::slowness().
Referenced by _validate().
|
protectedvirtual |
For implementing motion blur, return the matrix at various times. Default version changes the knobs and calls validate(), but a subclass can replace this if there is a faster way.
References matrix(), DD::Image::Op::outputContext(), DD::Image::Op::setKnobsToContext(), and DD::Image::Op::validate().
|
overrideprotectedvirtual |
Since _validate is fetching out values of knobs at nearby times to do motionblurring, we have to hash those in here, otherwise changing the velocity of the curve without changing its value will not result in the hash changing.
Reimplemented from DD::Image::Op.
References _shutter, DD::Image::Matrix4::append(), DD::Image::ShutterControls::calcOffset(), DD::Image::ShutterControls::getDuration(), DD::Image::Op::hash(), matrix(), DD::Image::Op::outputContext(), step(), and DD::Image::Op::validate().
|
overridevirtual |
_validate() will combine all adjacent Transform operators into a single one. When you call engine() it will skip the earlier operators, read from the input to the first one (concat_input()), and process by a concatenated transformation matrix (concat_matrix()).
Reimplemented from DD::Image::Iop.
References _motionblur, _shutter, DD::Image::IopInfo::black_outside(), DD::Image::ShutterControls::calcOffset(), DD::Image::IopInfoOwner::channels(), degenerate(), DD::Image::ShutterControls::getDuration(), DD::Image::Box::h(), DD::Image::IopInfoOwner::info(), DD::Image::IopInfoOwner::info_, DD::Image::Iop::input0(), DD::Image::Filter::interpolative(), matrix(), DD::Image::Box::merge(), DD::Image::Box::move(), DD::Image::Op::outputContext(), DD::Image::Box::pad(), DD::Image::Box::set(), DD::Image::Op::slowness(), DD::Image::IopInfoOwner::t(), updateConcat(), DD::Image::Op::validate(), DD::Image::Box::w(), DD::Image::IopInfoOwner::w(), DD::Image::Box::x(), DD::Image::IopInfoOwner::x(), DD::Image::Box::y(), DD::Image::IopInfoOwner::y(), DD::Image::IopInfoOwner::ydirection(), and DD::Image::IopInfo::ydirection().
void Transform::setclip | ( | const Box & | box | ) |
After _validate() is called a subclass can call this to force the Transform to clip the output to a rectangle and put black outside it. The rectangle is exactly 1 pixel inside the passed Box (ie the box includes the black edge). The info() is set to this box. This is used by Reformat.
References DD::Image::IopInfoOwner::info_, and DD::Image::Box::set().
|
overridevirtual |
Reimplemented from DD::Image::Iop.
|
overridevirtual |
Implements DD::Image::Iop.
|
inlineoverridevirtual |
Reimplemented from DD::Image::Iop.
|
overridevirtual |
this needs calling whenever the input pointers change even if they are pointing to equivalent Ops, as the Transform keeps its own pointers to its inputs.
Reimplemented from DD::Image::Op.
References DD::Image::Iop::input(), DD::Image::Op::setInputsValid(), and updateConcat().
|
overridevirtual |
Reimplemented from DD::Image::Op.
|
overridevirtual |
draw_handle() will draw the input texture map. We only want this to happen for the first operator, so that if the user has several open at once the texture is only drawn once.
Reimplemented from DD::Image::Iop.
References DD::Image::Op::add_draw_handle(), DD::Image::Op::build_input_handles(), DD::Image::Op::build_knob_handles(), DD::Image::CONNECTED, DD::Image::ViewerContext::connected(), DD::Image::ViewerContext::modelmatrix, DD::Image::Op::node_disabled(), DD::Image::Op::panel_visible(), DD::Image::Op::pushed(), DD::Image::Iop::set_texturemap(), DD::Image::SHOW_OBJECT, DD::Image::SHOW_PUSHED_OBJECT, DD::Image::ViewerContext::transform_mode(), DD::Image::Op::validate(), and DD::Image::VIEWER_2D.
|
overridevirtual |
Draws a rectangle the size of the input format, filled with the input as a texture map if possible.
Reimplemented from DD::Image::Op.
References DD::Image::ViewerContext::display3d(), DD::Image::ViewerContext::draw_lines(), DD::Image::ViewerContext::draw_transparent(), DD::Image::IopInfoOwner::format(), DD::Image::gl_rectangle(), DD::Image::glColor(), DD::Image::IopInfoOwner::info(), DD::Image::ViewerContext::node_color(), DD::Image::Box::r(), DD::Image::IopInfoOwner::r(), DD::Image::Iop::set_texturemap(), DD::Image::style_needs_wireframe(), DD::Image::Box::t(), DD::Image::IopInfoOwner::t(), DD::Image::Iop::unset_texturemap(), DD::Image::Box::x(), DD::Image::IopInfoOwner::x(), DD::Image::Box::y(), and DD::Image::IopInfoOwner::y().
|
static |
Evaluate a Mitchell filter at position x. This can be used by Nuke to view the filter shapes.
References DD::Image::IopInfoOwner::x().
Matrix4 * Transform::matrix | ( | ) |
This virtual function should return the matrix used. A subclass can call reset() and then scale, translate, etc to get the matrix wanted and then return Transform::matrix(). You can also skip doing anything and return Transform::matrix() if valid() is true, since you know the matrix has been calculated then.
Referenced by _validate(), append(), matrixAt(), and updateConcat().
bool Transform::transform | ( | double | x, |
double | y, | ||
double & | X, | ||
double & | Y, | ||
double & | Z | ||
) |
Transform an input uv position into an output xyw.
Returns false for w <= 0. Such a point is not visible and has no output x/y position. However this version makes a "guess" as to what direction visible pixels that are near uv are and returns very large values for x,y in that direction. This is useful for calculating resulting bounding boxes.
References DD::Image::IopInfoOwner::w(), DD::Image::IopInfoOwner::x(), and DD::Image::IopInfoOwner::y().
bool Transform::concat_transform | ( | double | x, |
double | y, | ||
double & | X, | ||
double & | Y, | ||
double & | Z | ||
) |
Same as transform() but it uses the concatenated matrix, thus transforming coordinates from concat_input(). This only works after validate() has been called.
References DD::Image::IopInfoOwner::w(), DD::Image::IopInfoOwner::x(), and DD::Image::IopInfoOwner::y().
|
inline |
Set the transformation to the identity.
References DD::Image::Matrix4::makeIdentity().
|
inline |
Transform further by an arbitrary transformation matrix. Like OpenGL all transformation operations are done by post-multiply, so this transformation is applied in the object's space. For instance a rotate(1) followed by a translate(1,0) will move the center of the object along a diagonal line.
|
inline |
Rotate about x (top towards camera) by angle radians.
References radians(), and DD::Image::Matrix4::rotateX().
|
inline |
Rotate about y (left edge towards camera) by angle radians.
References radians(), and DD::Image::Matrix4::rotateY().
|
inline |
Rotate about z (counter-clockwise) by angle radians.
References radians(), and DD::Image::Matrix4::rotateZ().
|
inline |
Set what filter to use. This is an index into a table presented to the user in the Nuke GUI. Index 0 is impulse, index 1 is our default filter (Cubic). Others are not defined and may change at any time.
Return the current filter type.
Referenced by sample().
|
inline |
If true then any negative intermediate results are set to zero. This can improve the results from high-contrast images and filters with negative lobes if you know nothing in the input is negative, by deleting a lot of the ringing in black areas.
The default value is false.
|
inline |
If true the transform will act as though any data outside the incoming bounding box is black. It will also produce an alpha channel if there is none in the input.
If this is false, Transform will replicate the pixels outside the bounding box instead. This will prevent any antialiasing on the edge. This is used by the Reformat operator, and may be useful for tile or camera shake type operators.
The default value is true.
|
overridevirtual |
Implements DD::Image::Op.
|
overridevirtual |
Implements DD::Image::Op.
|
overridevirtual |
All transform operators default to a purpleish color.
Reimplemented from DD::Image::Op.
|
inline |
After _validate() is done, this returns the transformation between the concat_input() and the output of this operator.
Referenced by updateConcat().
|
inline |
After _validate() is done this returns the operator that input will actually be read from.
Referenced by updateConcat().
void Transform::filter_knobs | ( | Knob_Callback | cb | ) |
Subclasses should call this to insert a filter-selection control into their control panels. This adds the "filter type" and "clamp" controls.
References DD::Image::Bool_knob(), DD::Image::Filter::knobs(), DD::Image::Knob::NODEGRAPH_ONLY, DD::Image::Knob::set_flag(), DD::Image::SetFlags(), and DD::Image::Tooltip().
Referenced by knobs().
void Transform::motionblur_knobs | ( | Knob_Callback | cb | ) |
Adds the motionblur amount and shutter knobs
do the shutter controls
References _motionblur, _shutter, DD::Image::Float_knob(), DD::Image::ShutterControls::knobs(), DD::Image::Knob::NODEGRAPH_ONLY, DD::Image::Knob::set_flag(), DD::Image::SetFlags(), and DD::Image::Tooltip().
Referenced by knobs().
|
overridevirtual |
Does filter_knobs, adds the "black outside" knob, and does motionblur_knobs()
Reimplemented from DD::Image::Op.
References DD::Image::Bool_knob(), filter_knobs(), motionblur_knobs(), DD::Image::Knob::NODEGRAPH_ONLY, DD::Image::Obsolete_knob(), DD::Image::SetFlags(), and DD::Image::Tooltip().
float Transform::motionBlurSample | ( | int | x, |
int | y, | ||
RowCacheTile & | i, | ||
ChannelMask | iChannels, | ||
Pixel & | out | ||
) |
Do motion blurring for the pixel, returns the guestimated path length of the sample
References DD::Image::RowCacheTile::at(), fast_floor(), DD::Image::Op::hash(), DD::Image::IopInfoOwner::info(), MIN(), DD::Image::p_random(), DD::Image::Box::r(), DD::Image::Box::t(), DD::Image::IopInfoOwner::t(), DD::Image::IopInfoOwner::w(), DD::Image::Box::x(), DD::Image::IopInfoOwner::x(), DD::Image::Box::y(), and DD::Image::IopInfoOwner::y().
|
overridevirtual |
Texture filtering function. Disables motion blur!
Reimplemented from DD::Image::Iop.
References DD::Image::Op::aborted(), DD::Image::Filter::Coefficients::array, DD::Image::Iop::at(), DD::Image::GeneralTile::channels(), DD::Image::GeneralTile::clampx(), DD::Image::GeneralTile::clampy(), DD::Image::Filter::Coefficients::count, DD::Image::Filter::Coefficients::delta, filter(), DD::Image::Filter::Coefficients::first, DD::Image::Filter::get(), DD::Image::IopInfoOwner::info(), DD::Image::Filter::Coefficients::normalize, DD::Image::Box::r(), DD::Image::GeneralTile::r(), DD::Image::Iop::sample(), DD::Image::Box::t(), DD::Image::GeneralTile::t(), DD::Image::GeneralTile::valid(), DD::Image::Box::x(), DD::Image::GeneralTile::x(), DD::Image::IopInfoOwner::x(), DD::Image::Box::y(), DD::Image::GeneralTile::y(), and DD::Image::IopInfoOwner::y().
Referenced by sample().
|
overridevirtual |
Disables motion blur!
Reimplemented from DD::Image::Iop.
References filter(), DD::Image::IopInfoOwner::h(), sample(), DD::Image::Iop::sample(), and DD::Image::IopInfoOwner::w().
|
overridevirtual |
Uses the input's texture map, but changes the OpenGL texture matrix to show it correctly translated.
Reimplemented from DD::Image::Iop.
References DD::Image::Matrix4::array(), and DD::Image::Iop::set_texturemap().
©2024 The Foundry Visionmongers, Ltd. All Rights Reserved. |