-
Notifications
You must be signed in to change notification settings - Fork 562
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Show a more fine grained progress bar #3597
Conversation
depending on how long the last display ago was done. Also display at least every second. This should help users to recognise that the export is still ongoing when the ecoder is slow and the clip is long. Needs more fine tuning and a method that combines the output that is now done at various locations in the code
Emit final exported frame (with elapsed time) and seconds_run would not be set
the code easier to read
src/windows/export.py
Outdated
if afterpoint < 1: | ||
afterpoint = 1 | ||
if afterpoint > 5: | ||
afterpoint = 5 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What these "magical" numbers is about?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are the number of digits after the decimal point. Here they are set to a minimum of 1 and a maximum of 5. One was the previous default value 4.1f .
More than 5 doesn't make sense as in total this would be a higher precision than 7 digits. At 60 fps and 86400 seconds a day that would be 5,184,000 frames per day.
I have more of a problem with the maximum time between updates; I think 1 second is too low. 2 or 5 seconds might be better.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm against if (x < 20)
in the code when there is no comment why 20
was chosen here. Sometimes people like to make constants or variables that are much easier to modify later:
max_digits = 20; //max number of digits after the decimal point
if (x < max_digits) ...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK. I will make a change to this PR soon adding comments.
Today I might not have the time, soon.
Maybe also explain the calculation with the log10
@ferdnyc Could you please look at this. It shows the progress bar far more often updated for slow encoding runs. This is very helpful for slow computers and/or slow encoders. |
Thanks @eisneinechse. I would like to merge this one, but I would kindly request we update some of the new variable names (old_part, new_part), and do some code cleanup, comments, better variable names, etc... Otherwise I fear I'll never figure out what this stuff means in the future. 😄 Thx! |
LGTM! Thanks @eisneinechse |
The progress bar and the windows title of the export window are updated more often and the precision of the percentage shown is adjusted automatically so that during the export with slow encoders and/or long clips the feedback that the program isn't crashed is still there.