Skip to content

Commit 099c8cb

Browse files
committed
Fixing missing impementation of high quality scale mode in FFmpegWriter
1 parent d6a4cb1 commit 099c8cb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/FFmpegWriter.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2119,11 +2119,11 @@ void FFmpegWriter::InitScalers(int source_width, int source_height) {
21192119
// Init the software scaler from FFMpeg
21202120
#if IS_FFMPEG_3_2
21212121
if (hw_en_on && hw_en_supported) {
2122-
img_convert_ctx = sws_getContext(source_width, source_height, PIX_FMT_RGBA, info.width, info.height, AV_PIX_FMT_NV12, SWS_BILINEAR, NULL, NULL, NULL);
2122+
img_convert_ctx = sws_getContext(source_width, source_height, PIX_FMT_RGBA, info.width, info.height, AV_PIX_FMT_NV12, scale_mode, NULL, NULL, NULL);
21232123
} else
21242124
#endif
21252125
{
2126-
img_convert_ctx = sws_getContext(source_width, source_height, PIX_FMT_RGBA, info.width, info.height, AV_GET_CODEC_PIXEL_FORMAT(video_st, video_st->codec), SWS_BILINEAR,
2126+
img_convert_ctx = sws_getContext(source_width, source_height, PIX_FMT_RGBA, info.width, info.height, AV_GET_CODEC_PIXEL_FORMAT(video_st, video_st->codec), scale_mode,
21272127
NULL, NULL, NULL);
21282128
}
21292129

0 commit comments

Comments
 (0)