Does anyone have or know of a tool for combining a height or displacement map with a normal map? Specifically, I want to take the height and set it as the alpha channel in the normal map.
I am currently doing that manually via GIMP, and it’s a pretty painful process.
I had a similar situation where I wanted to merge the intensity from 4 textures (let’s say the R channel but really all RGB values were the same) into the RGBA values of a single texture. I used an image editing app for this which wasn’t ideal (especially handling the Alpha channel).
Recently I wrote an importer to do that automatically.
It would be easy to convert it to your needs and combine the RBG (normal) from the first texture and the R (height ) from the second texture into the Alpha channel.
I think you can have a quick hack to do what you want within a day.
Use the sample project to test your results visually. (Samples.SLMC.WINDOWS.MG)
(at the moment it doesn’t show the alpha channel )
The idea about using the matrix is in my plans whenever I find the time.