fix(#425): opaque atlas capture + descriptive PNG naming + in-process Unity capture#432
Merged
Merged
Conversation
… Unity capture xrCaptureAtlasEXT hardening (XR_EXT_atlas_capture SPEC_VERSION 1->2): - Opaque alpha at all 6 encode sites via new aux helper u_image_force_opaque_rgba8 (u_image_capture.h) — forces A=255 so captures are no longer fully-transparent/black. Applied in d3d11/d3d12/gl/metal/ vk_native compositors + comp_d3d11_service.cpp. - Runtime-owned PNG suffix _atlas_<viewCount>_<cols>x<rows> built only at the EXT-contract layer (oxr_capture.c in-process resolves the active mode tile layout via GET_XDEV_BY_ROLE(head); comp_d3d11_service.cpp IPC). Callers pass a bare <stem>-<N> prefix; the *_capture_atlas_to_png cores write verbatim. test_apps/common/atlas_capture.* + the macOS cube apps updated to pass the bare prefix. - In-process D3D11 capture: dispatch via d3d11_compositor_dispatch_capture_ zerocopy() reading the zero-copy swapchain SRV directly, so single-shared- swapchain projection layers (Unity in-process, zero-copy eligible) no longer silently drop the capture. Shared core refactored to d3d11_capture_texture_to_png(tex, w, h, path). - Diagnostics: stop the misleading "Legacy app" WARN at xrCreateInstance for engine probe instances (Unity/Unreal create a zero-extension throwaway instance that can never start a session). oxr_system_fill_in downgrades the provisional-scale log to INFO; the authoritative LEGACY-session WARN now fires in oxr_session_create only when the compromise scale actually drives rendering. Verified on native test apps, demo apps, and the Unity/Unreal plugins.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #425.
Hardens
xrCaptureAtlasEXTand bumpsXR_EXT_atlas_captureSPEC_VERSION 1 → 2.What
u_image_force_opaque_rgba8(auxiliary/util/u_image_capture.h) — captures were fully transparent → black. Applied across d3d11/d3d12/gl/metal/vk_native +comp_d3d11_service.cpp.…_atlas_<viewCount>_<cols>x<rows>.png, built only at the EXT-contract layer (oxr_capture.cin-process;comp_d3d11_service.cppIPC). Callers pass a bare<stem>-<N>prefix; the*_capture_atlas_to_pngcores write verbatim (MCPcapture_frame+ dev triggers unaffected).test_apps/common/atlas_capture.*+ macOS cube apps updated.d3d11_compositor_dispatch_capture_zerocopy()reading the zero-copy swapchain SRV directly — single-shared-swapchain projection layers (Unity in-process, zero-copy eligible) no longer silently drop the capture. Shared core refactored tod3d11_capture_texture_to_png().oxr_system.c/oxr_session.c): engine probe instances (Unity/Unreal create a zero-extension throwaway instance that can never start a session) no longer emit a misleading "Legacy app" WARN atxrCreateInstance. Provisional-scale log downgraded to INFO; the authoritative LEGACY-session WARN now fires inoxr_session_createonly when the compromise scale actually drives rendering.Coupled merge order
Spec bump 1 → 2: merge this runtime PR first, let
publish-extensionsauto-sync, then thedisplayxr-unity/displayxr-unrealplugin PRs (each pins the v2 header).Verification
Verified on native test apps, demo apps, and the Unity + Unreal plugins (in-process and IPC). The Unity-only aspect issue was a project graphics-API setting (D3D11 → D3D12), tracked separately in displayxr-unity#142.
🤖 Generated with Claude Code