cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

tdgeorge
Journeyman III

TXB shader assembly instruction appears to not work with Radeon HD cards

Hi,

I have been trying to use the TXB shader assembly instruction so that I can bias the LOD of a texture from the shader but the instruction appears to act exactly like the TEX instruction.  Is TXB supported by Radeon HD 3XXX and 4XXX cards?

The sample shader acts the same whether it is using TXB or TEX as the texture read instruction.

Pixel Shader

!!ARBfp1.0

ATTRIB inColor = fragment.color.primary;

ATTRIB texcoord0 = fragment.texcoord[0];

TEMP texel,temp;

MOV temp, texcoord0;

MOV temp.w, 10.0;

MOV temp.z, 0.0;

TXB texel, temp, texture[0], 2D;

MOV result.color, texel;

END

 

Thanks,

 



0 Likes
2 Replies
pboudier
Staff

it is supported on all our cards, yes.

I assume that your texture had 10 mip levels ?

Pierre B.

0 Likes

No the texture only had 6 mip levels but it didn't matter what value (0.0-10.0) I passed to temp.w it always gave the same image as when I used TEX.

 

0 Likes