Original Post
when compiling a shader on an x64 build of my code the following code generates the wrong values, but on x86 build it works fine: sm3.0, march 2009 SDK I've narrowed it down to the line float2 charloc = float2( character % 15, character / 15 ); If I upload the character % 15 from the CPU the code runs fine. Is there any known bugs on the X64 HLSL compiler or is there some other reason this would be screwing up?
uniform extern int character;
uniform extern float3 position;
uniform extern float2 texSize;
uniform extern float2 charSize;
uniform extern float4x4 wvpMatrix;
struct VSOut{
float4 hposition : POSITION0;
float2 texCoord : TEXCOORD0;
};
VSOut FontVS( float3 pos : POSITION0, float2 texCoord : TEXCOORD0 )
{
VSOut vsOut;
vsOut.hposition = mul( float4( position.xy + ( position.z * pos.xy ), 0.0f, 1.0f ), wvpMatrix );
float2 charloc = float2( character % 15, character / 15 );
vsOut.texCoord = texSize * charSize * ( charloc + texCoord );
return vsOut;
}