I'm learning to use normal maps (per pixel lighting?) in 2D graphics with OpenGL.
New to normal mapping, I managed to wrap my head around the Sobel operator and the generation of normal maps (mostly thanks to this), that is creating a (2D) array of normals from a (2D) array of pixel data.
(Most of the tutorials and forum threads that I have found were specific to 3D uses and modelling software. I aim to implement this functionality myself, in C++.)
- What do I do once I've got the normal map?
- Do I need to register it with OpenGL?
- Does it need to be associated with the texture, if yes, how is it done?
- How is it mapped to a 2D textured quad?
- (Is this something that I can do without shaders / GLSL?)