Is there a way to shift textures?

All development conversation and discussion takes place here

Moderator: Moderator

Post Reply
Message
Author
nate
Wyrmic
Posts: 261
Joined: Fri Jan 18, 2013 8:35 am

Is there a way to shift textures?

#1 Post by nate »

If I'm not mistaken, both toScreen and toScreenPrecise always draw the first texel at the first pixel-- that is, the 0,0 pixel of the texture gets drawn at the coordinates of the first and second argument sent to the drawing function.

I would like to draw a shifted texture, such that a different texel gets drawn at the upper left corner of the drawing box. This is mostly for working with tiling (repeating) textures.

Is there a way to do that?

While I'm asking texture questions, is there a way to draw a textured triangle rather than a textured rectangle?
Proud father of Fx4fx and Chronometer add-ons; proud mother of Fated add-on

Post Reply