-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
feat: Support alpha colors with Text stroke #10800
Conversation
* feat: add ShaderSystem#maxTextures * use gpu.device.limits.maxSampledTexturesPerShaderStage --------- Co-authored-by: Zyie <24736175+Zyie@users.noreply.github.com>
* feat: reserve texture units for batching * maxTextures instead of reservedTextures --------- Co-authored-by: Zyie <24736175+Zyie@users.noreply.github.com>
* feat: add 'min' and 'max' blend modes * Add visual tests * Fix variable name * replace webgl2 test --------- Co-authored-by: Zyie <24736175+Zyie@users.noreply.github.com>
* add a renderable GC * lint * oops * fix nineslice destroy * fix up PR * tweak times for tests * Update package.json * remove unneeded extension.add call in TextureGCSystem and RenderableGCSystem --------- Co-authored-by: Zyie <24736175+Zyie@users.noreply.github.com>
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit 5dcd748:
|
9c9b4eb
to
23656bd
Compare
@@ -14,7 +14,7 @@ export function getCanvasFillStyle( | |||
{ | |||
if (fillStyle.texture === Texture.WHITE && !fillStyle.fill) | |||
{ | |||
return Color.shared.setValue(fillStyle.color).toHex(); | |||
return Color.shared.setValue(fillStyle.color).setAlpha(fillStyle.alpha ?? 1).toHexa(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From types, If there is HEXA fillStyle.color
but no fillStyle.alpha
, isn't opacity always will be 1
?
Fixes #10798
This fixes support on stroke for both #RRGGBBAA colors and alpha property uses.
Broken (v8.2.5)
https://jsfiddle.net/bigtimebuddy/gy7dw8mh/
https://jsfiddle.net/bigtimebuddy/gw2vbnc7/
Fixed (PR)
https://jsfiddle.net/bigtimebuddy/b6uztmjd/
https://jsfiddle.net/bigtimebuddy/t3h476x8/