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:
authorSybren A. Stüvel <sybren@blender.org>2019-12-17 19:00:08 +0300
committerSybren A. Stüvel <sybren@blender.org>2019-12-17 19:00:18 +0300
commit5f79e0d8f7090cb1b6f456924d3f8124f5965c75 (patch)
tree75d5b0ec50583f6336050e6737c2bda005c8b9c8 /release
parenta601f54ba2a5b5f18e46c8c2dbc46dabb68973c9 (diff)
USD: Only show in experimental features when built with USD support
Previously the USD Exporter was always visible in the Experimental Features user preferences tab, even when Blender was built with `WITH_USD=OFF`.
Diffstat (limited to 'release')
-rw-r--r--release/scripts/startup/bl_ui/space_userpref.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/release/scripts/startup/bl_ui/space_userpref.py b/release/scripts/startup/bl_ui/space_userpref.py
index 3aecd7b9775..ae77b9df01b 100644
--- a/release/scripts/startup/bl_ui/space_userpref.py
+++ b/release/scripts/startup/bl_ui/space_userpref.py
@@ -2225,6 +2225,11 @@ class USERPREF_PT_experimental_virtual_reality(ExperimentalPanel, Panel):
class USERPREF_PT_experimental_usd(ExperimentalPanel, Panel):
bl_label = "Universal Scene Description"
+ @classmethod
+ def poll(cls, context):
+ # Only show the panel if Blender was actually built with USD support.
+ return getattr(bpy.app.build_options, 'usd', False)
+
def draw_props(self, context, layout):
prefs = context.preferences