Skip to main content
Rashid Ellis's user avatar
Rashid Ellis's user avatar
Rashid Ellis's user avatar
Rashid Ellis
  • Member for 10 years, 11 months
  • Last seen more than 5 years ago
awarded
awarded
awarded
awarded
awarded
awarded
revised
Loading…
Loading…
comment
Directx: HLSL Texture based height map. (Shader 5.0)
@Krienie It's a multi-colored image, but I'm sampling from the red channel by default. In the event of grayscale,r=g=b --> height(scale).
comment
Directx: HLSL Texture based height map. (Shader 5.0)
@MooseBoys You're right, the texture was only bound to the Pixel Shader. Because of this, no amount of scaling, change would create usable values.
comment
Directx: HLSL Texture based height map. (Shader 5.0)
@KrienieThe texture was mapped from 0 to 1 across the span of the grid. I did this so that the grid's resolution is independent of the texture resolution. (Which is created by a function that takes resolution as a parameter.)
comment
Loading…
awarded
comment
Random number hlsl
MSDN gives intrinsic functions for HLSL, as well as the supported shader model. You can review the full range of functions at: msdn.microsoft.com/en-us/library/windows/desktop/…
accepted
answered
Loading…
awarded
comment
DirectX11: Drawing multiple objects
I didn't want to instance because the content of each vertex buffer was different. It was something simpler than the draw calls. I'm unsure how to refer to individual (indexed) vertex data in the index buffer... If I need to of course... and also confuzzled about how to wrap the data in a class for transforms. I thought about the cpu option, but my storage structures were in the heap and transforms would be called every single frame -or updated when changed... and it defeats the use of the GPU. :P