Macros
ai_nodes.h File Reference

AtNode struct and methods. More...

#include "ai_node_entry.h"
#include "ai_params.h"
#include "ai_api.h"
#include "ai_string.h"

Go to the source code of this file.

Macros

#define AI_INSTANCE_COMMON_METHODS
 Exporter for common methods. More...
 
#define AI_INSTANCE_COMMON_SHAPE_METHODS
 Exporter for common shape methods. More...
 
#define AiNodeDeclareGPULocalData(type)   namespace {}
 
Node Method Declarations
#define node_parameters   static void Parameters(AtList* params, AtNodeEntry* nentry)
 Parameter declaration method.
 
#define node_plugin_initialize
 Node plugin initialize method (optional) More...
 
#define node_plugin_cleanup
 Node plugin cleanup method (optional) More...
 
#define node_initialize   static void Initialize(AtNode* node)
 Node initialization method.
 
#define node_update   static void Update(AtNode* node)
 Node update method.
 
#define node_finish   static void Finish(AtNode* node)
 Node de-initialization method.
 
#define node_loader   AI_EXPORT_LIB bool NodeLoader(int i, AtNodeLib* node)
 Node loading method (for plugin nodes in dynamic libraries)
 

Functions

AtNode Methods
AI_API AtNodeAiNode (AtUniverse *universe, const AtString nentry_name, const AtString name=AtString(), const AtNode *parent=NULL)
 Create a fresh instantiation of a node in a specific Arnold universe. More...
 
AI_API AI_PURE AtNodeAiNodeLookUpByName (const AtUniverse *universe, const AtString name, const AtNode *parent=NULL)
 Search for a specific node in the given universe using the specified name string (which can be a simple name, a relative path or an absolute path). More...
 
AI_API bool AiNodeDeclare (AtNode *node, const AtString param, const char *declaration)
 Declare a user-defined parameter for this node. More...
 
AI_API AI_PURE const AtUserParamEntry * AiNodeLookUpUserParameter (const AtNode *node, const AtString param)
 Return the user-defined parameter entry that matches a given name. More...
 
AI_API AI_PURE bool AiNodeIs (const AtNode *node, AtString str)
 Compare the node type against a string. More...
 
AI_API void AiNodeReset (AtNode *node)
 Reset all node parameters to their default values and remove any input links. More...
 
AI_API void AiNodeResetParameter (AtNode *node, const char *param)
 Reset a node parameter to its default value and remove any links to that parameter. More...
 
AI_API AtNodeAiNodeClone (const AtNode *node, const AtString new_name=AtString(), const AtNode *parent=NULL)
 Return an exact clone of a source node. More...
 
AI_API bool AiNodeDestroy (AtNode *node)
 Destroy an existing node. More...
 
AI_API void AiNodeReplace (AtNode *old_node, AtNode *new_node, bool remove)
 Replace an existing node with another, updating all references to that node. More...
 
AI_API bool AiNodeLink (AtNode *src, const char *input, AtNode *target)
 Creates a connection between two shader nodes. More...
 
AI_API bool AiNodeLinkOutput (AtNode *src, const char *output, AtNode *target, const char *input)
 Creates a connection between two shader nodes. More...
 
AI_API bool AiNodeUnlink (AtNode *node, const char *input)
 Removes a connection from a node input parameter. More...
 
AI_API AI_PURE bool AiNodeIsLinked (const AtNode *node, const char *input)
 Returns true if the input parameter is linked. More...
 
AI_API AtNodeAiNodeGetLink (const AtNode *node, const char *input, int *comp=NULL)
 Returns the node connected to a given node input parameter. More...
 
AI_API AI_PURE const char * AiNodeGetName (const AtNode *node)
 Return the node's name. More...
 
AI_API AI_PURE const AtNodeEntryAiNodeGetNodeEntry (const AtNode *node)
 Return the node entry for this node. More...
 
AI_API AI_PURE void * AiNodeGetLocalData (const AtNode *node)
 Returns a pointer to the local data in the node. More...
 
AI_API void AiNodeSetLocalData (AtNode *node, void *data)
 Sets local data pointer in the node. More...
 
AI_API AI_PURE void * AiNodeGetPluginData (const AtNode *node)
 Returns a pointer to the per plugin data for the node type, as created in the node_plugin_initialize method. More...
 
AI_API void AiNodeSetDisabled (AtNode *node, bool disabled)
 Disable or enable any node in the scene. More...
 
AI_API AI_PURE bool AiNodeIsDisabled (const AtNode *node)
 Check if a node has been disabled or not. More...
 
AI_API AI_PURE AtNodeAiNodeGetParent (const AtNode *node)
 Returns the procedural parent of a node. More...
 
AI_API AI_PURE AtUniverseAiNodeGetUniverse (const AtNode *node)
 Returns the universe a node belongs to. More...
 
AI_API AtUserParamIterator * AiNodeGetUserParamIterator (const AtNode *node)
 Creates and returns a new AtUserParamIterator for this node. More...
 
AI_DEPRECATED AtNodeAiNode (const AtString nentry_name, const AtString name=AtString(), const AtNode *parent=NULL)
 Create a fresh instantiation of a node in the default universe. More...
 
AI_DEPRECATED AtNodeAiNodeLookUpByName (const AtString name, const AtNode *parent=NULL)
 Search for a specific node in the default universe using the specified name string (which can be a simple name, a relative path or an absolute path). More...
 
AI_DEPRECATED AtNodeAiNode (AtUniverse *universe, const char *nentry_name, const char *name="", const AtNode *parent=NULL)
 
AI_DEPRECATED AtNodeAiNode (const char *nentry_name, const char *name="", const AtNode *parent=NULL)
 
AI_DEPRECATED AtNodeAiNodeLookUpByName (const AtUniverse *universe, const char *name, const AtNode *parent=NULL)
 
AI_DEPRECATED AtNodeAiNodeLookUpByName (const char *name, const AtNode *parent=NULL)
 
AI_DEPRECATED bool AiNodeDeclare (AtNode *node, const char *param, const char *declaration)
 
AI_DEPRECATED const AtUserParamEntry * AiNodeLookUpUserParameter (const AtNode *node, const char *param)
 
AtUserParamIterator Methods
AI_API void AiUserParamIteratorDestroy (AtUserParamIterator *iter)
 Destroys a user param iterator when it is no longer needed. More...
 
AI_API const AtUserParamEntry * AiUserParamIteratorGetNext (AtUserParamIterator *iter)
 Returns current user param entry and points user param iterator to the next one. More...
 
AI_API bool AiUserParamIteratorFinished (const AtUserParamIterator *iter)
 Returns true if there are no more user parameters to iterate over. More...
 
Parameter Writers
AI_API void AiNodeSetByte (AtNode *node, const AtString param, uint8_t val)
 
AI_API void AiNodeSetInt (AtNode *node, const AtString param, int val)
 Set the value of an integer parameter. More...
 
AI_API void AiNodeSetUInt (AtNode *node, const AtString param, unsigned int val)
 
AI_API void AiNodeSetBool (AtNode *node, const AtString param, bool val)
 
AI_API void AiNodeSetFlt (AtNode *node, const AtString param, float val)
 
AI_API void AiNodeSetPtr (AtNode *node, const AtString param, void *val)
 
AI_API void AiNodeSetArray (AtNode *node, const AtString param, AtArray *val)
 Set the value of an array parameter. More...
 
AI_API void AiNodeSetMatrix (AtNode *node, const AtString param, AtMatrix val)
 
AI_API void AiNodeSetStr (AtNode *node, const AtString param, const AtString str)
 
AI_API void AiNodeSetRGB (AtNode *node, const AtString param, float r, float g, float b)
 
AI_API void AiNodeSetRGBA (AtNode *node, const AtString param, float r, float g, float b, float a)
 
AI_API void AiNodeSetVec (AtNode *node, const AtString param, float x, float y, float z)
 
AI_API void AiNodeSetVec2 (AtNode *node, const AtString param, float x, float y)
 
AI_DEPRECATED void AiNodeSetByte (AtNode *node, const char *param, uint8_t val)
 
AI_DEPRECATED void AiNodeSetInt (AtNode *node, const char *param, int val)
 
AI_DEPRECATED void AiNodeSetUInt (AtNode *node, const char *param, unsigned int val)
 
AI_DEPRECATED void AiNodeSetBool (AtNode *node, const char *param, bool val)
 
AI_DEPRECATED void AiNodeSetFlt (AtNode *node, const char *param, float val)
 
AI_DEPRECATED void AiNodeSetPtr (AtNode *node, const char *param, void *val)
 
AI_DEPRECATED void AiNodeSetArray (AtNode *node, const char *param, AtArray *val)
 
AI_DEPRECATED void AiNodeSetMatrix (AtNode *node, const char *param, AtMatrix val)
 
AI_DEPRECATED void AiNodeSetStr (AtNode *node, const char *param, const char *str)
 
AI_DEPRECATED void AiNodeSetRGB (AtNode *node, const char *param, float r, float g, float b)
 
AI_DEPRECATED void AiNodeSetRGBA (AtNode *node, const char *param, float r, float g, float b, float a)
 
AI_DEPRECATED void AiNodeSetVec (AtNode *node, const char *param, float x, float y, float z)
 
AI_DEPRECATED void AiNodeSetVec2 (AtNode *node, const char *param, float x, float y)
 
AI_API void AiNodeSetAttributes (AtNode *node, const char *attributes)
 Set the parameters of a node through an attributes string. More...
 
Parameter Readers
AI_API uint8_t AiNodeGetByte (const AtNode *node, const AtString param)
 
AI_API int AiNodeGetInt (const AtNode *node, const AtString param)
 Return the value of an integer parameter. More...
 
AI_API unsigned int AiNodeGetUInt (const AtNode *node, const AtString param)
 
AI_API bool AiNodeGetBool (const AtNode *node, const AtString param)
 
AI_API float AiNodeGetFlt (const AtNode *node, const AtString param)
 
AI_API AtRGB AiNodeGetRGB (const AtNode *node, const AtString param)
 
AI_API AtRGBA AiNodeGetRGBA (const AtNode *node, const AtString param)
 
AI_API AtVector AiNodeGetVec (const AtNode *node, const AtString param)
 
AI_API AtVector2 AiNodeGetVec2 (const AtNode *node, const AtString param)
 
AI_API AtString AiNodeGetStr (const AtNode *node, const AtString param)
 
AI_API void * AiNodeGetPtr (const AtNode *node, const AtString param)
 
AI_API AtArray * AiNodeGetArray (const AtNode *node, const AtString param)
 
AI_API AtMatrix AiNodeGetMatrix (const AtNode *node, const AtString param)
 
AI_DEPRECATED uint8_t AiNodeGetByte (const AtNode *node, const char *param)
 
AI_DEPRECATED int AiNodeGetInt (const AtNode *node, const char *param)
 
AI_DEPRECATED unsigned int AiNodeGetUInt (const AtNode *node, const char *param)
 
AI_DEPRECATED bool AiNodeGetBool (const AtNode *node, const char *param)
 
AI_DEPRECATED float AiNodeGetFlt (const AtNode *node, const char *param)
 
AI_DEPRECATED AtRGB AiNodeGetRGB (const AtNode *node, const char *param)
 
AI_DEPRECATED AtRGBA AiNodeGetRGBA (const AtNode *node, const char *param)
 
AI_DEPRECATED AtVector AiNodeGetVec (const AtNode *node, const char *param)
 
AI_DEPRECATED AtVector2 AiNodeGetVec2 (const AtNode *node, const char *param)
 
AI_DEPRECATED AtString AiNodeGetStr (const AtNode *node, const char *param)
 
AI_DEPRECATED void * AiNodeGetPtr (const AtNode *node, const char *param)
 
AI_DEPRECATED AtArray * AiNodeGetArray (const AtNode *node, const char *param)
 
AI_DEPRECATED AtMatrix AiNodeGetMatrix (const AtNode *node, const char *param)
 

Detailed Description

AtNode struct and methods.


© 2020 Autodesk, Inc. · All rights reserved · www.arnoldrenderer.com