From 5a380485daa08043a380d2cc5e36cb375ad5786f Mon Sep 17 00:00:00 2001 From: Jonathan Thomas Date: Wed, 23 Nov 2022 14:01:43 -0600 Subject: [PATCH] Fixing whitespace --- src/FFmpegReader.cpp | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/src/FFmpegReader.cpp b/src/FFmpegReader.cpp index e46f03c6..30cbd4ee 100644 --- a/src/FFmpegReader.cpp +++ b/src/FFmpegReader.cpp @@ -1057,26 +1057,26 @@ std::shared_ptr FFmpegReader::ReadStream(int64_t requested_frame) { // Check if largest frame is still cached frame = final_cache.GetFrame(largest_frame_processed); - int samples_in_frame = Frame::GetSamplesPerFrame(requested_frame, info.fps, - info.sample_rate, info.channels); + int samples_in_frame = Frame::GetSamplesPerFrame(requested_frame, info.fps, + info.sample_rate, info.channels); if (frame) { // Copy and return the largest processed frame (assuming it was the last in the video file) - std::shared_ptr f = CreateFrame(largest_frame_processed); + std::shared_ptr f = CreateFrame(largest_frame_processed); - // Use solid color (if no image data found) - if (!frame->has_image_data) { - // Use solid black frame if no image data available - f->AddColor(info.width, info.height, "#000"); - } - // Silence audio data (if any), since we are repeating the last frame - frame->AddAudioSilence(samples_in_frame); + // Use solid color (if no image data found) + if (!frame->has_image_data) { + // Use solid black frame if no image data available + f->AddColor(info.width, info.height, "#000"); + } + // Silence audio data (if any), since we are repeating the last frame + frame->AddAudioSilence(samples_in_frame); return frame; } else { // The largest processed frame is no longer in cache, return a blank frame std::shared_ptr f = CreateFrame(largest_frame_processed); f->AddColor(info.width, info.height, "#000"); - f->AddAudioSilence(samples_in_frame); + f->AddAudioSilence(samples_in_frame); return f; } } @@ -1787,8 +1787,8 @@ void FFmpegReader::Seek(int64_t requested_frame) { if (requested_frame > info.video_length) requested_frame = info.video_length; if (requested_frame > largest_frame_processed && packet_status.end_of_file) { - // Not possible to search past largest_frame once EOF is reached (no more packets) - return; + // Not possible to search past largest_frame once EOF is reached (no more packets) + return; } // Debug output