作者:海纳百川2602902033 | 来源:互联网 | 2023-08-16 19:35
Imtryingtomakeamosaicofandimagesclonethatisflippedandmirroredagainseachother.我正在尝
I'm trying to make a mosaic of and images clone that is flipped and mirrored agains each other.
我正在尝试制作一个马赛克和图像克隆,它们互相翻转和镜像。
But I can't get it to work properly. I have this JSFiddle: http://jsfiddle.net/arpo/yafLg7dc/
但我不能让它正常工作。我有这个JSFiddle:http://jsfiddle.net/arpo/yafLg7dc/
I want every second one flipped agains the first and so on.
我希望每一秒钟都会翻转第一个,依此类推。
But when I change to values to what I thought would do the trick the mosaic gets screwed up. Here's the values that I hoped should work but doesn't.
但是当我改变价值观时,我认为这样做会让马赛克搞砸了。这是我希望应该起作用但不起作用的价值观。
_drawImg(img, ctx, x1, y1, w, h, false, false);
_drawImg(img, ctx, x2, y1, w, h, true, false);
_drawImg(img, ctx, x1, y2, w, h, false, true);
_drawImg(img, ctx, x2, y2, w, h, true, true);
1 个解决方案