So the plan goes like this:
I have a rectangle that stretches from one side of the screen to the other (in width).And the height is 100.
The texture coords go like this:
So at my current resolution,the width of the rectangle would be 1280 and of course, 100 in height.
I'm trying to set this image as the texture to be used on that rectangle:
The problem is that the image gets very distorted! What is the solution? I tried tiling too,the same result,ugly distorsion!
Texture getting distorted
2 replies to this topic
Crossbones+ - Reputation: 2096
Posted 13 October 2012 - 06:20 AM
You have a square texture and you are rendering it on top of a rectangle with a large ratio between the two sides (1280:100). I would be very surprised if there was no distortion. You should change your texture coordinates so that several copies of the texture are inserted in that rectangle (you should also set your texture address mode to wrap). Your texture coordinates can be for example: