This repository has been archived by the owner on Sep 11, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 322
I'm no longer updating this package. #63
Comments
Thanks for everything, it just work for me ! I hope somebody will continue to maintain it... |
Thx. |
Why not open it up to the community? |
@nfnt thanks for your time, it's an awesome tool 😄 it's a pitty see you go |
A candidate for https://github.com/gofrs see gofrs/help-requests#3 |
As i had trouble finding examples using golang.org/x/image/draw to scale an image i cobbled together this basic example: // Scale will use the provided scaler to resize src to the bounds in rect
// It will always return an RGBA image
func Scale(src image.Image, rect image.Rectangle, scale draw.Scaler) image.Image {
dst := image.NewRGBA(rect)
scale.Scale(dst, rect, src, src.Bounds(), draw.Over, nil)
return dst
} Usage: scaled := Scale(src, image.Rect(0, 0, 200, 200), draw.ApproxBiLinear) full credit goes to this gist https://gist.github.com/logrusorgru/570d64fd6a051e0441014387b89286ca |
5 tasks
Open
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
As it may have been apparent by my long reaction time to PRs and issues, I haven't spend too much time working on this package in the last years. And I plan to keep it that way, hence I won't really look at PRs and issues anymore. Take a look at x/image/draw or gopkg.in/gographics/imagick.v2/imagick for packages that offer image resizing and much more.
The text was updated successfully, but these errors were encountered: