Skip to content

如何实时绘制eraser, 对pen绘制内容进行擦除 #44

Answered by leaferjs
Nero0 asked this question in Q&A
Discussion options

You must be logged in to vote

抱歉,刚看到这个板块,之前一直关注的是issues。

这样设置才能擦除另外一支Pen的内容:

const eraser = new Pen({isEraser: true})

当在setStyle时设置,橡皮擦功能只会对当前的Pen有效, setStyle本质上是创建了一条子路径。

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by leaferjs
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