13 #ifndef __SOP_Compiled_h__
14 #define __SOP_Compiled_h__
40 : myCookNode(cooknode)
59 myTimeDependent =
false;
64 myDependsOnExprInputs =
true;
71 delete myNodeParmsOrig;
103 , myUnloadMode(unloadmode)
107 , myForbiddenNodes(forbiddennodes)
108 , myRecyclingBin(recyclingbin)
126 return myRecyclingBin->entries() > 0;
131 if (!hasRecycleableGdp())
137 result = myRecyclingBin->last();
138 myRecyclingBin->removeLast();
142 myRecycledGdpShareCount.append(result.
getRefCount());
156 if (gdh.
getRefCount() != myRecycledGdpShareCount(idx))
181 void setInput(
int inputidx,
Task *input);
182 void setExprInput(
int inputidx,
Task *input);
183 void appendOutput(
Task *output);
187 virtual bool validate();
197 virtual void clearNodeTimeDependencies();
210 state(myStateId).myGdh = gdh;
211 state(myStateId).myCECache = cecache;
216 delete state(myStateId).myDelayedCook;
217 state(myStateId).myDelayedCook =
new DelayedCook(cooknode, context);
222 state(myStateId).myLocked =
true;
226 return state(myStateId).myLocked;
232 state(myStateId).myDirty =
true;
233 state(myStateId).myUseCount = 0;
257 void dump(std::ostream &os)
const;
287 bool isTopologyDirty(
const OP_Context &context);
289 bool isTopologyTimeDependent()
const;
291 void dump(std::ostream &os)
const;
303 exint getNumRoots()
const;
306 bool isCompiled()
const;
350 static bool canBeCompiled(
const OP_Node *node);
DelayedCook(SOP_Node *cooknode, const OP_Context &context)
UT_Array< Task * > myTaskInputs
const UT_Array< Task * > & roots() const
void lock(TaskStateArray &state)
bool isValid() const
Determine if this is a valid handle (!isNull())
DEP_MicroNode * depnode() const
DEP_MicroNode * myDepNode
bool isGdpIdRecycled(const GU_DetailHandle &gdh) const
const UT_Array< Task * > & outputs() const
UT_Array< Task * > myOutputs
UT_Array< TaskState > TaskStateArray
bool myDependsOnExprInputs
const GU_Detail * gdp() const
**But if you need a result
GU_DetailHandle allocGdp(bool clear=true) const
UT_ExintArray myRecycledGdpShareCount
UT_Array< GU_DetailHandle > * myRecyclingBin
bool isDirty(const TaskStateArray &state) const
const UT_Array< Task * > & tasks() const
bool hasCECache(const TaskStateArray &state) const
UT_Array< Task * > myRoots
const OP_Context & context() const
const OP_GraphProxy * graph() const
void allocateAndSet(GU_Detail *gdp, bool own=true)
const UT_Array< Task * > & inputs() const
UT_Array< GU_DetailHandle > myRecyclingBin
bool hasRecycleableGdp() const
UnloadMode unloadMode() const
int getRefCount() const
Returns the number of references made to the base handle.
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
SOP_NodeCache * myNodeCache
UT_ErrorManager & myErrors
OP_GraphProxy::NodeIdx myNodeIdx
OP_Node * getNode() const
void dirtyParms(TaskStateArray &state)
UT_Array< OP_GraphProxy::NodeIdx > myNodeInputIds
GU_DetailHandle getDetailHandle(const TaskStateArray &state)
SOP_NodeParms * myNodeParms
SOP_NodeVerb::ForbiddenNodeMap * myNodeSet
void clearDependsOnExprInputs(TaskStateArray &state)
void setTimeDependent(TaskStateArray &state, bool timedep)
void setDetailHandle(TaskStateArray &state, GU_DetailHandle gdh, bool cecache)
virtual void dumpSubclass(std::ostream &os) const
UT_Array< Task * > myInputs
TaskStateArray & state() const
SOP_NodeParms * myNodeParmsOrig
const UT_Array< Task * > & exprInputs() const
void dirty(TaskStateArray &state)
DelayedCook * myDelayedCook
exint getUniqueId() const
UT_Array< Task * > myTasks
void markClean(TaskStateArray &state)
UT_ErrorManager & errors() const
DEP_TimedMicroNode myTopoMicroNode
static GU_Detail * prepNewDetail(GU_Detail *gdp)
SOP_NodeVerb::ForbiddenNodeMap & forbiddenNodes() const
bool isLocked(TaskStateArray &state) const
void setDependsOnExprInputs(TaskStateArray &state)
UT_ExintArray myRecycledGdpId
exint taskInputCount() const
const UT_Array< Task * > & taskInputs() const
ExecuteParms(TaskStateArray &state, UnloadMode unloadmode, const OP_Context &context, UT_ErrorManager &errors, DEP_MicroNode *depnode, SOP_NodeVerb::ForbiddenNodeMap &forbiddennodes, UT_Array< GU_DetailHandle > *recyclingbin)
void markParmsClean(TaskStateArray &state)
OP_GraphProxy::NodeIdx getNodeIdx() const
A global error manager scope.
void setDelayedCook(TaskStateArray &state, SOP_Node *cooknode, const OP_Context &context)
const OP_Context & myContext
OP_GraphProxy::NodeIdx nodeIdx() const
SOP_NodeVerb::ForbiddenNodeMap & myForbiddenNodes
const OP_GraphProxy * myGraph
bool isParmsDirty(const TaskStateArray &state) const
bool dependsOnExprInputs(const TaskStateArray &state) const
UT_SharedPtr< const OP_GraphProxy > myGraphProxy
UT_Array< Task * > myExprInputs
bool getTimeDependent(const TaskStateArray &state) const
virtual OP_Node * idxToNode(NodeIdx idx) const =0