why loading bars jump around instead of smoothly increasing percent?

639 viewsOtherTechnology

3%. 5%. 34%! 97%! 97… 98…

In: Technology

24 Answers

Anonymous 0 Comments

Because in most cases it’s impossible to predict how long some processes would take, especially when algorithm behind your progress bar tries to cover many cases. Copying tens of thousands small files is going to be very slow, copying one or two big files – fast, both cases are predictable. But now imagine user is copying some common data, which consists of big and small files in random order. It’s really hard to predict how long something would take, and generally not worth it. Like, if you want your program to be precise, you’ll need to first benchmark the media, SSD, HDD or whatever it is, then look up every file to read their size, then calculate the estimation. And that means reading every file at least twice, which is really inefficient and don’t worth the progress bar working steadily.

You are viewing 1 out of 24 answers, click here to view all answers.