diff --git a/src/filters/transform/vsfilter/DirectVobSubFilter.cpp b/src/filters/transform/vsfilter/DirectVobSubFilter.cpp index 52539dfb4..05bdc61fd 100644 --- a/src/filters/transform/vsfilter/DirectVobSubFilter.cpp +++ b/src/filters/transform/vsfilter/DirectVobSubFilter.cpp @@ -2280,10 +2280,19 @@ void CDirectVobSubFilter::SetYuvMatrix() } else { - yuv_matrix = (extformat.VideoTransferMatrix == DXVA2_VideoTransferMatrix_BT709 || - extformat.VideoTransferMatrix == DXVA2_VideoTransferMatrix_SMPTE240M || - m_xy_size_opt[SIZE_ORIGINAL_VIDEO].cx > m_bt601Width || - m_xy_size_opt[SIZE_ORIGINAL_VIDEO].cy > m_bt601Height) ? ColorConvTable::BT709 : ColorConvTable::BT601; + switch (extformat.VideoTransferMatrix) + { + case DXVA2_VideoTransferMatrix_BT709: + yuv_matrix = ColorConvTable::BT709; + break; + case DXVA2_VideoTransferMatrix_SMPTE240M: + yuv_matrix = ColorConvTable::BT601; + break; + default: + yuv_matrix = (m_xy_size_opt[SIZE_ORIGINAL_VIDEO].cx > m_bt601Width || + m_xy_size_opt[SIZE_ORIGINAL_VIDEO].cy > m_bt601Height) ? + ColorConvTable::BT709 : ColorConvTable::BT601; + } } } else