Skip to content

fix(linux): import P010 as single-plane images without multi-planar support - #1413

Closed
TheWeaklessOne wants to merge 1 commit into
OpenCloudGaming:devfrom
TheWeaklessOne:fix/linux-p010-single-plane-import
Closed

TheWeaklessOne wants to merge 1 commit into
OpenCloudGaming:devfrom
TheWeaklessOne:fix/linux-p010-single-plane-import

Conversation

@TheWeaklessOne

Copy link
Copy Markdown

10-bit HDR streams through VA-API DMA-BUF come out green on Turnip (Adreno 740, AYN Odin 2 Portal). The driver has neither G10X6_B10X6R10X6_2PLANE_420_UNORM_3PACK16 nor the R10X6 plane views, and an image of a format it cannot sample reads as zeros.

When the multi-planar format is not sampleable with the frame's DRM modifier, or the 10-bit plane views are missing, import_nv12_dmabuf now imports P010 as two single-plane images over the same DMA-BUF: R16_UNORM luma and R16G16_UNORM chroma, the way libplacebo does. The 10-bit samples sit in the high bits of each 16-bit word, so the conversion runs with sample_bits = 16, as it already does for R16_UNORM Vulkan frames. The acquire and release barriers cover the second image.

Drivers that support the multi-planar format keep the existing path. multi_planar_p010_samples makes that decision per modifier.

Verification:

  • cargo test -p opennow-streamer-platform-linux on clean dev with this change: 187 passed. One failure, fixed_audio_output_never_falls_back_and_stays_isolated, is unrelated: ALSA device enumeration returns -2 on that device, also without this change.
  • GeForce NOW on an Odin 2 Portal (msm VA-API driver from Fix Av1 + 10 bit + HDR on odin 2 portal hashtagbasit/Zaviya#80), AV1 10-bit 4:2:0 HDR, 1080p: correct colours, 120 decoded fps.

The stream test ran on a tree with other local changes for that device. Not tested on AMD or Intel, where the single-plane path should not be selected.

🤖 Generated with Claude Code

…upport

Turnip on the Adreno 740 has no G10X6_B10X6R10X6_2PLANE_420 and no R10X6
views, and an image of a format the driver cannot sample reads as zeros, so
10-bit HDR streams through VA-API DMA-BUF came out green. When the
multi-planar format is not sampleable with the frame's DRM modifier, import
the planes as R16 and R16G16 images over the same DMA-BUF, as libplacebo
does. Drivers that support the multi-planar format keep the existing path.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Nov 5, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 331b3f60-7a8c-4763-b62a-f125667312d5

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-05T20:25:09.373932Z 976aacb PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@TheWeaklessOne

Copy link
Copy Markdown
Author

Folded into #1470 together with the other Linux decode fixes, rebased on dev and retested on the Portal. Closing this one in favour of it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant