From 2a094437dd07921e90d6026cc717dc343bbc9cbb Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Sat, 30 Dec 2023 20:33:31 -0600 Subject: [PATCH] Don't override HDR color format for AV1 --- .../com/limelight/binding/video/MediaCodecDecoderRenderer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/com/limelight/binding/video/MediaCodecDecoderRenderer.java b/app/src/main/java/com/limelight/binding/video/MediaCodecDecoderRenderer.java index fab18025..2cb9a612 100644 --- a/app/src/main/java/com/limelight/binding/video/MediaCodecDecoderRenderer.java +++ b/app/src/main/java/com/limelight/binding/video/MediaCodecDecoderRenderer.java @@ -486,7 +486,7 @@ public class MediaCodecDecoderRenderer extends VideoDecoderRenderer implements C // If the stream is HDR-capable, the decoder will detect transitions in color standards // rather than us hardcoding them into the MediaFormat. - if (getActiveVideoFormat() != MoonBridge.VIDEO_FORMAT_H265_MAIN10) { + if ((getActiveVideoFormat() & MoonBridge.VIDEO_FORMAT_MASK_10BIT) != 0) { // Set color format keys when not in HDR mode, since we know they won't change videoFormat.setInteger(MediaFormat.KEY_COLOR_TRANSFER, MediaFormat.COLOR_TRANSFER_SDR_VIDEO); switch (getPreferredColorSpace()) {