Jump to content

  • Log In with Google      Sign In   
  • Create Account

Mirror Texture


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 Danicco   Members   -  Reputation: 449

Like
0Likes
Like

Posted 26 August 2013 - 10:47 AM

What is the best/good way to deal with mirrored textures?

 

Most questions I've found about it suggest to either invert the texture pixels before uploading to the card, or invert the UV coordinates of it.

 

The problem with inverting the UV coordinates (the way I'm tempted to do) is that I would need to create the VBO for UVs x 4 for all textures I'm going to use to be able to adjust for: normal, vertical mirrored, horizontal mirrored, vertical and horizontal mirrored. (I can use the same VBO but it's still UVs count x 4)

 

At first I thought I could just invert the order I draw the vertices of my quad but it didn't work, is there an elegant way to deal with this?



Sponsor:

#2 Dave Hunt   Crossbones+   -  Reputation: 2457

Like
0Likes
Like

Posted 26 August 2013 - 11:07 AM

In most cases it's best to invert the texture pixels when loading. That way everything else stays consistent.

 

Or save your textures the way you want them in the first place...



#3 3TATUK2   Members   -  Reputation: 730

Like
0Likes
Like

Posted 29 August 2013 - 08:03 PM

scale the projection matrix by -1 on the axis you want flipped






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS