Issue 14621 in skia: CanvasKit: add support for Blender API

3 views
Skip to first unread message

johns… via monorail

unread,
Jul 14, 2023, 9:02:11 AM7/14/23
to bu...@skia.org
Status: Accepted
Owner: brian...@google.com
CC: kjlu...@google.com
Area: CanvasKit
Priority: Medium
Type: Feature

New issue 14621 by johns...@google.com: CanvasKit: add support for Blender API
https://bugs.chromium.org/p/skia/issues/detail?id=14621

The CanvasKit API was never updated to add support for Blender-based APIs. We need to add support for SkBlender, SkPaint::setBlender, and SkBlendImageFilter.

--
You received this message because:
1. The project was configured to send all issue notifications to this address

You may adjust your notification preferences at:
https://bugs.chromium.org/hosting/settings

satco… via monorail

unread,
Jul 21, 2023, 1:06:46 PM7/21/23
to bu...@skia.org

Comment #1 on issue 14621 by satco...@gmail.com: CanvasKit: add support for Blender API
https://bugs.chromium.org/p/skia/issues/detail?id=14621#c1

I am working on SkBlender, SkPaint::setBlender except SkBlendImageFilter.
727676: Add Blender of RuntimeEffect to canvaskit | https://skia-review.googlesource.com/c/skia/+/727676

Git Watcher via monorail

unread,
Jul 21, 2023, 5:57:09 PM7/21/23
to bu...@skia.org

Comment #2 on issue 14621 by Git Watcher: CanvasKit: add support for Blender API
https://bugs.chromium.org/p/skia/issues/detail?id=14621#c2

The following revision refers to this bug:
https://skia.googlesource.com/skia/+/fbaad71dad8a7abfa20389328b5c39c649ac9ffb

commit fbaad71dad8a7abfa20389328b5c39c649ac9ffb
Author: bigfood <satco...@hanmail.net>
Date: Fri Jul 21 21:04:34 2023


Add Blender of RuntimeEffect to canvaskit

I'm new to skia, also new to cpp. So I think a thorough review will be needed.

# What I did
## Added
- `Paint.setBlender` Sets the current blender.
- `Blender.Mode` Create a blender that implements the specified BlendMode.
- `RuntimeEffect.MakeForBlender` Compiles a RuntimeEffect from the given blender code.

Bug: skia:14621
Related Discuss: https://groups.google.com/g/skia-discuss/c/6QdgoxoYnv8
Change-Id: Ib77c4e5d21fe85764b762eefdbbf7b9c8c863f22
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/727676
Reviewed-by: Brian Osman <brian...@google.com>
Commit-Queue: Brian Osman <brian...@google.com>

[modify] https://crrev.com/fbaad71dad8a7abfa20389328b5c39c649ac9ffb/modules/canvaskit/tests/rtshader_test.js
[modify] https://crrev.com/fbaad71dad8a7abfa20389328b5c39c649ac9ffb/modules/canvaskit/externs.js
[modify] https://crrev.com/fbaad71dad8a7abfa20389328b5c39c649ac9ffb/modules/canvaskit/rt_shader.js
[modify] https://crrev.com/fbaad71dad8a7abfa20389328b5c39c649ac9ffb/modules/canvaskit/CHANGELOG.md
[modify] https://crrev.com/fbaad71dad8a7abfa20389328b5c39c649ac9ffb/modules/canvaskit/npm_build/types/index.d.ts
[modify] https://crrev.com/fbaad71dad8a7abfa20389328b5c39c649ac9ffb/AUTHORS
[modify] https://crrev.com/fbaad71dad8a7abfa20389328b5c39c649ac9ffb/modules/canvaskit/canvaskit_bindings.cpp

brian… via monorail

unread,
Jul 24, 2023, 2:55:04 PM7/24/23
to bu...@skia.org
Updates:
Status: Fixed

Comment #3 on issue 14621 by brian...@google.com: CanvasKit: add support for Blender API
https://bugs.chromium.org/p/skia/issues/detail?id=14621#c3

(No comment was entered for this change.)

johns… via monorail

unread,
Jul 24, 2023, 4:53:31 PM7/24/23
to bu...@skia.org

Comment #4 on issue 14621 by johns...@google.com: CanvasKit: add support for Blender API
https://bugs.chromium.org/p/skia/issues/detail?id=14621#c4

We still don't support `SkBlendImageFilter` in CK; should we cut a separate bug for this, or just let it go until someone requests it?

brian… via monorail

unread,
Jul 25, 2023, 9:45:28 AM7/25/23
to bu...@skia.org

Comment #5 on issue 14621 by brian...@google.com: CanvasKit: add support for Blender API
https://bugs.chromium.org/p/skia/issues/detail?id=14621#c5

I think we can wait. (There are a bunch of other APIs that are missing from CK, I think. I need to do a good inventory).
Reply all
Reply to author
Forward
0 new messages