Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hevc: add 12bit videotoolbox decoding support #459

Merged
merged 1 commit into from
Sep 18, 2024
Merged

Conversation

gnattu
Copy link
Member

@gnattu gnattu commented Sep 18, 2024

Changes

12bit HEVC works with minimal changes if we process all filters using downsampled yuv420p10. However, it's important to note that Intel Macs never had hardware support for 12-bit processing, so they will always fall back on software decoding. Even on M1 series, hardware acceleration for 12-bit is incomplete and likely uses hybrid decoding. This is evident by the higher CPU usage compared to 10-bit 4:4:4 inputs, though the M1 still achieves better framerates with lower CPU usage than FFmpeg's native software decoder when decoding 4K HDR 12-bit 4:4:4 inputs.

Issues

Copy link
Member

@nyanmisaka nyanmisaka left a comment

Choose a reason for hiding this comment

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

Interestingly, the three vendors use different pixel memory layouts for yuv444p12.

AV_PIX_FMT_XV36 <- Intel
AV_PIX_FMT_P416 <- Apple
AV_PIX_FMT_YUV444P16 <- NVIDIA

@gnattu gnattu merged commit f5d6432 into jellyfin Sep 18, 2024
27 checks passed
@gnattu gnattu deleted the add-12b-vt branch September 18, 2024 07:23
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.

2 participants