I made shader that calculates RGB based on height. Height -> Map Range to 0-16777216 and result pixel based on where C is input number based on height:
B = C % 256
G = ((C-B)/256) % 256
R = ((C-B)/256**2) - G/256
Render result looks bad. Res: 5000x2900, tried cycles, evee, tga, openexr and all possible combinations i could think of. I'm not expecting render to look good, i just want file with correctly calculated pixels. Is there any way to achieve this with Blender? Any settings? Plugins?
Context: I'm working on isometric rpg. Need solution for hiding objects behind parts of pre-rendered background. Depth map is not good enough (greyscale) for big maps so I'm going with height map based on full rgb - similar to Pillars of Eternity. The problem is they did it in Maya (using mental ray) - am not familiar with this soft and I don't have it.