-
Notifications
You must be signed in to change notification settings - Fork 37
Description
Transforming the wgpu Canvas using CSS transform with perspective and rotateX or rotateY results in a very strange behaviour. It seems as if the View below it in terms of layers starts having priority in blending, but only for the part that should seem farther away.
Here's the link for the minimal reproduction repo that I made
If you want to take a quick look you can see how it behaves in a bit more complex reproduction, with the View transformed to showcase the problem in another way (behaves the same, but looks a bit less clear).
The first one has absolutely positioned View below the canvas, but you can see that weird behaviour in the second example more clearly (the only change is the background color of the View that contains both). I changed the colors so the alpha was less than 1.0 - in that way you can clearly see what happens in terms of blending. You can also change the alpha in the minimal reproduction if you want to test it out.
I also have to say that this behaviour is present only on iOS - the android version behaves even weirder - Canvas looks as if it were skewed in X and Y directions, and the origin of the canvas (0,0) is transformed with the skewing.