It may sound silly, but could someone give a definition of the following variables?
-ForegroundTexture
-BackgroundTexture
-SourceTexture
-PreviousTexture
It seems straight forward and self-explanatory, but sometimes I get unwanted results or can use whatever I want and get the same result (and not the one I intended). Please, don't laugh at me
The HLSL intrinsic functions list one called noise. If you look at the reference on msdn, it says that the function ist fully supported with shader model 2 and above. But when I try to use it I get an "cannot map expression..." error, if using a variable as input (noise takes a vector of any size as input). With values as input no error is raised, but the output value is always the same no matter what input values I use.
no error, but always the same output value:
a) noise(0.6f)
b) noise(float2(0.25, 0.5))
c) float nseed = 1000.6f
noise(nseed)
error message:
a) float nseed = Tex.x
noise(nseed)
b) float2 nseed = Tex.xy
noise(nseed)
c) float2 nseed = float2(Tex.x, Tex.y)
noise(nseed)
d) noise(tex.xy)
e) noise(float2(Tex.x, Tex.y))
The only thing I could find on the web was a thread on the msdn-forum, posted 2 years ago, where someone said:
"noise() is only supported for tx_x_0 profiles, i.e. software shader implemented by D3DX TextureFill functions."
I have no clue what this means, but the tx_x_0 profile restriction is only shown for shader model 1
Any ideas?
And if it comes to the point, that the perlin noise function is not usable, how can I setup my own random noise function?