Archived

This topic is now archived and is closed to further replies.

RaphaelMun

1D Texture Coordinate Problem

Recommended Posts

RaphaelMun    122
Okay, so what happens is I load a 4 x 1 texture and it works fine on one computer using 2d coordinates where v = 0, but it won''t work right on another computer and rather just uses 0,0 for the u-v''s. The coordinates seem to sort of work when I have the texture in a square 4x4 or 16x16 or whatever, but then the texture also doesn''t show up right. (This is for cel-shading btw) Is this a hardware mismatch that can''t use u-v coordinates for textures that don''t have equal dimensions? Is there some way to fix this? Thank you!

Share this post


Link to post
Share on other sites
Muhammad Haggag    1358
- Some hardware/drivers can''t handle textures that don''t have power-of-two dimensions. These hardware would - hypothetically, I''ve not actually used non-pow2 textures on such hardware - either fail texture creation (most probably) or do bogus texturing.

- Some hardware/drivers support only square textures. Again, on such hardware, you''ll either get failure or bogus texturing.

- You can check for support of pow2 textures and square textures using the caps (don''t remember the exactcaps bits, though)

- I think this doesn''t apply here, but why don''t you try biasing your u''s a little?.

Sorry if it wasn''t much help

Muhammad Haggag

Share this post


Link to post
Share on other sites
RaphaelMun    122
Okay, been testing out different stuff for about 4 days now since I''ve gotten this problem. More testing today with square textures and different pow-2 sizes but it''s doing something weird. I can''t figure out whether it''s the texture loading that''s being goofy or the the drawprimitive not using the texture coordinates right. I use D3DXCreateTextureFromFileEx with 1 filter level and 0 mipmaps but I don''t see how the loading function would have much of a problem with all of this...
It looks something like this right now:



The problem is that the computer doesn''t seem to be recognizing 0,0 nor 1,0 uv coordinates. The texture itself is a threshold grayscale from dark to light. Has anyone encountered something like this before with texturing problems? The texture loads fine, that''s for sure, lol. Thanks!

Share this post


Link to post
Share on other sites