HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DAE_OPUtil Class Reference

#include <DAE_OPUtil.h>

Static Public Member Functions

static void getOPLabel (const UT_String &name, const UT_String &id, UT_String &label)
 Passes back a suggested OP label for the given name and id. More...
 
static OP_NetworkfindOPNetwork (const char *path)
 
static OP_NodecreateOPNode (OP_Network *parent, const char *label, const char *type, bool runInit=1)
 
static void wireOPNodes (OP_Node *outputNode, OP_Node *inputNode, int inputIndex)
 
static void wireOPNodes (OP_SubnetIndirectInput *outputNode, OP_Node *inputNode, int inputIndex)
 
static void organizeOPLayout (OP_Network *network, OP_LayoutDirection layout_dir=OP_LAYOUT_TOP_TO_BOT)
 Organizes the node layout in the given network. More...
 
static void getOPParmValue (OP_Node *node, const char *parmName, int &ivalue, int index=0)
 Passes back the OP parameter's value (1 integer). More...
 
static void getOPParmValue (OP_Node *node, const char *parmName, fpreal &fvalue, int index=0)
 Passes back the OP parameter's value (1 float). More...
 
static void setOPParm (OP_Node *node, const char *parmName, int ivalue, int index=0)
 Sets the OP parameter's value (1 integer). More...
 
static void setOPParm (OP_Node *node, const char *parmName, fpreal fvalue, int index=0)
 Sets the OP parameter's value (1 float). More...
 
static void setOPParm (OP_Node *node, const char *parmName, const char *strvalue, CH_StringMeaning meaning, int index=0)
 Sets the OP parameter's value (1 string). More...
 
static void setOPParm (OP_Node *node, const char *parmName, fpreal fvalue1, fpreal fvalue2, fpreal fvalue3)
 Sets the OP parameter's value (3 floats). More...
 
static void setOPParm (OP_Node *node, const char *parmName, const char *svalue1, const char *svalue2, const char *svalue3, CH_StringMeaning meaning)
 Sets the OP parameter's value (3 strings). More...
 
static void addOPSpareFloatParm (OP_Node *node, const char *token, const char *label, fpreal defaultValue, fpreal minValue, fpreal maxValue, bool cook_dependent=false)
 Adds a spare float parameter to the given node. More...
 
static void addOPSpareStringParm (OP_Node *node, const char *token, const char *label, const char *defaultValue, bool cook_dependent=false)
 Adds a spare string parameter to the given node. More...
 
static void addOPSpare3FloatParm (OP_Node *node, const char *token, const char *label, fpreal defaultValue1, fpreal defaultValue2, fpreal defaultValue3, bool cook_dependent=false)
 Adds a spare 3-float parameter to the given node. More...
 
static void addOPProperty (OP_Node *node, const char *propClass, const char *propName)
 Adds a property to the given node. More...
 
static void keyOPChannel (CH_Channel *ch, fpreal time, fpreal fvalue, bool hasInSlope=false, bool hasOutSlope=false, bool hasInterp=false, fpreal inSlope=0.0, fpreal outSlope=0.0, const char *interp="")
 
static int getCHIndexByName (const char *name)
 
static const char * getCHKeyExprByName (const char *name)
 

Protected Member Functions

 DAE_OPUtil ()
 Constructor. More...
 
virtual ~DAE_OPUtil ()
 Destructor. More...
 

Detailed Description

Static class. The OP utility library. This is a wrapper for low-level functionality dealing with objects from the Houdini network.

Definition at line 29 of file DAE_OPUtil.h.

Constructor & Destructor Documentation

DAE_OPUtil::DAE_OPUtil ( )
protected

Constructor.

virtual DAE_OPUtil::~DAE_OPUtil ( )
protectedvirtual

Destructor.

Member Function Documentation

static void DAE_OPUtil::addOPProperty ( OP_Node node,
const char *  propClass,
const char *  propName 
)
static

Adds a property to the given node.

static void DAE_OPUtil::addOPSpare3FloatParm ( OP_Node node,
const char *  token,
const char *  label,
fpreal  defaultValue1,
fpreal  defaultValue2,
fpreal  defaultValue3,
bool  cook_dependent = false 
)
static

Adds a spare 3-float parameter to the given node.

static void DAE_OPUtil::addOPSpareFloatParm ( OP_Node node,
const char *  token,
const char *  label,
fpreal  defaultValue,
fpreal  minValue,
fpreal  maxValue,
bool  cook_dependent = false 
)
static

Adds a spare float parameter to the given node.

static void DAE_OPUtil::addOPSpareStringParm ( OP_Node node,
const char *  token,
const char *  label,
const char *  defaultValue,
bool  cook_dependent = false 
)
static

Adds a spare string parameter to the given node.

static OP_Node* DAE_OPUtil::createOPNode ( OP_Network parent,
const char *  label,
const char *  type,
bool  runInit = 1 
)
static

Creates an OP node of the given type, under the given parent network. If successful, returns a pointer to the new OP_Node, otherwise, it returns NULL.

static OP_Network* DAE_OPUtil::findOPNetwork ( const char *  path)
static

Uses the path to find a node in the Houdini network. Returns a pointer to the OP network if the node is a subnet. Returns NULL otherwise.

static int DAE_OPUtil::getCHIndexByName ( const char *  name)
static

Returns the channel index that corresponds to the given symbolic name. The mapping of names to indices is specified in "Chapter 4: The COMMON Profile - Common Glossary" of the COLLADA specification document.

static const char* DAE_OPUtil::getCHKeyExprByName ( const char *  name)
static

Returns the CH key expression that corresponds to the given symbol name. The possible names are specified in "Chapter 3: Schema Reference - <sampler>" of the COLLADA specificaion document.

static void DAE_OPUtil::getOPLabel ( const UT_String name,
const UT_String id,
UT_String label 
)
static

Passes back a suggested OP label for the given name and id.

static void DAE_OPUtil::getOPParmValue ( OP_Node node,
const char *  parmName,
int ivalue,
int  index = 0 
)
static

Passes back the OP parameter's value (1 integer).

static void DAE_OPUtil::getOPParmValue ( OP_Node node,
const char *  parmName,
fpreal fvalue,
int  index = 0 
)
static

Passes back the OP parameter's value (1 float).

static void DAE_OPUtil::keyOPChannel ( CH_Channel ch,
fpreal  time,
fpreal  fvalue,
bool  hasInSlope = false,
bool  hasOutSlope = false,
bool  hasInterp = false,
fpreal  inSlope = 0.0,
fpreal  outSlope = 0.0,
const char *  interp = "" 
)
static

Sets a keyframe on the given channel using the passed-in attributes.

static void DAE_OPUtil::organizeOPLayout ( OP_Network network,
OP_LayoutDirection  layout_dir = OP_LAYOUT_TOP_TO_BOT 
)
static

Organizes the node layout in the given network.

static void DAE_OPUtil::setOPParm ( OP_Node node,
const char *  parmName,
int  ivalue,
int  index = 0 
)
static

Sets the OP parameter's value (1 integer).

static void DAE_OPUtil::setOPParm ( OP_Node node,
const char *  parmName,
fpreal  fvalue,
int  index = 0 
)
static

Sets the OP parameter's value (1 float).

static void DAE_OPUtil::setOPParm ( OP_Node node,
const char *  parmName,
const char *  strvalue,
CH_StringMeaning  meaning,
int  index = 0 
)
static

Sets the OP parameter's value (1 string).

static void DAE_OPUtil::setOPParm ( OP_Node node,
const char *  parmName,
fpreal  fvalue1,
fpreal  fvalue2,
fpreal  fvalue3 
)
static

Sets the OP parameter's value (3 floats).

static void DAE_OPUtil::setOPParm ( OP_Node node,
const char *  parmName,
const char *  svalue1,
const char *  svalue2,
const char *  svalue3,
CH_StringMeaning  meaning 
)
static

Sets the OP parameter's value (3 strings).

static void DAE_OPUtil::wireOPNodes ( OP_Node outputNode,
OP_Node inputNode,
int  inputIndex 
)
static

Wires the first operator into the second operator. The connection is made to the input corresponding to 'inputIndex'.

static void DAE_OPUtil::wireOPNodes ( OP_SubnetIndirectInput outputNode,
OP_Node inputNode,
int  inputIndex 
)
static

Wires the indirect input node into the operator. The connection is made to the input corresponding to 'inputIndex'.


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