From 81735fd6644af49f010cc6b32b84038e4e7958c2 Mon Sep 17 00:00:00 2001 From: Sean Donnelly <23455376+seando-adsk@users.noreply.github.com> Date: Wed, 11 Jan 2023 16:25:48 -0500 Subject: [PATCH] MAYA-126653 - mayaUsd.ufe.stagePath() returns incorrect value * Fix build error with Ufe v1. --- lib/mayaUsd/ufe/wrapUtils.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/mayaUsd/ufe/wrapUtils.cpp b/lib/mayaUsd/ufe/wrapUtils.cpp index 162f4e0287..7deced3856 100644 --- a/lib/mayaUsd/ufe/wrapUtils.cpp +++ b/lib/mayaUsd/ufe/wrapUtils.cpp @@ -105,9 +105,14 @@ std::vector getAllStages() std::string stagePath(PXR_NS::UsdStageWeakPtr stage) { +#ifdef UFE_V2_FEATURES_AVAILABLE // Even though the Proxy shape node's UFE path is a single segment, we always // need to return as a Ufe::PathString (to remove |world). return Ufe::PathString::string(ufe::stagePath(stage)); +#else + // Remove the leading '|world' component. + return ufe::stagePath(stage).popHead().string(); +#endif } std::string usdPathToUfePathSegment(