文档上没有canvas 'source-in',但真机上渲染正常,是否说明可用?
发布于 5 年前 作者 leilong 12931 次浏览 来自 问答

https://developers.weixin.qq.com/miniprogram/dev/api/CanvasContext.html 文档上写着:

在绘制新形状时应用的合成操作的类型。目前安卓版本只适用于 fill 填充块的合成,用于 stroke 线段的合成效果都是 source-over

目前支持的操作有

  • 安卓:xor, source-over, source-atop, destination-out, lighter, overlay, darken, lighten, hard-light

  • iOS:xor, source-over, source-atop, destination-over, destination-out, lighter, multiply, overlay, darken, lighten, color-dodge, color-burn, hard-light, soft-light, difference, exclusion, saturation, luminosity

文档上未出现 source-in,但在 5S 和 华为 P9 真机和微信开发者工具均渲染正常,那是否说明其他机型也可以正确渲染?

1 回复

建议以文档为准

回到顶部