Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/io/usd/intern/usd_common.cc')
-rw-r--r--source/blender/io/usd/intern/usd_common.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/io/usd/intern/usd_common.cc b/source/blender/io/usd/intern/usd_common.cc
index 2b6b6f4ed43..e5a83442140 100644
--- a/source/blender/io/usd/intern/usd_common.cc
+++ b/source/blender/io/usd/intern/usd_common.cc
@@ -11,6 +11,10 @@ namespace blender::io::usd {
void ensure_usd_plugin_path_registered()
{
+ /* if PXR_PYTHON_SUPPORT_ENABLED is defined, we *must* be dynamic and
+ the plugins are placed relative to the USD shared library hence no
+ hinting is required. */
+#ifndef PXR_PYTHON_SUPPORT_ENABLED
static bool plugin_path_registered = false;
if (plugin_path_registered) {
return;
@@ -22,6 +26,7 @@ void ensure_usd_plugin_path_registered()
const std::string blender_usd_datafiles = BKE_appdir_folder_id(BLENDER_DATAFILES, "usd");
/* The trailing slash indicates to the USD library that the path is a directory. */
pxr::PlugRegistry::GetInstance().RegisterPlugins(blender_usd_datafiles + "/");
+#endif
}
} // namespace blender::io::usd