Browse Source

mac-videotoolbox: Fix compile issue if HEVC is disabled

The format is only checked for 10-bit capable formats, which in this
case applies to HEVC only. When HEVC is disabled, then `format` is
not checked and becomes an unused variable otherwise.
PatTheMav 2 years ago
parent
commit
43f12d1fbd
1 changed files with 2 additions and 0 deletions
  1. 2 0
      plugins/mac-videotoolbox/encoder.c

+ 2 - 0
plugins/mac-videotoolbox/encoder.c

@@ -148,6 +148,8 @@ static CFStringRef obs_to_vt_profile(CMVideoCodecType codec_type,
 		}
 #endif // macOS 12.3
 		return kVTProfileLevel_HEVC_Main_AutoLevel;
+#else
+		(void)format;
 #endif // ENABLE_HEVC
 	} else {
 		return kVTProfileLevel_H264_Baseline_AutoLevel;