feat(video): detect HDR Vivid metadata in performance overlay - #86
Conversation
|
Warning Review limit reached
Next review available in: 45 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthrough新增 HDR Vivid 元数据扫描器,在 HEVC HLG 解码过程中检测 CUVA T.35 SEI,并将结果经 native bridge 与串流统计传递至性能覆盖层,显示 HDR Vivid、HLG 或 PQ 解码器信息。 ChangesHDR Vivid 检测链路
Estimated code review effort: 4 (Complex) | ~45 minutes 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@nativelib/src/test/cpp/hdr_vivid_metadata_scanner_test.cpp`:
- Line 28: Replace the sole assert in main’s ScanSegments test with an explicit
failure check that remains active in release builds. When ScanSegments(segments)
returns false, emit an error message and return a nonzero status; retain the
success path only when scanning succeeds.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: fc7bc75c-e44e-4a9d-8aaf-7ecb76f5b55b
📒 Files selected for processing (10)
entry/src/main/ets/components/PerformanceOverlay.etsentry/src/main/ets/components/PerformanceOverlayManager.etsentry/src/main/ets/service/streaming/StreamingSession.etsnativelib/src/main/cpp/CMakeLists.txtnativelib/src/main/cpp/hdr_vivid_metadata_scanner.cppnativelib/src/main/cpp/hdr_vivid_metadata_scanner.hnativelib/src/main/cpp/moonlight_bridge.cppnativelib/src/main/cpp/video_decoder.cppnativelib/src/main/cpp/video_decoder.hnativelib/src/test/cpp/hdr_vivid_metadata_scanner_test.cpp
改了啥呀
0x26 / 0x0004 / 0x0005判断真实 HDR Vivid 动态元数据HDR PQ、HDR HLG和HDR Vivid为啥要改
HLG 配置只能说明传输函数,不能证明码流真的带了 HDR Vivid 动态元数据。现在直接看码流证据,纯 HLG 不用再被杂鱼误判硬塞成 Vivid 啦。
扫描仅发生在 HEVC HLG 会话开始阶段,命中后保持会话状态,避免给正常解码路径增加持续开销。
验证
c++ -std=c++17 -Wall -Wextra -Werror -I nativelib/src/main/cpp nativelib/src/main/cpp/hdr_vivid_metadata_scanner.cpp nativelib/src/test/cpp/hdr_vivid_metadata_scanner_test.cpp -o /tmp/moonlight_hdr_vivid_scanner_test && /tmp/moonlight_hdr_vivid_scanner_testnpm run check:scriptsDEVECO_SDK_HOME=/Users/mac/ohos-sdk-cache/6.1-Release-mac/sdk-ci-shape JAVA_HOME=/Applications/DevEco-Studio.app/Contents/jbr/Contents/Home node hvigorw.js assembleApp --mode project -p product=default -p buildMode=debug --no-daemonSummary by CodeRabbit
新功能
问题修复