I am working on Frank Luna's DirectX 9.0c: A Shader Approach program, and I am stuck in Exercise 2 in Chapter 10. I have to calculate the float s value and pass it to the pixel shader so that I can calculate the "tone lighting". I understand the theory of how calculations work, but I cannot figure out how to pass a single float value from my vertex shader to a pixel shader. When I searched on MSDN, I found only semantics that allowed me to skip 3d vectors, etc.
It seems like I might need to somehow modify the input and output structure, but the exercises so far have not had any structures other than the "outputVS" structure.
In short, how do I transfer a single float value from my vertex shader to a pixel shader in HLSL?
Thanks in advance.
source
share