diff options
author | dec05eba <dec05eba@protonmail.com> | 2024-10-12 11:58:56 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2024-10-12 11:58:56 +0200 |
commit | a5895b775db0a139847a5cb75d8e3aea83af92da (patch) | |
tree | 682457e67bb07390b87347a795df421f98a48ab1 | |
parent | 2c4b077f437d41aba5269de3d5b9caf68ffdb279 (diff) |
appendum
-rw-r--r-- | src/main.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main.cpp b/src/main.cpp index 7b31074..f64450c 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -3791,7 +3791,7 @@ int main(int argc, char **argv) { const double frame_time = frame_end - frame_start; const bool frame_deadline_missed = frame_time > target_fps; - if(time_to_next_frame > 0.0 && !frame_deadline_missed) + if(time_to_next_frame > 0.0 && !frame_deadline_missed && frame_captured) av_usleep(time_to_next_frame * 1000.0 * 1000.0); else { if(paused) @@ -3800,7 +3800,7 @@ int main(int argc, char **argv) { {} else if(framerate_mode == FramerateMode::CONTENT || !frame_captured) av_usleep(2.8 * 1000.0); // 2.8 milliseconds - else if(!damaged) + else if(!frame_captured) av_usleep(1.0 * 1000.0); // 1 milliseconds wait_until_frame_time_elapsed = true; } |