Skip to content

HYDRA-2414 : Fix external camera resolution for two-segment UFE paths - #474

Merged
debloip-adsk merged 2 commits into
devfrom
yoonb1/HYDRA-2414/fix-ext-cam-for-2-segment-ufe-paths
Jul 30, 2026
Merged

HYDRA-2414 : Fix external camera resolution for two-segment UFE paths#474
debloip-adsk merged 2 commits into
devfrom
yoonb1/HYDRA-2414/fix-ext-cam-for-2-segment-ufe-paths

Conversation

@benyoon-adsk

@benyoon-adsk benyoon-adsk commented Jul 23, 2026

Copy link
Copy Markdown
Collaborator

Batch rendering with a USD camera in a Maya USD proxy shape (e.g. -cam "|stage1|stageShape1,/camera1") crashes with HdArnold. Single-segment Maya paths like -cam "|camera1" work.

Previously, mhExternalCameraOverrideSceneIndex -> mhExternalCameraResolvingSceneIndex converted the UFE path into one SdfPath, dropping the , segment boundary. On decode, the path became a single Maya segment instead of Maya + USD.

The fix now handles 2-segment UFE paths like "|stage1|stageShape1,/camera1" by inserting the sentinel string __ufeSegment__ during encoding:

// ex: |stage1|stageShape1,/camera1
//  -> /__adskUsd__externalCamera/stage1/stageShape1__ufeSegment__/camera1

Then later in the resolving phase, the SdfPath is converted to Ufe path segment.

@benyoon-adsk benyoon-adsk self-assigned this Jul 23, 2026
Comment thread test/lib/cmdLineRender/CMakeLists.txt
Comment thread test/lib/cmdLineRender/CMakeLists.txt

@ppt-adsk ppt-adsk left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks for the fix and the test! Code seems a bit intricate, have a look at my suggestions.

Comment thread lib/mayaHydra/hydraExtensions/sceneIndex/mhExternalCameraOverrideSceneIndex.cpp Outdated
Comment thread lib/mayaHydra/hydraExtensions/sceneIndex/mhExternalCameraOverrideSceneIndex.cpp Outdated
Comment thread lib/mayaHydra/hydraExtensions/sceneIndex/mhExternalCameraResolvingSceneIndex.cpp Outdated
@ppt-adsk ppt-adsk added the ready-for-merge Development process is finished, PR is ready for merge label Jul 30, 2026
@debloip-adsk
debloip-adsk merged commit 1600a5a into dev Jul 30, 2026
11 of 12 checks passed
@debloip-adsk
debloip-adsk deleted the yoonb1/HYDRA-2414/fix-ext-cam-for-2-segment-ufe-paths branch July 30, 2026 16:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-merge Development process is finished, PR is ready for merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants