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

enhancement: add custom max pixel length functionality #43

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

hidayahapriliansyah
Copy link

While using Thumbhash, I wanted to generate image thumbnails with very small file sizes, ideally less than 1KB. To achieve this, I needed the ability to set a custom maximum pixel length, such as 16 pixels. However, I found that Thumbhash currently enforces a default minimum pixel length of 32 pixels, which limits flexibility.

I made changes to the code to allow users to define their own custom maximum pixel length when generating thumbnails. This enhancement provides more control over the size of the thumbnails, making it possible to optimize them for smaller file sizes when needed. A demo of this updated functionality can be found here: https://thumbhash-generator.vercel.app/

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.

1 participant