Data Structures | Macros | Typedefs | Functions
Plug-in Loading API

Data Structures

struct  AtNodeLib
 Used by dynamically-linked nodes to return node info. More...
 

Macros

#define AI_EXPORT_LIB   AI_EXTERN_C AI_DLL_EXPORT
 Used by dynamically-linked nodes to export the entry-point function.
 

Typedefs

typedef struct AtNodeLib AtNodeLib
 Used by dynamically-linked nodes to return node info.
 

Functions

AI_API void AiLoadPlugins (const char *directory)
 Dynamically load plug-ins from a list of libraries. More...
 
AI_API void AiLoadPlugin (const char *path)
 Dynamically load a specific plug-in library. More...
 

Detailed Description

Function Documentation

AI_API void AiLoadPlugins ( const char *  file_or_dir)

Dynamically load plug-ins from a list of libraries.

Dynamically loads plug-in nodes from a list of libraries given by their file names or by the paths to the directories where they reside.

Plug-in nodes are stored in dynamic libraries, or library modules. The extension of these files is system-dependent:

  • Windows: .dll
  • Linux: .so / .sog
  • OSX: .dylib (although the Linux-like form .so/.sog is also supported)

Library modules must define an entry-point function (the plug-in "hook") called NodeLoader(). The Arnold API provides a handy wrapper for this hook called node_loader, which plug-in writers are encouraged to use.

A single library module can contain one or more Arnold nodes of any of the available node classes, such as shaders, cameras, drivers, etc.

Note
Using a .sog extension in Linux or Mac OS X will trigger the global export of the symbols from the plugin (whereas .so plugins will only expose symbols locally).
Warning
This function is not thread-safe. It is typically called before the scene is created and before actual rendering starts.
Parameters
file_or_dira list of multiple entries (separated by ':' in Linux/OSX or ';' in Windows), where each entry can be a library file name or a directory, that will be searched for library files
AI_API void AiLoadPlugin ( const char *  path)

Dynamically load a specific plug-in library.

For more information on Arnold plug-ins, see AiLoadPlugins.

Warning
This function is not thread-safe. It is typically called before the scene is created and before actual rendering starts.
Deprecated:
Use AiLoadPlugins() instead
Parameters
pathan absolute path to a plug-in library

© 2009-2013 Solid Angle SL · all rights reserved · www.solidangle.com