We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Does this library support resize images?
The text was updated successfully, but these errors were encountered:
DecodeRGBA will return an *image.RGBA which can be resized using the standard draw package golang.org/x/image/draw.
DecodeRGBA
*image.RGBA
draw
golang.org/x/image/draw
The following should work:
m, err := webp.DecodeRGBA((data) if err != nil { log.Fatal(err) } width := 100 height := 200 scale := draw.BiLinear rect := image.Rect(0, 0, width, height) dst := image.NewRGBA(rect) scale.Scale(dst, rect, m, src.Bounds(), draw.Over, nil)
Sorry, something went wrong.
No branches or pull requests
Does this library support resize images?
The text was updated successfully, but these errors were encountered: