HDK
|
Typedefs | |
typedef void * | Handle |
Functions | |
OIIO_UTIL_API const char * | plugin_extension (void) |
OIIO_UTIL_API Handle | open (const char *plugin_filename, bool global=true) |
Handle | open (const std::string &plugin_filename, bool global=true) |
OIIO_UTIL_API bool | close (Handle plugin_handle) |
OIIO_UTIL_API void * | getsym (Handle plugin_handle, const char *symbol_name, bool report_error=true) |
void * | getsym (Handle plugin_handle, const std::string &symbol_name, bool report_error=true) |
OIIO_UTIL_API std::string | geterror (bool clear=true) |
typedef void* Plugin::Handle |
OIIO_UTIL_API bool Plugin::close | ( | Handle | plugin_handle | ) |
Close the open plugin with the given handle and return true upon success. If some error occurred, return false and the next call to geterror() will contain an explanatory message.
OIIO_UTIL_API std::string Plugin::geterror | ( | bool | clear = true | ) |
Return any error messages associated with the last call to any of open, close, or getsym from the same thread.
OIIO_UTIL_API void* Plugin::getsym | ( | Handle | plugin_handle, |
const char * | symbol_name, | ||
bool | report_error = true |
||
) |
Get the address of the named symbol from the open plugin handle. If some error occurred, return nullptr and the next call to geterror() will contain an explanatory message (unless report_error is false, in which case the error message will be suppressed).
|
inline |
OIIO_UTIL_API Handle Plugin::open | ( | const char * | plugin_filename, |
bool | global = true |
||
) |
Open the named plugin, return its handle. If it could not be opened, return 0 and the next call to geterror() will contain an explanatory message. If the 'global' parameter is true, all symbols from the plugin will be available to the app (on Unix-like platforms; this has no effect on Windows).
|
inline |
OIIO_UTIL_API const char* Plugin::plugin_extension | ( | void | ) |
Return the platform-dependent suffix for plug-ins ("dll" on Windows, "so" on Linux and Mac OS X.