Skip to content

How to "draw" with Sources? #2

Answered by Hartrik
fabkury asked this question in Q&A
Jan 31, 2024 · 1 comments · 2 replies
Discussion options

You must be logged in to vote

Hi. It's probably not well documented, but it's possible. There are hidden effect brushes that create a source when applied.

var fire = brush(130);
var sourceEffect = brush(243);  // 240-243

for (var x = 0; x < 10; x++) {
    canvas.set(50 + x, 50, fire);
    canvas.set(50 + x, 50, sourceEffect);
}

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@fabkury
Comment options

@Hartrik
Comment options

Answer selected by fabkury
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants