소스 검색

Fix subtitle dar comparison when number not exact (#12660)

gnattu 9 달 전
부모
커밋
41ac5f8d76
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs

+ 1 - 1
MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs

@@ -3015,7 +3015,7 @@ namespace MediaBrowser.Controller.MediaEncoding
                 var subtitleDar = (double)subtitleWidth.Value / subtitleHeight.Value;
 
                 // No need to add padding when DAR is the same -> 1080p PGSSUB on 2160p video
-                if (videoDar == subtitleDar)
+                if (Math.Abs(videoDar - subtitleDar) < 0.01f)
                 {
                     filters = @"scale,scale={0}:{1}:fast_bilinear";
                 }