Could someone help me figure out why a float3 is being returned in the following HLSL line?
float3 v = gRandomTex.SampleLevel(gTriLinearSam, u, 0);
Now, gRandomTex, gTriLinearSam and u are defined as follows:
Texture1D gRandomTex;
SamplerState gTriLinearSam
{
Filter = MIN_MAG_MIP_LINEAR;
AddressU = WRAP;
AddressV = WRAP;
}
float u = 1.0f; //Actually it is not a constant, but just for the example, I set it to 1.0f