Writing to a D3DFMT_R32F render target clamps to 1
- by Mike
I'm currently implementing a picking system.
I render some objects in a frame buffer, which has a render target, which has the D3DFMT_R32F format.
For each mesh, I set an integer constant evaluator, which is its material index.
My shader is simple: I output the position of each vertex, and for each pixel, I cast the material index in float, and…