![]() |
|
This class defines a renderer plugin interface for Hydra. More...
#include <rendererPlugin.h>
Inheritance diagram for HdRendererPlugin:Public Member Functions | |
| HD_API TfToken | GetPluginId () const |
| Look-up plugin id in plugin registry. | |
| HD_API std::string | GetDisplayName () const |
| Look-up display name in plugin registry. | |
| virtual bool | IsSupported (HdRendererCreateArgs const &rendererCreateArgs, std::string *reasonWhyNot=nullptr) const =0 |
Returns true if this renderer plugin is supported in the running process and false if not. | |
| virtual HD_API bool | IsSupported (bool gpuEnabled=true) const |
Hydra 2.0 API | |
| HD_API HdPluginRendererUniqueHandle | CreateRenderer (HdSceneIndexBaseRefPtr const &sceneIndex, const HdRendererCreateArgs &rendererCreateArgs) |
| Create renderer through the plugin and wrap it in a handle that keeps this plugin alive until the renderer is destroyed. | |
Hydra 1.0 API | |
| HD_API HdPluginRenderDelegateUniqueHandle | CreateDelegate (HdRenderSettingsMap const &settingsMap={}) |
| Create a render delegate through the plugin and wrap it in a handle that keeps this plugin alive until render delegate is destroyed. | |
| virtual HdRenderDelegate * | CreateRenderDelegate ()=0 |
| Clients should use CreateDelegate since this method will eventually become protected, use CreateRenderDelegateHandle instead. | |
| virtual HD_API HdRenderDelegate * | CreateRenderDelegate (HdRenderSettingsMap const &settingsMap) |
| Clients should use CreateDelegate since this method will eventually become protected. | |
| virtual void | DeleteRenderDelegate (HdRenderDelegate *renderDelegate)=0 |
| Clients should use CreateDelegate since this method will eventually become protected. | |
Protected Member Functions | |
| virtual HD_API std::unique_ptr< HdRenderer > | _CreateRenderer (HdSceneIndexBaseRefPtr const &sceneIndex, const HdRendererCreateArgs &rendererCreateArgs) |
This class defines a renderer plugin interface for Hydra.
A renderer plugin is a dynamically discovered and loaded at run-time using the Plug system.
This object has singleton behavior, in that is instantiated once per library (managed by the plugin registry).
The class is used to factory objects that provide delegate support to other parts of the Hydra Ecosystem.
Definition at line 34 of file rendererPlugin.h.
| HD_API HdPluginRenderDelegateUniqueHandle CreateDelegate | ( | HdRenderSettingsMap const & | settingsMap = {} | ) |
Create a render delegate through the plugin and wrap it in a handle that keeps this plugin alive until render delegate is destroyed.
Initial settings can be passed in.
|
pure virtual |
Clients should use CreateDelegate since this method will eventually become protected, use CreateRenderDelegateHandle instead.
Factory a Render Delegate object, that Hydra can use to factory prims and communicate with a renderer.
Implemented in HdEmbreeRendererPlugin.
|
virtual |
Clients should use CreateDelegate since this method will eventually become protected.
Factory a Render Delegate object, that Hydra can use to factory prims and communicate with a renderer. Pass in initial settings...
Reimplemented in HdEmbreeRendererPlugin.
| HD_API HdPluginRendererUniqueHandle CreateRenderer | ( | HdSceneIndexBaseRefPtr const & | sceneIndex, |
| const HdRendererCreateArgs & | rendererCreateArgs | ||
| ) |
Create renderer through the plugin and wrap it in a handle that keeps this plugin alive until the renderer is destroyed.
The renderer is populated from the given scene index.
|
pure virtual |
Clients should use CreateDelegate since this method will eventually become protected.
Release the object factoried by CreateRenderDelegate().
Implemented in HdEmbreeRendererPlugin.
| HD_API std::string GetDisplayName | ( | ) | const |
Look-up display name in plugin registry.
| HD_API TfToken GetPluginId | ( | ) | const |
Look-up plugin id in plugin registry.
|
virtual |
Returns true if this renderer plugin is supported in the running process and false if not.
This gives the plugin a chance to perform some runtime checks to make sure that the system meets minimum requirements. The gpuEnabled parameter indicates if the GPU is available for use by the plugin in case this information is necessary to make this determination.
|
pure virtual |
Returns true if this renderer plugin is supported in the running process and false if not.
This gives the plugin a chance to perform some runtime checks to make sure that the system meets minimum requirements. The rendererCreateArgs parameter indicates the resources available when making this determination.
The reasonWhyNot param, when provided, can be filled with the reason why the renderer plugin is not supported.
Implemented in HdEmbreeRendererPlugin.