You don't deform the texture - you rotate the object that the texture is applied to. Perspective means that the object (and therefore the texture applied to the object) will appear narrower at the top of the screen than it does at the bottom, for example.
For your purposes you need to rotate it on the X axis. Use cursor up/down in the above code to demonstrate the effect.
For your purposes you need to rotate it on the X axis. Use cursor up/down in the above code to demonstrate the effect.