#include <VOP_Node.h>

Public Member Functions | |
| virtual const char * | getChildType () const |
| virtual const char * | getOpType () const |
| virtual OP_OpTypeId | getChildTypeID () const |
| virtual OP_OpTypeId | getOpTypeID () const |
| virtual OP_DATA_TYPE | getCookedDataType () const |
| Nobody should have to override this, but it's public for other people. | |
| virtual void | opChanged (OP_EventType reason, void *data=0) |
| virtual void | referencedParmChanged (int pi) |
| virtual void | getParameterBlock (UT_String &parmstr) |
| virtual void | getParameterDeclaration (UT_String &parmdecl, const VOP_Language *language, const VOP_ContextType *type) |
| virtual void | getPragmas (UT_String &pragmastr, VOP_ContextType context_type) |
| virtual void | getOuterCode (UT_String &codestr) |
| virtual void | getCode (UT_String &codestr, VOP_CodeVarMapperContext *context=NULL) |
| virtual bool | getParmConstantString (const char *parmname, VOP_Type type, UT_String &str, bool expand_string, const VOP_Language *l=0) |
| virtual bool | getIsParmGenerator () const |
| Returns true if this VOP is a VOP_ParmGenerator or subclass. | |
| virtual bool | getExportParm (VOP_ContextType context_type, UT_String &varname) |
| virtual void | initializeNode () |
| virtual void | ensureParametersAreValid () |
| void | getOutputName (UT_String &out, int idx) const |
| int | getOutputFromName (const UT_String &out) const |
| VOP_Type | getOutputType (int idx) |
| void | getInputName (UT_String &in, int idx) const |
| int | getInputFromName (const UT_String &in) const |
| VOP_Type | getInputType (int idx) |
| virtual bool | getIsVisible (int idx) |
| virtual void | getAllowedInputTypes (unsigned idx, VOP_VopTypeArray &voptypes) |
| virtual bool | areOutputVariablesFixed (VOP_ContextType context_type) |
| virtual void | getOutputVariable (UT_String &var, int idx) |
| void | mergeInputNodeList (VOP_NodeList &nodes, TMergeNodeInfos &merge_infos) |
| virtual bool | forceCodeGenerationOfInputs (VOP_ContextType context_type, bool essential) const |
| virtual bool | getIsEncapsulatedShader () const |
| virtual void | updateEncapsulatedParameters (const VOP_CodeParmList &parms) |
| Update the parameters for the encapsulated shader. | |
| virtual bool | getEncapsulatedShaderName (UT_WorkBuffer &name) const |
| virtual bool | getEncapsulatedShaderPath (UT_WorkBuffer &name) const |
| Get the "op:" shader name (used when building shader strings). | |
| virtual bool | getIsScriptedShader () |
| virtual bool | getScriptedShaderName (UT_WorkBuffer &name) |
| Get the shader name. | |
| const UT_SymbolTable * | getGlobalVariables () const |
| const UT_SymbolTable * | getLocalVariables () const |
| const UT_SymbolTable * | getLocalChannels () const |
| void | setTables (const UT_SymbolTable *globals, UT_SymbolTable *locals, UT_SymbolTable *channels) |
| void | setTablesFromVop (VOP_Node *vop) |
| void | addLocalVariable (const char *varname, VOP_ParmGenerator *definer) |
| void | deleteLocalVariable (const char *varname) |
| void | getSortedGlobalVariableList (VOP_GlobalVarList &vars, VOP_ContextType type, bool mustBeReadable, bool mustBeWritable) |
| virtual void | setExtraFlag (char flag, int onoff) |
| int | setInOutLOD (int level, int inoff) |
| int | getInOutLOD (int level) const |
| virtual OP_ERROR | setInput (unsigned idx, OP_Node *op, unsigned outputIdx=0) |
| virtual OP_ERROR | setInputReference (unsigned idx, const char *label, int keeppos, unsigned outputIdx=0) |
| Connects an input to particular node by name in the network. | |
| virtual void | moveInput (int srcidx, int dstidx, bool forcesubnet=false) |
| virtual bool | isConnected (int inputidx, bool recursive) |
| virtual VOP_OutputNameEditorSource * | getOutputNameEditorSource () |
| Returns a pointer used by OPUI_OutputNameEditor to get and set data. | |
| VOP_Node * | getSubnetOutputNode () const |
| Used by subnet type operators which must always have an output node. | |
| VOP_Node * | insertParmGenerator (int inputidx, bool makeparmnode) |
| VOP_Node * | insertNode (int inputidx, const char *nodetype, bool connect_to_input, const char *undo_string=NULL) |
| virtual VOP_ParmGenerator * | getInsertParmGeneratorSource (int inputidx) |
| void | insertParmGeneratorsForAllInputs (bool makeparmnodes) |
| virtual void | getParmNameFromInput (UT_String &parmname, int inputidx) const |
| bool | outputDefaultParmDefinition (ostream &os, int idx) |
| virtual void | saveDialogScriptExtraInfo (ostream &os) |
| bool | saveParmValues (ostream &os) |
| Saves the parameter values to the output stream. | |
| bool | loadParmValues (UT_IStream &is) |
| Loads the parameter values to the output stream. | |
| virtual VOP_Node * | getRealDefinition () |
| const VOP_Language * | getLanguage () const |
| virtual fpreal | getW () const |
| Absolute width. | |
| virtual fpreal | getH () const |
| Absolute height. | |
| virtual fpreal | getYOffset () const |
| virtual void | clearInterrupted () |
| void | getDisplayedButtonCount (bool input_flag, int &count, bool &ellipsis) const |
| virtual bool | willAutoconvertInputType (int input_idx) |
| Returns true if the input will be auto-converetd, false otherwise. | |
| VOP_Type | getAutoConvertTargetType (int input_idx) |
| VOP_Type | getAutoConvertTypeFromType (int input_idx, VOP_Type source_type) |
| void | addAutoConvertNodePointer (VOP_AutoConvert *ac_node, int input_index) |
| Do not call this method directly. | |
| void | clearAutoConvertInfos (void) |
| VOP_AutoConvert * | getAutoConvertNode (int input_idx) |
| int | getNumAutoConvertNodes (void) |
| VOP_OutputInfoManager * | getOutputInfoManager (void) |
| void | appendOutputOverrideCode (UT_String &str_code) |
| bool | needToExecute (void) |
| void | onNodeChange (OP_EventType type) |
| Do not call this method directly. | |
| virtual OP_ERROR | save (ostream &os, const OP_SaveFlags &flags, const char *path_prefix="") |
| virtual bool | load (UT_IStream &is, const char *ext="", const char *path=0) |
| virtual bool | allowReservingParm (PRM_Parm *parm) |
| virtual int | getDebug () const |
| Gets the value of the debug flag on this node. | |
| virtual int | setDebug (int on_off) |
| Sets the value of the debug flag on this node. | |
| void | getSubOutputAndSubInputs (OP_Node *&outputnode, OP_NodeList &inputnodes) const |
| void | hideInput (int input_index, bool hide) |
| void | setReferenceTargetDefaults (int input_index, bool do_set) |
| bool | getAllowEditingParmDefaults (int input_index) |
| VEX_ContextType | getVexContextType () const |
| RSL_ContextType | getRslContextType () const |
| bool | isSingleContextType () const |
| VOP_ContextType | getShaderContextType () const |
| bool | acceptsTypeForCodeGeneration (VOP_ContextType t) const |
| virtual bool | providesShaderCode () |
| VOP_Node * | verifyProcedural (VOP_Type type) |
| virtual void | getFixedParameterMap (UT_StringArray &parmmap) |
| virtual void | getShaderInputMap (UT_StringArray &inputmap) |
| virtual const PRM_Template * | getShaderParmTemplates () |
| Obtains the template array for shader parameters. | |
| bool | deleteIndependentInputNodes (int input_index) |
| void | getInputsRecursive (OP_NodeList &nodes_out) |
| bool | doesDependOnlyOn (VOP_Node *other_node, int max_connections, bool recurse) |
| void | getParmInputs (VOP_ParmGeneratorList &parm_vops) |
| VOP_Node * | findSimpleInput (int index) |
| virtual VOP_Node * | findSimpleInputFromOutput (int output_index) |
| virtual void | findSimpleInputCandidatesFromOutput (int output_index, UT_IntArray &input_indices) |
| bool | isExternalShader () |
| virtual bool | runCreateScript () |
| void | updateInputFlagsFromOperator (VOP_OperatorInfo *type_info, bool keep_visible) |
| void | setDisableAutoInputDelete (bool value) |
Static Public Member Functions | |
| static void | buildOperatorTable (OP_OperatorTable &table) |
| static void | incrementVariableName (UT_String &varname) |
| static void | deleteAutoConvertNodesIn (VOP_NodeList &nodes) |
| static int & | getLODPref () |
| static void | setLODPref (int value) |
| static void | cacheAllParmNames (OP_Node *root) |
| Calls cacheParmName on all VOP_ParmGenerator nodes under root. | |
| static void | recalculateAllParmDefiners (OP_Node *root) |
| Calls recalculateParmDefiner on all VOP_ParmGenerator nodes under root. | |
Protected Member Functions | |
| VOP_Node (OP_Network *parent, const char *name, OP_Operator *entry) | |
| virtual | ~VOP_Node () |
| virtual void | getNodeSpecificInfoText (OP_Context &context, int verbose, UT_WorkBuffer &text) |
| virtual void | deleteCookedData () |
| virtual int | saveCookedData (ostream &, OP_Context &, int binary=0) |
| virtual int | saveCookedData (const char *, OP_Context &) |
| virtual const char * | getFileExtension (int) const |
| virtual OP_ERROR | cookMe (OP_Context &) |
| virtual OP_ERROR | bypassMe (OP_Context &, int &) |
| virtual void | preOpChanged (OP_EventType, void *) |
| virtual void | postOpChanged (OP_EventType, void *) |
| virtual VOP_ContextType | getSpecificShaderContextType () const |
| virtual void | getTypesForCodeGeneration (VOP_ContextTypeList &types) const |
| virtual void | getOutputNameSubclass (UT_String &out, int idx) const |
| virtual VOP_Type | getOutputTypeSubclass (int idx) |
| virtual void | getInputNameSubclass (UT_String &in, int idx) const |
| virtual int | getInputFromNameSubclass (const UT_String &in) const |
| virtual VOP_Type | getInputTypeSubclass (int idx) |
| virtual bool | getIsVisibleSubclass (int idx) |
| virtual void | getAllowedInputTypesSubclass (unsigned idx, VOP_VopTypeArray &voptypes) |
| virtual bool | getRequiresInputParameters () const |
| void | addError (VOP_ErrorCodes code, const char *msg=0) |
| void | addMessage (VOP_ErrorCodes code, const char *msg=0) |
| void | addWarning (VOP_ErrorCodes code, const char *msg=0) |
| void | addFatal (VOP_ErrorCodes code, const char *msg=0) |
| virtual void | getAdditionalUndoNodes (const OP_NodeList &orig_list, OP_NodeList &nodes_for_input_undo) |
| virtual OP_ERROR | saveIntrinsic (ostream &os, const OP_SaveFlags &flags) |
| Save and load VOP version numbers. | |
| virtual bool | loadPacket (UT_IStream &is, short class_id, short sig, const char *path=0) |
| virtual bool | loadPacket (UT_IStream &is, const char *token, const char *path=0) |
| virtual int | getLatestVopVersion () const |
| void | getInputsRecursiveHelper (OP_NodeList &nodes_out, UT_RefArray< int > &array) |
| bool | doesDependOnlyOnHelper (VOP_Node *other_node, int max_connections, bool recurse, UT_RefArray< int > &array) |
| virtual void | onInputAllocated (OP_Input *new_input, int index) |
| Overriden in VOPs. | |
| virtual void | finishedLoadingNetwork (bool is_child_call=false) |
Static Protected Member Functions | |
| static void | rewireInputs (OP_Network *parent, OP_NodeList &inputs, int srcidx, int dstidx) |
| This function is used to rewire nodes when we do a moveInput. | |
Protected Attributes | |
| const VOP_Language * | myLanguage |
| int | myVopVersion |
VOP/VOP_CustomContext.C, VOP/VOP_CustomContext.h, VOP/VOP_Switch.C, and VOP/VOP_Switch.h.
Definition at line 137 of file VOP_Node.h.
| VOP_Node::VOP_Node | ( | OP_Network * | parent, | |
| const char * | name, | |||
| OP_Operator * | entry | |||
| ) | [protected] |
| virtual VOP_Node::~VOP_Node | ( | ) | [protected, virtual] |
| bool VOP_Node::acceptsTypeForCodeGeneration | ( | VOP_ContextType | t | ) | const |
Returns true if the node can generate code in the given context. For nodes in a single-context vopnet it returns true if the given type is exactly the same as specified by the parent vopnet. For multi-context vopnets, the nodes usually specify the list of accepted types, and this method tests given type against that list.
| void VOP_Node::addAutoConvertNodePointer | ( | VOP_AutoConvert * | ac_node, | |
| int | input_index | |||
| ) |
Do not call this method directly.
| void VOP_Node::addError | ( | VOP_ErrorCodes | code, | |
| const char * | msg = 0 | |||
| ) | [inline, protected] |
Definition at line 630 of file VOP_Node.h.
| void VOP_Node::addFatal | ( | VOP_ErrorCodes | code, | |
| const char * | msg = 0 | |||
| ) | [inline, protected] |
Definition at line 636 of file VOP_Node.h.
| void VOP_Node::addLocalVariable | ( | const char * | varname, | |
| VOP_ParmGenerator * | definer | |||
| ) |
| void VOP_Node::addMessage | ( | VOP_ErrorCodes | code, | |
| const char * | msg = 0 | |||
| ) | [inline, protected] |
Definition at line 632 of file VOP_Node.h.
| void VOP_Node::addWarning | ( | VOP_ErrorCodes | code, | |
| const char * | msg = 0 | |||
| ) | [inline, protected] |
Definition at line 634 of file VOP_Node.h.
| virtual bool VOP_Node::allowReservingParm | ( | PRM_Parm * | parm | ) | [virtual] |
We should not reserve the name of the parameter in PI_EditScriptedParms::initializeReserveNames()if it is one of our inputs. This function implements this behaviour.
Reimplemented from OP_Parameters.
| void VOP_Node::appendOutputOverrideCode | ( | UT_String & | str_code | ) |
Appends code which overrides output values if necessary (uses myOutputInfos below to determine this).
| virtual bool VOP_Node::areOutputVariablesFixed | ( | VOP_ContextType | context_type | ) | [virtual] |
Returns whether or not this op outputs variabls in a given context. If so, the second function returns the name of this output variable.
Reimplemented in VOP_ParmGenerator.
| static void VOP_Node::buildOperatorTable | ( | OP_OperatorTable & | table | ) | [static] |
| virtual OP_ERROR VOP_Node::bypassMe | ( | OP_Context & | , | |
| int & | ||||
| ) | [protected, virtual] |
Implements OP_Node.
| static void VOP_Node::cacheAllParmNames | ( | OP_Node * | root | ) | [static] |
Calls cacheParmName on all VOP_ParmGenerator nodes under root.
| void VOP_Node::clearAutoConvertInfos | ( | void | ) |
| virtual void VOP_Node::clearInterrupted | ( | ) | [virtual] |
Override clearInterrupted so that we don't recook the whole DOP Network when the user interrupts a cook. The clearInterrupted on the containing VOP Network willb be enough.
Reimplemented from OP_Node.
| virtual OP_ERROR VOP_Node::cookMe | ( | OP_Context & | ) | [protected, virtual] |
| static void VOP_Node::deleteAutoConvertNodesIn | ( | VOP_NodeList & | nodes | ) | [static] |
Scans the node list and deletes the auto convert nodes (and replaces them with NULLs in the list). Also, clears any auto-convert information for all other nodes in the list. Note, thet the node list is usually constructed with mergeInputNodeList() method.
| virtual void VOP_Node::deleteCookedData | ( | ) | [protected, virtual] |
Implements OP_Node.
| bool VOP_Node::deleteIndependentInputNodes | ( | int | input_index | ) |
Deletes the input nodes for a given input (recursively), but only if none of them depend on anything other than this node. Returns true if any nodes were deleted, false otherwise.
| void VOP_Node::deleteLocalVariable | ( | const char * | varname | ) |
| bool VOP_Node::doesDependOnlyOn | ( | VOP_Node * | other_node, | |
| int | max_connections, | |||
| bool | recurse | |||
| ) |
| bool VOP_Node::doesDependOnlyOnHelper | ( | VOP_Node * | other_node, | |
| int | max_connections, | |||
| bool | recurse, | |||
| UT_RefArray< int > & | array | |||
| ) | [protected] |
| virtual void VOP_Node::ensureParametersAreValid | ( | ) | [virtual] |
Make sure that our parmname parameter (if we have one) doesn't conflict with any other parmname parameter values.
Reimplemented in VOP_OutputVar, VOP_ScriptNode, and VOP_VariableInput.
| VOP_Node* VOP_Node::findSimpleInput | ( | int | index | ) |
Returns the node wired to this VOP's 'index' input tracing past simple VOPs like the Switch or Null VOP.
| virtual void VOP_Node::findSimpleInputCandidatesFromOutput | ( | int | output_index, | |
| UT_IntArray & | input_indices | |||
| ) | [inline, virtual] |
A method that reports which immediate input connectors are considered by findSimpleInputFromOutput() method. This is useful when analyzing the simple input decision tree.
Reimplemented in VOP_OutputVar.
Definition at line 540 of file VOP_Node.h.
| virtual VOP_Node* VOP_Node::findSimpleInputFromOutput | ( | int | output_index | ) | [inline, virtual] |
Virtual helper to findSimpleInput() which returns the simple input node (ie the final node we look for) based on the request coming from the node connected to on the output of a given index.
Reimplemented in VOP_OutputVar.
Definition at line 535 of file VOP_Node.h.
| virtual void VOP_Node::finishedLoadingNetwork | ( | bool | is_child_call = false |
) | [protected, virtual] |
Reimplemented from OP_Network.
| virtual bool VOP_Node::forceCodeGenerationOfInputs | ( | VOP_ContextType | context_type, | |
| bool | essential | |||
| ) | const [virtual] |
Determines if the code generation should collect code-generating nodes by recursively traversing the input nodes starting from this node. This returns true for nodes such as: output node, output variable, code node, print node, etc, and returns false for nodes such as global variables, add node, etc. The essential flag is used to urge the nodes to report true if they really think they are essential. This was introduced with multi-context vopnets because previously a wide range of nodes would report true (eg, a null, as context-specific subnets) which would then make way into incompatible contexts. The essential flag is meant to weed out all such nodes and only let through output and export variables nodes.
Reimplemented in VOP_OutputVar, VOP_ParmGenerator, VOP_ScriptNode, and VOP_SubnetOutput.
| virtual void VOP_Node::getAdditionalUndoNodes | ( | const OP_NodeList & | orig_list, | |
| OP_NodeList & | nodes_for_input_undo | |||
| ) | [protected, virtual] |
Reimplemented from OP_Network.
| virtual void VOP_Node::getAllowedInputTypes | ( | unsigned | idx, | |
| VOP_VopTypeArray & | voptypes | |||
| ) | [virtual] |
Returns all allowed input types on a given input, regardless of what is currently connected to that input. These do not include types to which autoconversion is possible.
Reimplemented in VOP_ScriptNode.
| virtual void VOP_Node::getAllowedInputTypesSubclass | ( | unsigned | idx, | |
| VOP_VopTypeArray & | voptypes | |||
| ) | [protected, virtual] |
This methods should be overriden in most VOP nodes. It should fill in voptypes vector with vop types that are allowed to be connected to this node at the input at index idx. Note that unlike getInputTypeSubclass(), this method should return valid vop types even when nothing is connected to the corresponding input.
Reimplemented in VOP_OutputVar, VOP_Parameter, VOP_ScriptNode, VOP_SubnetOutput, VOP_VariableInput, HDK_Sample::VOP_CustomVop, and HDK_Sample::VOP_Switch.
| bool VOP_Node::getAllowEditingParmDefaults | ( | int | input_index | ) |
| VOP_AutoConvert* VOP_Node::getAutoConvertNode | ( | int | input_idx | ) |
| VOP_Type VOP_Node::getAutoConvertTargetType | ( | int | input_idx | ) |
Returns the type to which the input will be auto-convert. This is necessary because some inputs can take in a range of various types, and we need to know which one will be converting to. This function assumes that autoconversion is necessary. If it is not possible, or not needed, it returns VOP_TYPE_UNDEF.
Similar to the getAutoConvertTargetType(), but takes in an input type instead of trying to read it from the connected node. This is useful when one needs to know what the incoming type will be converted to before it is actually connected.
| virtual const char* VOP_Node::getChildType | ( | ) | const [virtual] |
Reimplemented from OP_Network.
| virtual OP_OpTypeId VOP_Node::getChildTypeID | ( | ) | const [virtual] |
Implements OP_Network.
| virtual void VOP_Node::getCode | ( | UT_String & | codestr, | |
| VOP_CodeVarMapperContext * | context = NULL | |||
| ) | [virtual] |
Reimplemented in VOP_AutoConvert, VOP_Collect, VOP_OutputVar, VOP_ParmGenerator, VOP_ScriptNode, VOP_SubnetOutput, VOP_VariableInput, and HDK_Sample::VOP_Switch.
| virtual OP_DATA_TYPE VOP_Node::getCookedDataType | ( | ) | const [virtual] |
| virtual int VOP_Node::getDebug | ( | ) | const [virtual] |
| void VOP_Node::getDisplayedButtonCount | ( | bool | input_flag, | |
| int & | count, | |||
| bool & | ellipsis | |||
| ) | const |
Returns EITHER the number of input buttons, or the number of output buttons currently displayed on this VOP, which depends on our level of detail (LOD). Set 'input_flag' to TRUE to count input buttons, false to count output buttons. The value returned does NOT include an ellipsis even if one is displayed. If there is an ellipsis, the parameter 'ellipsis' will instead be set to true (else set to false).
| virtual bool VOP_Node::getEncapsulatedShaderName | ( | UT_WorkBuffer & | name | ) | const [virtual] |
Get a shader name for the encapsulated shader. This shader name can be unique based on the session. For non-encapsulated shaders, this method returns false and leaves the name buffer un-modified.
| virtual bool VOP_Node::getEncapsulatedShaderPath | ( | UT_WorkBuffer & | name | ) | const [virtual] |
Get the "op:" shader name (used when building shader strings).
| virtual bool VOP_Node::getExportParm | ( | VOP_ContextType | context_type, | |
| UT_String & | varname | |||
| ) | [virtual] |
Returns true when this VOP is a VOP_ParmGenerator and it's also an export parameter in a given context type.
| context_type | context type to which the query applies | |
| varname | outgoing parameter that will contain the export parameter name. |
Reimplemented in VOP_ParmGenerator.
| virtual const char* VOP_Node::getFileExtension | ( | int | ) | const [protected, virtual] |
Implements OP_Node.
| virtual void VOP_Node::getFixedParameterMap | ( | UT_StringArray & | parmmap | ) | [virtual] |
Returns a parmmap string array where alternate entries contain key and value, where key is the vop parameter name and the value is the parameter name specified by the Parm VOP connected to the input corresponding to that vop parameter.
| const UT_SymbolTable* VOP_Node::getGlobalVariables | ( | ) | const |
Get or set the table of global or local variables for this context. The global variables are defined solely by the VEX context. The data associated with each entry is the VEX_Type of the variable. The local variables are those defined by Parameter ops. This table provides a common place to look for variable name conflicts.
| int VOP_Node::getInOutLOD | ( | int | level | ) | const |
| int VOP_Node::getInputFromName | ( | const UT_String & | in | ) | const |
| virtual int VOP_Node::getInputFromNameSubclass | ( | const UT_String & | in | ) | const [protected, virtual] |
| void VOP_Node::getInputName | ( | UT_String & | in, | |
| int | idx | |||
| ) | const |
Returns the variable name associated with a given input number. These just call the getInputXXXSubclass functions.
| virtual void VOP_Node::getInputNameSubclass | ( | UT_String & | in, | |
| int | idx | |||
| ) | const [protected, virtual] |
Returns the variable name associated with a given input number. Implementers of this function should also implement the reverse function.
Reimplemented in VOP_AutoConvert, VOP_OutputVar, VOP_ParmGenerator, VOP_Properties, VOP_ScriptNode, VOP_SubnetOutput, VOP_VariableInput, HDK_Sample::VOP_CustomVop, and HDK_Sample::VOP_Switch.
| void VOP_Node::getInputsRecursive | ( | OP_NodeList & | nodes_out | ) |
| void VOP_Node::getInputsRecursiveHelper | ( | OP_NodeList & | nodes_out, | |
| UT_RefArray< int > & | array | |||
| ) | [protected] |
| VOP_Type VOP_Node::getInputType | ( | int | idx | ) |
will_autoconvert_out, if not null, is set to true if autoconversion will be needed, to false otherwise.
| virtual VOP_Type VOP_Node::getInputTypeSubclass | ( | int | idx | ) | [protected, virtual] |
Reimplemented in VOP_AutoConvert, VOP_Collect, VOP_OutputVar, VOP_Parameter, VOP_Properties, VOP_ScriptNode, VOP_SubnetOutput, VOP_VariableInput, HDK_Sample::VOP_CustomVop, and HDK_Sample::VOP_Switch.
| virtual VOP_ParmGenerator* VOP_Node::getInsertParmGeneratorSource | ( | int | inputidx | ) | [virtual] |
When inserting a parameter (i.e. Promote Parameter), the source VOP is allowed to give us a source VOP_ParmGenerator if there's no corresponding parameter found. The source parm generator is used to initialize settings on the new parameter node.
| virtual bool VOP_Node::getIsEncapsulatedShader | ( | ) | const [virtual] |
Check to see if this is a subnetwork which generates an encapsulated shader. For example the SubnetCVEX VOP.
| virtual bool VOP_Node::getIsParmGenerator | ( | ) | const [virtual] |
| virtual bool VOP_Node::getIsScriptedShader | ( | ) | [virtual] |
Check to see if this VOP is a "scripted shader". That is, a VOP which has a shader output, but isn't defined by a VOP network (i.e. it's defined by either pre-compiled VEX code or C++ code for procedurals).
| virtual bool VOP_Node::getIsVisible | ( | int | idx | ) | [virtual] |
Reimplemented from OP_Node.
| virtual bool VOP_Node::getIsVisibleSubclass | ( | int | idx | ) | [protected, virtual] |
Reimplemented in VOP_ScriptNode.
| const VOP_Language* VOP_Node::getLanguage | ( | ) | const [inline] |
Definition at line 366 of file VOP_Node.h.
| virtual int VOP_Node::getLatestVopVersion | ( | ) | const [inline, protected, virtual] |
If a subclass has VOP versioning, it should return a value greater than 0 for the latest version.
Definition at line 656 of file VOP_Node.h.
| const UT_SymbolTable* VOP_Node::getLocalChannels | ( | ) | const |
| const UT_SymbolTable* VOP_Node::getLocalVariables | ( | ) | const |
| static int& VOP_Node::getLODPref | ( | ) | [inline, static] |
Definition at line 295 of file VOP_Node.h.
| virtual void VOP_Node::getNodeSpecificInfoText | ( | OP_Context & | context, | |
| int | verbose, | |||
| UT_WorkBuffer & | text | |||
| ) | [protected, virtual] |
| int VOP_Node::getNumAutoConvertNodes | ( | void | ) |
| virtual const char* VOP_Node::getOpType | ( | ) | const [virtual] |
Implements OP_Node.
| virtual OP_OpTypeId VOP_Node::getOpTypeID | ( | ) | const [virtual] |
This returns the OP_OpTypeId which corresponds to this node type. Management nodes will return the type they really are, which is likely different than the network they currently reside in.
Implements OP_Node.
| virtual void VOP_Node::getOuterCode | ( | UT_String & | codestr | ) | [virtual] |
Reimplemented in VOP_AutoConvert, and VOP_ScriptNode.
| int VOP_Node::getOutputFromName | ( | const UT_String & | out | ) | const |
| VOP_OutputInfoManager* VOP_Node::getOutputInfoManager | ( | void | ) |
Returns the output information manager. The manager is responsible for manipulating VOP_OutputInfo objects for each output. These objects dictate how an output behaves when the node is in debug or bypass mode. See VOP_OutputInfo for more information. Please note that by default, an output info does not exist for any outputs, and is only created when a debug/bypass value is changed.
| void VOP_Node::getOutputName | ( | UT_String & | out, | |
| int | idx | |||
| ) | const |
Functions to get information about our operator outputs. These just call the getOutputXXXSubclass functions.
| virtual VOP_OutputNameEditorSource* VOP_Node::getOutputNameEditorSource | ( | ) | [inline, virtual] |
Returns a pointer used by OPUI_OutputNameEditor to get and set data.
Reimplemented in VOP_SubnetOutput.
Definition at line 319 of file VOP_Node.h.
| virtual void VOP_Node::getOutputNameSubclass | ( | UT_String & | out, | |
| int | idx | |||
| ) | const [protected, virtual] |
Functions to get information about our operator outputs. These functions are used for variable name replacement and for creating output labels on the op tiles.
Reimplemented in VOP_AutoConvert, VOP_OutputVar, VOP_ParmGenerator, VOP_Properties, VOP_ScriptNode, VOP_VariableInput, HDK_Sample::VOP_CustomVop, and HDK_Sample::VOP_Switch.
| VOP_Type VOP_Node::getOutputType | ( | int | idx | ) |
| virtual VOP_Type VOP_Node::getOutputTypeSubclass | ( | int | idx | ) | [protected, virtual] |
Reimplemented in VOP_AutoConvert, VOP_OutputVar, VOP_ParmGenerator, VOP_Properties, VOP_ScriptNode, VOP_VariableInput, HDK_Sample::VOP_CustomVop, and HDK_Sample::VOP_Switch.
| virtual void VOP_Node::getOutputVariable | ( | UT_String & | var, | |
| int | idx | |||
| ) | [virtual] |
Reimplemented in VOP_ParmGenerator.
| virtual void VOP_Node::getParameterBlock | ( | UT_String & | parmstr | ) | [virtual] |
Get the parm block information that will go in the dialog script for our VOPNET.
Reimplemented in VOP_Parameter.
| virtual void VOP_Node::getParameterDeclaration | ( | UT_String & | parmdecl, | |
| const VOP_Language * | language, | |||
| const VOP_ContextType * | type | |||
| ) | [virtual] |
Reimplemented in VOP_Parameter.
| virtual bool VOP_Node::getParmConstantString | ( | const char * | parmname, | |
| VOP_Type | type, | |||
| UT_String & | str, | |||
| bool | expand_string, | |||
| const VOP_Language * | l = 0 | |||
| ) | [virtual] |
Reimplemented in VOP_Parameter, and VOP_ScriptNode.
| void VOP_Node::getParmInputs | ( | VOP_ParmGeneratorList & | parm_vops | ) |
Search through this node's inputs and return a list of parameter VOPs that appear in the input network. Recursively search through subnetworks as well. If this node is a parameter VOP, then add it to the list.
| virtual void VOP_Node::getParmNameFromInput | ( | UT_String & | parmname, | |
| int | inputidx | |||
| ) | const [virtual] |
The following method is needed to obtain the parameter name to be associated with an input. It is possible that the parameter name differs from the input name.
Reimplemented in VOP_ScriptNode.
| virtual void VOP_Node::getPragmas | ( | UT_String & | pragmastr, | |
| VOP_ContextType | context_type | |||
| ) | [virtual] |
Reimplemented in VOP_Parameter.
| virtual VOP_Node* VOP_Node::getRealDefinition | ( | ) | [inline, virtual] |
This virtual is overridden by VOP_ParmGenerator so we can find out which VOP defines the actual parameter attributes.
Reimplemented in VOP_ParmGenerator.
Definition at line 363 of file VOP_Node.h.
| virtual bool VOP_Node::getRequiresInputParameters | ( | ) | const [protected, virtual] |
If the can only accept parameters as inputs, this method should return true. By default, this method checks the operator to see whether the VOP relies on external code (i.e. geometry procedurals)
Reimplemented in VOP_Properties.
| RSL_ContextType VOP_Node::getRslContextType | ( | ) | const |
Determine the VEX context type if the node is single-context type. For nodes in a multi-context vopnet (or for VEX vopnet) returns RSL_INVALID_CONTEXT, because the specific RSL context cannot be reliably and unambiguously determined.
| virtual bool VOP_Node::getScriptedShaderName | ( | UT_WorkBuffer & | name | ) | [virtual] |
Get the shader name.
| VOP_ContextType VOP_Node::getShaderContextType | ( | ) | const |
Gets the context type (VEX_ContextType or RSL_ContextType) to which this node subscribes. In single-type vopnets, it is equal to the node's VEX/RSL context type. In multi-type vopnets, the exact type is variable and usually depends on the node's parameter value.
| virtual void VOP_Node::getShaderInputMap | ( | UT_StringArray & | inputmap | ) | [virtual] |
Returns an input map string array where alternate entries contain key and value, where key is the vop parameter name and the value is the node path specified for that parameter (usually connected into an input corresponding to that vop parameter).
| virtual const PRM_Template* VOP_Node::getShaderParmTemplates | ( | ) | [virtual] |
Obtains the template array for shader parameters.
| void VOP_Node::getSortedGlobalVariableList | ( | VOP_GlobalVarList & | vars, | |
| VOP_ContextType | type, | |||
| bool | mustBeReadable, | |||
| bool | mustBeWritable | |||
| ) |
| virtual VOP_ContextType VOP_Node::getSpecificShaderContextType | ( | ) | const [protected, virtual] |
Gets the shader context type (VEX_ContextType or RSL_ContextType) to which a node belongs to.
This method is meant to be overriden by nodes that can specify a single concrete context type when they are created in a multi-context vopnet. This method is invoked by getShaderContextType() to obtain the concrete type, if possible
In multi-context vopnets, for nodes that explicitly specify a single context (such as an output node, usually determined from the node's parameter), this method returns such explicltly selected context type. For other nodes that don't explicltly choose a context, this method returns an invalid type, meaning such nodes don't have control over a specific type, and they belong to a type specified during code generation.
Reimplemented in VOP_OutputVar.
| VOP_Node* VOP_Node::getSubnetOutputNode | ( | ) | const |
Used by subnet type operators which must always have an output node.
| void VOP_Node::getSubOutputAndSubInputs | ( | OP_Node *& | outputnode, | |
| OP_NodeList & | inputnodes | |||
| ) | const |
| virtual void VOP_Node::getTypesForCodeGeneration | ( | VOP_ContextTypeList & | types | ) | const [protected, virtual] |
Obtains a list of types in which this node wants to initiate the generation of code.
Reimplemented in VOP_ParmGenerator.
| VEX_ContextType VOP_Node::getVexContextType | ( | ) | const |
Determine the VEX context type if the node is single-context type. For nodes in a multi-context vopnet (or for RSL vopnet) returns VEX_INVALID_CONTEXT, because the specific VEX context cannot be reliably and unambiguously determined.
| virtual fpreal VOP_Node::getYOffset | ( | ) | const [virtual] |
Reimplemented from OP_NetworkBoxItem.
| void VOP_Node::hideInput | ( | int | input_index, | |
| bool | hide | |||
| ) |
| static void VOP_Node::incrementVariableName | ( | UT_String & | varname | ) | [static] |
| virtual void VOP_Node::initializeNode | ( | ) | [virtual] |
Gives the node a chance to initialize itself when it is first created. This is only used for VOP_ParmGenerator nodes.
Reimplemented in VOP_OutputVar, VOP_Parameter, and VOP_ParmGenerator.
| VOP_Node* VOP_Node::insertNode | ( | int | inputidx, | |
| const char * | nodetype, | |||
| bool | connect_to_input, | |||
| const char * | undo_string = NULL | |||
| ) |
| VOP_Node* VOP_Node::insertParmGenerator | ( | int | inputidx, | |
| bool | makeparmnode | |||
| ) |
Create a Parameter or Constant VOP that matches the type, name and value of one of our inputs, and connect it to that input. 'parm' specifies whether to build a Parameter or a Constant.
| void VOP_Node::insertParmGeneratorsForAllInputs | ( | bool | makeparmnodes | ) |
Create Parameter or Constant VOPs for all inputs of this node. We don't create nodes for inputs that are already connected.
| virtual bool VOP_Node::isConnected | ( | int | inputidx, | |
| bool | recursive | |||
| ) | [virtual] |
Return our input node for the give index. If recursive is true and we are in a subnet and the direct input for inputidx is a subnet input node, travel up the parent chain until no longer in a subnet or the input node is not a subnet input node. Basically, we want to know if we are connected to anything meaningful.
Reimplemented in VOP_AutoConvert.
| bool VOP_Node::isExternalShader | ( | ) |
Returns true if the operator represents an externally defined shader such as a Geometry Shader.
| bool VOP_Node::isSingleContextType | ( | ) | const |
Determines if the vop can be interpreted as a single or several RSL/VEX context types (surface, disp, ..), by looking at code generator. Returns true if the vop node is multi-type and false if single-type.
| virtual bool VOP_Node::load | ( | UT_IStream & | is, | |
| const char * | ext = "", |
|||
| const char * | path = 0 | |||
| ) | [virtual] |
Reimplemented from OP_Network.
| virtual bool VOP_Node::loadPacket | ( | UT_IStream & | is, | |
| const char * | token, | |||
| const char * | path = 0 | |||
| ) | [protected, virtual] |
Reimplemented from OP_Node.
| virtual bool VOP_Node::loadPacket | ( | UT_IStream & | is, | |
| short | class_id, | |||
| short | sig, | |||
| const char * | path = 0 | |||
| ) | [protected, virtual] |
Reimplemented from OP_Node.
| bool VOP_Node::loadParmValues | ( | UT_IStream & | is | ) |
Loads the parameter values to the output stream.
| void VOP_Node::mergeInputNodeList | ( | VOP_NodeList & | nodes, | |
| TMergeNodeInfos & | merge_infos | |||
| ) |
Recurse through our inputs and add them in order to the given list. Note this this might create new auto-conversion nodes in this list, and these will have to be deallocated by the caller (using the utility function deleteAutoConvertNodesIn())
| virtual void VOP_Node::moveInput | ( | int | srcidx, | |
| int | dstidx, | |||
| bool | forcesubnet = false | |||
| ) | [virtual] |
For subnet VOPs, when moving an input, we want to go in and reorganize the connections to our subinput and suboutput nodes so that the internal connections remain the same.
Reimplemented from OP_Node.
Reimplemented in VOP_SubnetOutput.
| bool VOP_Node::needToExecute | ( | void | ) |
If this returns false, getCode() will not be called during code generation on this node (appendOutputOverrideCode() still will). This is useful when all outputs of this node are overriden, and no execution is necessary.
| virtual void VOP_Node::onInputAllocated | ( | OP_Input * | new_input, | |
| int | index | |||
| ) | [protected, virtual] |
| void VOP_Node::onNodeChange | ( | OP_EventType | type | ) |
Do not call this method directly.
| virtual void VOP_Node::opChanged | ( | OP_EventType | reason, | |
| void * | data = 0 | |||
| ) | [virtual] |
Whenever a variable type parm changes, we have to send out an event to get our tile to update.
Reimplemented from OP_Node.
Reimplemented in VOP_ParmGenerator, and VOP_Properties.
| bool VOP_Node::outputDefaultParmDefinition | ( | ostream & | os, | |
| int | idx | |||
| ) |
Based on the specified input index, output a parm definition block appropriate for a dialog script. The parm definition provides a default value for the input if it is not connected. If the input is VEX_TYPE_UNDEF, we output nothing and return false. Otherwise we return true.
| virtual void VOP_Node::postOpChanged | ( | OP_EventType | , | |
| void * | ||||
| ) | [inline, protected, virtual] |
| virtual void VOP_Node::preOpChanged | ( | OP_EventType | , | |
| void * | ||||
| ) | [inline, protected, virtual] |
| virtual bool VOP_Node::providesShaderCode | ( | ) | [virtual] |
Returns true if the node provides or represents procedural or encapsulated shader code, or any other vop that has a code generator capable of generating shader code for this node.
| static void VOP_Node::recalculateAllParmDefiners | ( | OP_Node * | root | ) | [static] |
Calls recalculateParmDefiner on all VOP_ParmGenerator nodes under root.
| virtual void VOP_Node::referencedParmChanged | ( | int | pi | ) | [virtual] |
Reimplemented from OP_Node.
| static void VOP_Node::rewireInputs | ( | OP_Network * | parent, | |
| OP_NodeList & | inputs, | |||
| int | srcidx, | |||
| int | dstidx | |||
| ) | [static, protected] |
This function is used to rewire nodes when we do a moveInput.
| virtual bool VOP_Node::runCreateScript | ( | ) | [virtual] |
Reimplemented from OP_Node.
Reimplemented in HDK_Sample::VOP_CustomVop.
| virtual OP_ERROR VOP_Node::save | ( | ostream & | os, | |
| const OP_SaveFlags & | flags, | |||
| const char * | path_prefix = "" | |||
| ) | [virtual] |
Reimplemented from OP_Node.
| virtual int VOP_Node::saveCookedData | ( | const char * | , | |
| OP_Context & | ||||
| ) | [protected, virtual] |
Implements OP_Node.
| virtual int VOP_Node::saveCookedData | ( | ostream & | , | |
| OP_Context & | , | |||
| int | binary = 0 | |||
| ) | [protected, virtual] |
Implements OP_Node.
| virtual void VOP_Node::saveDialogScriptExtraInfo | ( | ostream & | os | ) | [virtual] |
Reimplemented from OP_Node.
| virtual OP_ERROR VOP_Node::saveIntrinsic | ( | ostream & | os, | |
| const OP_SaveFlags & | flags | |||
| ) | [protected, virtual] |
| bool VOP_Node::saveParmValues | ( | ostream & | os | ) |
Saves the parameter values to the output stream.
| virtual int VOP_Node::setDebug | ( | int | on_off | ) | [virtual] |
| void VOP_Node::setDisableAutoInputDelete | ( | bool | value | ) | [inline] |
Definition at line 557 of file VOP_Node.h.
| virtual void VOP_Node::setExtraFlag | ( | char | flag, | |
| int | onoff | |||
| ) | [virtual] |
Functions for getting and setting the in/out LOD value, using the OP_NodeFlag mechanism.
Reimplemented from OP_Node.
| int VOP_Node::setInOutLOD | ( | int | level, | |
| int | inoff | |||
| ) |
| virtual OP_ERROR VOP_Node::setInput | ( | unsigned | idx, | |
| OP_Node * | op, | |||
| unsigned | outputIdx = 0 | |||
| ) | [virtual] |
Override the setInput functions so that we can send notification to the nodes that are our inputs when we disconnect from them.
Reimplemented from OP_Node.
Reimplemented in VOP_SubnetOutput.
| virtual OP_ERROR VOP_Node::setInputReference | ( | unsigned | idx, | |
| const char * | label, | |||
| int | keeppos, | |||
| unsigned | outputIdx = 0 | |||
| ) | [virtual] |
Connects an input to particular node by name in the network.
Reimplemented from OP_Node.
Reimplemented in VOP_SubnetOutput.
| static void VOP_Node::setLODPref | ( | int | value | ) | [static] |
| void VOP_Node::setReferenceTargetDefaults | ( | int | input_index, | |
| bool | do_set | |||
| ) |
| void VOP_Node::setTables | ( | const UT_SymbolTable * | globals, | |
| UT_SymbolTable * | locals, | |||
| UT_SymbolTable * | channels | |||
| ) |
| void VOP_Node::setTablesFromVop | ( | VOP_Node * | vop | ) |
| virtual void VOP_Node::updateEncapsulatedParameters | ( | const VOP_CodeParmList & | parms | ) | [virtual] |
Update the parameters for the encapsulated shader.
| void VOP_Node::updateInputFlagsFromOperator | ( | VOP_OperatorInfo * | type_info, | |
| bool | keep_visible | |||
| ) |
Tests if this node is trully a procedural of a given type, and returns this pointer if so, or NULL otherwise. The test is done by verifying that the node has an output of the shader type specified by type.
| virtual bool VOP_Node::willAutoconvertInputType | ( | int | input_idx | ) | [virtual] |
const VOP_Language* VOP_Node::myLanguage [protected] |
int VOP_Node::myVopVersion [protected] |
Definition at line 667 of file VOP_Node.h.
1.5.9