CARB_PLUGIN_IMPL_WITH_INIT¶
Defined in carb/PluginCoreUtils.h
-
CARB_PLUGIN_IMPL_WITH_INIT
(impl, ...)¶ Defines boiler-plate code to declare the plugin’s interfaces and registration code.
Rather than directly calling this macro, consider calling CARB_PLUGIN_IMPL which calls this macro for you.
This macro does the following:
Defines
carbGetFrameworkVersion
andcarbOnPluginRegisterEx2
functions.Sets the g_carbFramework variable so carb::getFramework() works.
Sets the plugin client variable: g_carbClientName. The client name is used by carb::Framework to create a graph of client inter-dependencies.
Advertises to carb::Framework the interfaces implemented by this plugin.
Enables the usage of ONI (see Omniverse Native Interfaces ) in the plugin.
This macro must be defined in the global namespace.
- Parameters
impl – The PluginImplDesc constant to be used as plugin description.
... – One or more interface types to be implemented by the plugin. An interface is a
struct
with a call to CARB_PLUGIN_INTERFACE() inside it. These interface types are constructed during plugin registration (prior to the plugin startup) and destructed immediately after plugin shutdown. A global fillInterface() function must exist and will be called immediately after instantiating the interface type. The interface types need not be trivially constructed or destructed, but their constructors and destructors MUST NOT use any Carbonite framework functions.