I'm starting my journey into shader programming and In many respects I just don't quite know where to begin. I've opened up some HLSL shader files and messed around (with some success) but I feel like I'm blindly poking around in the dark. Does anyone have some good resources for learning HLSL and or GLSL? I've read a lot about the matrices involved (world space/object space/ tangent space) and now I'm wanting to dive in deeper.
I'm familiar with rendering assets in passes and comping them together in photoshop, however I don't fully understand what math is being used to put it all together. For instance, I know I need to use the "screen" blend in PS mode for reflections... but what is the screen mode doing and should I be mimicking that in a shader?
I know light is additive so I need to add the diffuse pass and the specular pass together with the ambient color so:
Diffuse pass = add to ambient/base
Spec pass = add to ambient/base
But what about the rest?
Reflection pass = ?
Shadow pass = ?
Glow/emissive pass = ?
Thanks in advance PCers!