11#include <pxr/base/arch/fileSystem.h>
12#include <pxr/base/plug/plugin.h>
13#include <pxr/base/plug/thisPlugin.h>
14#include <pxr/base/tf/envSetting.h>
15#include <pxr/imaging/hd/rendererPluginRegistry.h>
17PXR_NAMESPACE_OPEN_SCOPE
19#ifdef WITH_CYCLES_LOGGING
20TF_DEFINE_ENV_SETTING(CYCLES_LOGGING,
false,
"Enable Cycles logging")
21TF_DEFINE_ENV_SETTING(CYCLES_LOGGING_SEVERITY, 1, "Cycles logging verbosity")
26 const PlugPluginPtr plugin = PLUG_THIS_PLUGIN;
28 std::string rootPath = PXR_NS::ArchAbsPath(plugin->GetResourcePath());
29 CCL_NS::path_init(std::move(rootPath));
31#ifdef WITH_CYCLES_LOGGING
32 if (TfGetEnvSetting(CYCLES_LOGGING)) {
33 CCL_NS::util_logging_start();
34 CCL_NS::util_logging_verbosity_set(TfGetEnvSetting(CYCLES_LOGGING_SEVERITY));
60 return new HD_CYCLES_NS::HdCyclesDelegate(settingsMap);
65 delete renderDelegate;
74 HdRendererPluginRegistry::Define<PXR_NS::HdCyclesPlugin>();
77PXR_NAMESPACE_CLOSE_SCOPE
bool IsSupported() const override
PXR_NS::HdRenderDelegate * CreateRenderDelegate() override
~HdCyclesPlugin() override
void DeleteRenderDelegate(PXR_NS::HdRenderDelegate *) override
TF_REGISTRY_FUNCTION(TfType)