TuttleOFX  1
tuttle::host::INode Class Reference

#include <INode.hpp>

Inheritance diagram for tuttle::host::INode:
Collaboration diagram for tuttle::host::INode:

Public Types

enum  ENodeType {
  eNodeTypeUnknown, eNodeTypeImageEffect, eNodeTypeParam, eNodeTypeGraph,
  eNodeTypeBuffer
}
typedef INode This
typedef std::set< OfxTime > TimesSet
typedef std::map< std::string,
TimesSet
ClipTimesSetMap
typedef graph::ProcessVertexData Data
typedef
graph::ProcessVertexAtTimeData 
DataAtTime
typedef std::map< OfxTime,
DataAtTime * > 
DataAtTimeMap

Public Member Functions

 INode ()
 INode (const INode &e)
virtual ~INode ()
virtual INodeclone () const =0
virtual bool operator== (const INode &) const =0
virtual const std::string & getName () const =0
virtual void setName (const std::string &name)=0
virtual const ENodeType getNodeType () const =0
ImageEffectNodeasImageEffectNode ()
const ImageEffectNodeasImageEffectNode () const
virtual std::vector< int > getVersion () const =0
std::string getVersionStr () const
virtual std::string getLabel () const =0
virtual const
ofx::property::OfxhSet
getProperties () const =0
virtual ofx::property::OfxhSetgetEditableProperties ()=0
virtual attribute::AttributegetAttribute (const std::string &name)=0
const attribute::AttributegetAttribute (const std::string &name) const
virtual attribute::AttributegetSingleInputAttribute ()=0
virtual const
attribute::Attribute
getSingleInputAttribute () const =0
virtual std::size_t getNbParams () const =0
virtual const
ofx::attribute::OfxhParam
getParam (const std::string &name) const =0
virtual ofx::attribute::OfxhParamgetParam (const std::string &name)=0
virtual const
ofx::attribute::OfxhParam
getParamByScriptName (const std::string &name, const bool acceptPartialName=false) const =0
virtual ofx::attribute::OfxhParamgetParamByScriptName (const std::string &name, const bool acceptPartialName=false)=0
virtual const
ofx::attribute::OfxhParam
getParam (const std::size_t index) const =0
virtual ofx::attribute::OfxhParamgetParam (const std::size_t index)=0
virtual attribute::ClipImagegetClip (const std::string &name, const bool acceptPartialName=false)=0
virtual const
attribute::ClipImage
getClip (const std::string &name, const bool acceptPartialName=false) const =0
attribute::ClipImagegetOutputClip ()
const attribute::ClipImagegetOutputClip () const
virtual
ofx::attribute::OfxhParamSet
getParamSet ()=0
virtual const
ofx::attribute::OfxhParamSet
getParamSet () const =0
virtual
ofx::attribute::OfxhClipImageSet
getClipImageSet ()=0
virtual const
ofx::attribute::OfxhClipImageSet
getClipImageSet () const =0
virtual std::size_t getLocalHashAtTime (const OfxTime time) const =0
virtual void connect (const INode &, attribute::Attribute &)=0
virtual void setup1 ()=0
virtual void setup2_reverse ()=0
virtual void setup3 ()=0
virtual OfxRangeD computeTimeDomain ()=0
virtual OfxRangeD getTimeDomain () const =0
virtual void beginSequence (graph::ProcessVertexData &processData)=0
 Begin of the a new frame range to process. Initilize this node.
virtual ClipTimesSetMap getTimesNeeded (const OfxTime time) const =0
 Asks the plugin all times it needs for each of it's input clips.
virtual void preProcess1 (graph::ProcessVertexAtTimeData &processData)
 Initialization pass to propagate informations from inputs to outputs.
virtual void preProcess2_reverse (graph::ProcessVertexAtTimeData &processData)
 Initialization pass to propagate informations from outputs to inputs.
virtual bool isIdentity (const graph::ProcessVertexAtTimeData &processData, std::string &clip, OfxTime &time) const =0
 The node can declare to be an identity operation. In this case, the node is not processed and the rendering engine direcly use the indicated input clip at a particular time.
virtual void preProcess_infos (const graph::ProcessVertexAtTimeData &processData, const OfxTime time, graph::ProcessVertexAtTimeInfo &nodeInfos) const =0
 Fill ProcessInfo to compute statistics for the current process, like memory used by this node, by all input nodes, etc.
virtual void process (graph::ProcessVertexAtTimeData &processData)=0
 Process this node. All inputs are compute.
virtual void postProcess (graph::ProcessVertexAtTimeData &processData)=0
 The process of all nodes is done for one frame, now finalize this node.
virtual void endSequence (graph::ProcessVertexData &processData)=0
 End of the whole frame range process, now finalize this node.
void setBeforeRenderCallback (Callback *cb)
virtual std::ostream & print (std::ostream &os) const =0
void beforeRenderCallback (INode &, DataAtTime &)
void setProcessData (Data *data)
void setProcessDataAtTime (DataAtTime *dataAtTime)
void clearProcessDataAtTime ()
DatagetData ()
const DatagetData () const
bool hasData (const OfxTime time) const
const DataAtTimegetData (const OfxTime time) const
const DataAtTimegetFirstData () const
const DataAtTimegetLastData () const
DataAtTimegetData (const OfxTime time)
DataAtTimegetFirstData ()
DataAtTimegetLastData ()

Data Fields

Callback_beforeRenderCallback

Protected Attributes

Data_data
 link to external datas
DataAtTimeMap _dataAtTime
 link to external datas at each time

Friends

std::ostream & operator<< (std::ostream &os, const This &v)

Detailed Description

Definition at line 47 of file INode.hpp.


Member Typedef Documentation

typedef std::map<std::string, TimesSet> tuttle::host::INode::ClipTimesSetMap

Definition at line 53 of file INode.hpp.

Definition at line 217 of file INode.hpp.

typedef std::map<OfxTime,DataAtTime*> tuttle::host::INode::DataAtTimeMap

Definition at line 219 of file INode.hpp.

Reimplemented in tuttle::host::ImageEffectNode.

Definition at line 50 of file INode.hpp.

typedef std::set<OfxTime> tuttle::host::INode::TimesSet

Definition at line 52 of file INode.hpp.


Member Enumeration Documentation

Enumerator:
eNodeTypeUnknown 
eNodeTypeImageEffect 
eNodeTypeParam 
eNodeTypeGraph 
eNodeTypeBuffer 

Definition at line 55 of file INode.hpp.


Constructor & Destructor Documentation

tuttle::host::INode::INode ( ) [inline]

Definition at line 65 of file INode.hpp.

tuttle::host::INode::INode ( const INode e) [inline]

Definition at line 69 of file INode.hpp.

tuttle::host::INode::~INode ( ) [virtual]

Definition at line 15 of file INode.cpp.


Member Function Documentation

const ImageEffectNode & tuttle::host::INode::asImageEffectNode ( ) const

Definition at line 22 of file INode.cpp.

void tuttle::host::INode::beforeRenderCallback ( INode node,
DataAtTime data 
)

Definition at line 59 of file INode.cpp.

References _beforeRenderCallback, tuttle::host::graph::ProcessVertexAtTimeData::_time, and tuttle::host::Callback::call().

Here is the call graph for this function:

virtual void tuttle::host::INode::beginSequence ( graph::ProcessVertexData processData) [pure virtual]

Begin of the a new frame range to process. Initilize this node.

Parameters:
[in]processData
Remarks:
called on each node without predefined order.

Implemented in tuttle::host::ImageEffectNode.

void tuttle::host::INode::clearProcessDataAtTime ( )

Definition at line 49 of file INode.cpp.

References _dataAtTime.

Referenced by tuttle::host::graph::ProcessGraph::processAtTime().

virtual INode* tuttle::host::INode::clone ( ) const [pure virtual]
virtual OfxRangeD tuttle::host::INode::computeTimeDomain ( ) [pure virtual]
virtual void tuttle::host::INode::connect ( const INode ,
attribute::Attribute  
) [pure virtual]
virtual void tuttle::host::INode::endSequence ( graph::ProcessVertexData processData) [pure virtual]

End of the whole frame range process, now finalize this node.

Parameters:
[in]processData
Remarks:
called on each node without predefined order.

Implemented in tuttle::host::ImageEffectNode.

virtual attribute::Attribute& tuttle::host::INode::getAttribute ( const std::string &  name) [pure virtual]
const attribute::Attribute& tuttle::host::INode::getAttribute ( const std::string &  name) const [inline]

Definition at line 94 of file INode.hpp.

References getAttribute().

Referenced by getAttribute().

Here is the call graph for this function:

virtual attribute::ClipImage& tuttle::host::INode::getClip ( const std::string &  name,
const bool  acceptPartialName = false 
) [pure virtual]
virtual const attribute::ClipImage& tuttle::host::INode::getClip ( const std::string &  name,
const bool  acceptPartialName = false 
) const [pure virtual]
virtual ofx::attribute::OfxhClipImageSet& tuttle::host::INode::getClipImageSet ( ) [pure virtual]
virtual const ofx::attribute::OfxhClipImageSet& tuttle::host::INode::getClipImageSet ( ) const [pure virtual]
const INode::Data & tuttle::host::INode::getData ( ) const

Definition at line 78 of file INode.cpp.

References _data, and getName().

Here is the call graph for this function:

const INode::DataAtTime & tuttle::host::INode::getData ( const OfxTime  time) const

Definition at line 95 of file INode.cpp.

References _dataAtTime, and getName().

Here is the call graph for this function:

INode::DataAtTime & tuttle::host::INode::getData ( const OfxTime  time)

Definition at line 117 of file INode.cpp.

References getData().

Here is the call graph for this function:

virtual ofx::property::OfxhSet& tuttle::host::INode::getEditableProperties ( ) [pure virtual]
const INode::DataAtTime & tuttle::host::INode::getFirstData ( ) const

Definition at line 122 of file INode.cpp.

References _dataAtTime, and getName().

Referenced by getFirstData().

Here is the call graph for this function:

INode::DataAtTime & tuttle::host::INode::getFirstData ( )

Definition at line 134 of file INode.cpp.

References getFirstData().

Here is the call graph for this function:

virtual std::string tuttle::host::INode::getLabel ( ) const [pure virtual]
const INode::DataAtTime & tuttle::host::INode::getLastData ( ) const

Definition at line 139 of file INode.cpp.

References _dataAtTime, and getName().

Referenced by getLastData(), tuttle::host::ImageEffectNode::getProjectExtent(), and tuttle::host::ImageEffectNode::getProjectSize().

Here is the call graph for this function:

INode::DataAtTime & tuttle::host::INode::getLastData ( )

Definition at line 151 of file INode.cpp.

References getLastData().

Here is the call graph for this function:

virtual std::size_t tuttle::host::INode::getLocalHashAtTime ( const OfxTime  time) const [pure virtual]
virtual std::size_t tuttle::host::INode::getNbParams ( ) const [pure virtual]
attribute::ClipImage& tuttle::host::INode::getOutputClip ( ) [inline]

Reimplemented in tuttle::host::ImageEffectNode.

Definition at line 109 of file INode.hpp.

References getClip().

Here is the call graph for this function:

const attribute::ClipImage& tuttle::host::INode::getOutputClip ( ) const [inline]

Reimplemented in tuttle::host::ImageEffectNode.

Definition at line 110 of file INode.hpp.

References getClip().

Here is the call graph for this function:

virtual const ofx::attribute::OfxhParam& tuttle::host::INode::getParam ( const std::string &  name) const [pure virtual]
virtual ofx::attribute::OfxhParam& tuttle::host::INode::getParam ( const std::string &  name) [pure virtual]
virtual const ofx::attribute::OfxhParam& tuttle::host::INode::getParam ( const std::size_t  index) const [pure virtual]
virtual ofx::attribute::OfxhParam& tuttle::host::INode::getParam ( const std::size_t  index) [pure virtual]
virtual const ofx::attribute::OfxhParam& tuttle::host::INode::getParamByScriptName ( const std::string &  name,
const bool  acceptPartialName = false 
) const [pure virtual]
virtual ofx::attribute::OfxhParam& tuttle::host::INode::getParamByScriptName ( const std::string &  name,
const bool  acceptPartialName = false 
) [pure virtual]
virtual ofx::attribute::OfxhParamSet& tuttle::host::INode::getParamSet ( ) [pure virtual]
virtual const ofx::attribute::OfxhParamSet& tuttle::host::INode::getParamSet ( ) const [pure virtual]
virtual const ofx::property::OfxhSet& tuttle::host::INode::getProperties ( ) const [pure virtual]
virtual attribute::Attribute& tuttle::host::INode::getSingleInputAttribute ( ) [pure virtual]
virtual const attribute::Attribute& tuttle::host::INode::getSingleInputAttribute ( ) const [pure virtual]
virtual OfxRangeD tuttle::host::INode::getTimeDomain ( ) const [pure virtual]
virtual ClipTimesSetMap tuttle::host::INode::getTimesNeeded ( const OfxTime  time) const [pure virtual]

Asks the plugin all times it needs for each of it's input clips.

Parameters:
[in]time

Implemented in tuttle::host::ImageEffectNode.

virtual std::vector<int> tuttle::host::INode::getVersion ( ) const [pure virtual]

Implemented in tuttle::host::ImageEffectNode.

Referenced by getVersionStr().

std::string tuttle::host::INode::getVersionStr ( ) const

Definition at line 27 of file INode.cpp.

References getVersion().

Here is the call graph for this function:

bool tuttle::host::INode::hasData ( const OfxTime  time) const

Definition at line 89 of file INode.cpp.

References _dataAtTime.

virtual bool tuttle::host::INode::isIdentity ( const graph::ProcessVertexAtTimeData processData,
std::string &  clip,
OfxTime &  time 
) const [pure virtual]

The node can declare to be an identity operation. In this case, the node is not processed and the rendering engine direcly use the indicated input clip at a particular time.

Parameters:
[in]processData
[out]clipthe input clip to use as identity
[out]timethe time to use as identity
Returns:
if the node is an identity operation

Implemented in tuttle::host::ImageEffectNode.

virtual bool tuttle::host::INode::operator== ( const INode ) const [pure virtual]
virtual void tuttle::host::INode::postProcess ( graph::ProcessVertexAtTimeData processData) [pure virtual]

The process of all nodes is done for one frame, now finalize this node.

Parameters:
[in]processData
Remarks:
Called on each node in a depth first search order. So you have the guarantee that it has been called on each input nodes before.

Implemented in tuttle::host::ImageEffectNode.

virtual void tuttle::host::INode::preProcess1 ( graph::ProcessVertexAtTimeData processData) [inline, virtual]

Initialization pass to propagate informations from inputs to outputs.

Parameters:
[in]processData
Remarks:
Called on each node in a depth first search order. So you have the guarantee that it has been called on each input nodes before.

Reimplemented in tuttle::host::ImageEffectNode.

Definition at line 153 of file INode.hpp.

virtual void tuttle::host::INode::preProcess2_reverse ( graph::ProcessVertexAtTimeData processData) [inline, virtual]

Initialization pass to propagate informations from outputs to inputs.

Parameters:
[in]processData
Remarks:
Called on each node in a REVERSE depth first search order. So you have the guarantee that it has been called on each output nodes before. Output nodes are those who used the result of the current node.

Reimplemented in tuttle::host::ImageEffectNode.

Definition at line 160 of file INode.hpp.

virtual void tuttle::host::INode::preProcess_infos ( const graph::ProcessVertexAtTimeData processData,
const OfxTime  time,
graph::ProcessVertexAtTimeInfo nodeInfos 
) const [pure virtual]

Fill ProcessInfo to compute statistics for the current process, like memory used by this node, by all input nodes, etc.

Parameters:
[in]processData
Remarks:
Called on each node in a depth first search order. So you have the guarantee that it has been called on each input nodes before.

Implemented in tuttle::host::ImageEffectNode.

virtual std::ostream& tuttle::host::INode::print ( std::ostream &  os) const [pure virtual]
virtual void tuttle::host::INode::process ( graph::ProcessVertexAtTimeData processData) [pure virtual]

Process this node. All inputs are compute.

Parameters:
[in]processData
Remarks:
Called on each node in a depth first search order. So you have the guarantee that it has been called on each input nodes before.

Implemented in tuttle::host::ImageEffectNode.

void tuttle::host::INode::setBeforeRenderCallback ( Callback cb)

Callback triggered before the render. The Node does not own the callback so the client has to set the callback to null and destroy it.

Definition at line 54 of file INode.cpp.

References _beforeRenderCallback.

virtual void tuttle::host::INode::setName ( const std::string &  name) [pure virtual]
void tuttle::host::INode::setProcessData ( Data data)

Definition at line 38 of file INode.cpp.

References _data.

Referenced by tuttle::host::graph::ProcessGraph::setup().

void tuttle::host::INode::setProcessDataAtTime ( DataAtTime dataAtTime)

Definition at line 43 of file INode.cpp.

References _dataAtTime, tuttle::host::graph::ProcessVertexAtTimeData::_time, getName(), TUTTLE_TLOG, and TUTTLE_TRACE.

Referenced by tuttle::host::graph::ProcessGraph::setupAtTime().

Here is the call graph for this function:

virtual void tuttle::host::INode::setup1 ( ) [pure virtual]
virtual void tuttle::host::INode::setup2_reverse ( ) [pure virtual]
virtual void tuttle::host::INode::setup3 ( ) [pure virtual]

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const This v 
) [friend]

Definition at line 156 of file INode.cpp.


Field Documentation

link to external datas

Definition at line 226 of file INode.hpp.

Referenced by getData(), and setProcessData().


The documentation for this class was generated from the following files: