Skip to content
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

Halve framerate and dimension if they are big #31

Merged
merged 4 commits into from
Jun 12, 2018
Merged

Conversation

LarsJK
Copy link
Contributor

@LarsJK LarsJK commented Mar 19, 2018

We already clamp the framerate to 5-30. Do wee need to also halve it? If so should the halving be based on the clamped value, or the original value then clamped to 5-30..?

closes #28

@LarsJK
Copy link
Contributor Author

LarsJK commented Mar 20, 2018

Maybe its better if we instead of halving, used 24 fps and 640 width as standard if the video is bigger..?

@kornelski
Copy link
Collaborator

I'd suggest halve first, then cap. Halving (or dividing by integer in general) gives the best quality -- smoothest animation and nicest scaling.

GIF can only express framerates as 100/n, and most screens can play only 60/n, so 10 and 20fps are the best framerates for GIF.

Uneven framerate scaling causes judder: https://en.wikipedia.org/wiki/Three-two_pull_down

@sindresorhus
Copy link
Owner

@LarsJK Are you still interested in finishing this? No worries if you don't have time right now.

@LarsJK
Copy link
Contributor Author

LarsJK commented May 15, 2018

@sindresorhus Yeah I can finish this.
Do you have any suggestions for the scale slider? See #28 and @kornelski 's comment on #25

I tried implementing a ticked slider but it it didn't look very good. Too many ticks and probably need to do something about the styling to make it work better with the dark background.

image

@sindresorhus
Copy link
Owner

My idea is that we use a normal slider, but have a list of predefined sizes, like commented in #25 (comment). So let's say if we had 4 predefined sizes, when the slider is at 0%, it would pick the first, when it's at 20% it would still pick the first, when at 26% it would pick the second, and when at 76% it would pick the last element. So we just spread the elements evenly out. So it's like a tick slider without the ticks.

@sindresorhus
Copy link
Owner

I also think we should revert the open/save dialog to be non-dark. It looked cool at first, but it's clearly not designed to be dark and there are a lot of weird visual bugs.

@sindresorhus
Copy link
Owner

We could also maybe make the text on the right-side of the slider a text field instead, for the perfectionists that want an exact size more easily.

@LarsJK
Copy link
Contributor Author

LarsJK commented Jun 2, 2018

I also think we should revert the open/save dialog to be non-dark. It looked cool at first, but it's clearly not designed to be dark and there are a lot of weird visual bugs.

@sindresorhus 🤞Real dark mode support announce next week

@sindresorhus
Copy link
Owner

sindresorhus commented Jun 6, 2018

🤞Real dark mode support announce next week

We got it!!!!!!!

@sindresorhus
Copy link
Owner

I also think we should revert the open/save dialog to be non-dark. It looked cool at first, but it's clearly not designed to be dark and there are a lot of weird visual bugs.

Done in 2894888

@LarsJK
Copy link
Contributor Author

LarsJK commented Jun 9, 2018

@sindresorhus I simplified the code a bit, and changed the minimum scale so that it will allow you to scale the GIF down to 10x10 independent of the input size..

I'm struggling to find a good way to use predefined size and a slider. Do you prefer a slider or could we do a dropdown like preview:

preview

The preset that give the best quality (1/n scaling) can be marked with "best quality" or something like that..

Maybe we should merge this to get better defaults and figure out the way to handle predefines in another PR?

@sindresorhus
Copy link
Owner

Maybe we should merge this to get better defaults and figure out the way to handle predefines in another PR?

👍 Can you open an issue about the remaining things we need to change? Like slider=>dropdown.

@sindresorhus sindresorhus merged commit 6704119 into master Jun 12, 2018
@sindresorhus sindresorhus deleted the better-defaults branch June 12, 2018 14:06
@sindresorhus
Copy link
Owner

This looks great :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

File size and frame rate defaults
3 participants