From 1ea42ab9f0eacc40529f0c908ff7a56994e5d7cd Mon Sep 17 00:00:00 2001 From: Aurumaker72 Date: Thu, 19 Dec 2024 20:43:58 +0100 Subject: [PATCH] FFmpegEncoder/Fix: Wrong divisor in sample length calculation --- view/capture/encoders/FFmpegEncoder.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/view/capture/encoders/FFmpegEncoder.cpp b/view/capture/encoders/FFmpegEncoder.cpp index 90d403f0..555e9c61 100644 --- a/view/capture/encoders/FFmpegEncoder.cpp +++ b/view/capture/encoders/FFmpegEncoder.cpp @@ -173,7 +173,7 @@ bool FFmpegEncoder::append_video(uint8_t* image) { if (lag_count > 2) { - const auto samples_per_frame = static_cast(m_params.arate) / m_params.fps; + const auto samples_per_frame = static_cast(m_params.arate) / 64; append_audio_impl(m_silence_buffer, static_cast(round(samples_per_frame))); } }