DirectX 11 C++ How to rotate a texture coordinate along a point?

674 Views Asked by At

I'm trying to make a whirling effect where the screen is rotating along the center point.

So the end result would be a whirlpool continuously spinning with the center of the screen being the focal point.

I tried to rotate the texture coordinate in the vertex shader by XMMatrixRotationZ, but it rotates the whole screen obviously.

I need to rotate around the center point (0.5, 0.5) but unsure how to go about it.

0

There are 0 best solutions below