Skip to content

Commit dc2dbb7

Browse files
committed
Temporarily disable steady ticks on progress bars
This fixes an issue where the fps and eta would not update until the very end of the encode. See also console-rs/indicatif#493
1 parent 03b8391 commit dc2dbb7

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

av1an-core/src/progress_bar.rs

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
use std::fmt::Write;
2-
use std::time::Duration;
32

43
use indicatif::{
54
HumanBytes, MultiProgress, ProgressBar, ProgressDrawTarget, ProgressState, ProgressStyle,
@@ -83,7 +82,7 @@ pub fn init_progress_bar(len: u64) {
8382
PROGRESS_BAR.get_or_init(|| ProgressBar::new(len).with_style(spinner_style()))
8483
};
8584
pb.set_draw_target(ProgressDrawTarget::stderr_with_hz(60));
86-
pb.enable_steady_tick(Duration::from_millis(100));
85+
// pb.enable_steady_tick(Duration::from_millis(100));
8786
pb.reset();
8887
pb.reset_eta();
8988
pb.reset_elapsed();
@@ -187,7 +186,7 @@ pub fn init_multi_progress_bar(len: u64, workers: usize, total_chunks: usize) {
187186

188187
let pb = ProgressBar::hidden();
189188
pb.set_style(pretty_progress_style());
190-
pb.enable_steady_tick(Duration::from_millis(100));
189+
// pb.enable_steady_tick(Duration::from_millis(100));
191190
pb.reset_elapsed();
192191
pb.reset_eta();
193192
pb.set_position(0);

0 commit comments

Comments
 (0)