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

colorm: add DrawImageOptions.ColorScale #3188

Closed
11 tasks
hajimehoshi opened this issue Feb 1, 2025 · 1 comment
Closed
11 tasks

colorm: add DrawImageOptions.ColorScale #3188

hajimehoshi opened this issue Feb 1, 2025 · 1 comment

Comments

@hajimehoshi
Copy link
Owner

hajimehoshi commented Feb 1, 2025

Operating System

  • Windows
  • macOS
  • Linux
  • FreeBSD
  • OpenBSD
  • Android
  • iOS
  • Nintendo Switch
  • PlayStation 5
  • Xbox
  • Web Browsers

What feature would you like to be added?

A colorm.ColorM is for straight alpha colors while ebiten.ColorScale is for premultiplied alpha colors. If you want to apply a ColorScale value to colorm.ColorM, the calculation would be complicated (see the implementation of ColorM.ScaleWithColor). Let's introduce ColorM.ScaleWithColorScale for convenience.

EDIT: This was requested by @kazzmir.

EDIT: DrawImageOptions.ColorScale seems simpler and more straightforward.

Why is this needed?

No response

@hajimehoshi
Copy link
Owner Author

Another option is to add colorm.DrawImageOptions.ColorScale.

@hajimehoshi hajimehoshi changed the title colorm: add ColorM.ScaleWithColorScale colorm: add DrawImageOptions.ColorScale Feb 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant