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

setting the alpha of an image #42

Open
1 of 2 tasks
KhafraDev opened this issue Feb 15, 2023 · 0 comments
Open
1 of 2 tasks

setting the alpha of an image #42

KhafraDev opened this issue Feb 15, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@KhafraDev
Copy link
Contributor

KhafraDev commented Feb 15, 2023

Search before asking

  • I searched in the issues and found nothing similar.

Motivation

Being able to set an image's alpha value (to make it partially transparent) would make it easier to create gifs on my end.

It could be used to create frames that fade out, overlap 2 images on top of each other without hiding the bottom image, etc.

Solution

with getrawpixels I could manually do it, but I have problems creating an image from a raw pixel buffer

Alternatives

with @napi-rs/canvas I can set the alpha and draw an image that way, and mix it with a package like @skyra/gifenc to create gifs.

Anything else?

No response

Are you willing to submit a PR?

  • I'm willing to submit a PR!

(my rust isn't good enough, sorry)

@KhafraDev KhafraDev added the enhancement New feature or request label Feb 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant