mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-11 11:21:16 +02:00
Fix
This commit is contained in:
+2
-2
@@ -127,8 +127,8 @@ module.exports = class CanvasUtil {
|
||||
|
||||
static motionBlur(ctx, image, x, y, width, height) {
|
||||
ctx.drawImage(image, x, y, width, height);
|
||||
ctx.globalAlpha = 0.1;
|
||||
for (let i = 0; i < 10; ++i) ctx.drawImage(image, x + i, y, width, height);
|
||||
ctx.globalAlpha = 0.2;
|
||||
for (let i = 0; i < 10; i += 2) ctx.drawImage(image, x + i, y, width, height);
|
||||
ctx.globalAlpha = 1;
|
||||
return ctx;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user