Skip to main content
gamedev.net
🔒 Locked

Texture question

Started by Zmax Sep 12, 2005 at 3:25 AM 1 replies 750+ views
Original Post
Zmax
Zmax
It is possible to place the texture on a shape the has more than 4 vertexes?How? I'm asking that because i loaded a HeightMap from a picture file and textured it so: 4 neighbour vertexes share one texture.It is not textured nice because i would like to place the texture over more than 4 vertexes... This is how the heightMap texturind looks in my project: 00 10 00 10 01 11 01 11 00 10 00 10 01 11 01 11 00 10 00 10 01 11 01 11 .... . . . I tryed to texture so: 00 x x x x x 10 x x x x x 01 x x x x x 11 but i don't know how...can anybody help me
Satook
Satook
if you use coordinates above 1 it should wrap the values for you. This would mean you can go, horizontally:
0,0 1,0 2,0 3,0 4,0 xxxx 29,0
0,1 1,1 2,1 3,1 4,1 xxxx 29,1
etc

Try it and see how it goes. If you just want to stretch the texture, use fractions instead. Divide each coord by width/height to get how far across the texture.

Hope it helps,
Andrew
What''s a cleaver?
Zmax
Zmax
Thanx :) i got it,...it looks better now :)

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.