Enforce 10 FPS encoding frame rate floor to improve static image quality (#754)

This commit is contained in:
Cameron Gutman 2023-01-11 10:02:53 -06:00 committed by GitHub
parent 43d47c6f3c
commit 696a11942c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1134,14 +1134,12 @@ void encode_run(
idr_events->pop();
}
// Encode at a minimum of 10 FPS to avoid image quality issues with static content
if(!frame->key_frame || images->peek()) {
if(auto img = images->pop(100ms)) {
session->device->convert(*img);
}
else if(images->running()) {
continue;
}
else {
else if(!images->running()) {
break;
}
}