is a 16 bit normal map overkill for a 16 bit heightmap?
#1 Members - Reputation: 555
Posted 02 July 2012 - 05:33 AM
Im creating a heightmap from a 16 bit channel in a texture that came from a 16 bit per channel png image using the vertex shader. I was thinking that instead of using a seperate texture for the normal map I might as well put both the normal and height map in a single 16 bit per channel (64 bbp) png image. RGB would become the normal map and Alpha would be the height map. This would also greatly simplify the process of creating height and normal maps in photoshop using the nifty normal map plugin from nvidia. Using this way I also bind one less texture but I dont know how much of an advantage that is. I dont know if the end result will have any noticeble quality improvement.
Is this aproach fine or should i rather save the normal map in a seperate 8 bits per channel image.
Blood Tactics - Online first person shooter.........Frost TD - 3D tower defence game.
Spheres of Madness - 2D puzzle game...............Essence - Online Go (boardgame).
Descent - 2D top down shooter...........................Dragon Wars - Online turn based strategy game.
#2 Members - Reputation: 216
Posted 02 July 2012 - 11:27 AM
#3 Members - Reputation: 555
Posted 03 July 2012 - 01:58 AM
Edited by Wilhelm van Huyssteen, 03 July 2012 - 02:00 AM.
Blood Tactics - Online first person shooter.........Frost TD - 3D tower defence game.
Spheres of Madness - 2D puzzle game...............Essence - Online Go (boardgame).
Descent - 2D top down shooter...........................Dragon Wars - Online turn based strategy game.
#4 Moderators - Reputation: 13585
Posted 03 July 2012 - 03:09 AM
If you were really space concious, you could use an 8bit*4channel format and pack the normals into the R&G channels, and the height into the B&A channels.
If you've got a 2048^2 heightmap, that's 32MiB if using 4x16-bit channels. Dropping down to 8-bit channels saves you 16MiB, which may or may not be a lot of RAM depending on your target hardware.
Edited by Hodgman, 03 July 2012 - 03:19 AM.
#6 Members - Reputation: 555
Posted 04 July 2012 - 05:56 AM
Alternitively cant i just store the normal in 15 bits using 5 bits for each axis and let one bit go to waiste? or is that a bad idea.
Edited by Wilhelm van Huyssteen, 04 July 2012 - 06:18 AM.
Blood Tactics - Online first person shooter.........Frost TD - 3D tower defence game.
Spheres of Madness - 2D puzzle game...............Essence - Online Go (boardgame).
Descent - 2D top down shooter...........................Dragon Wars - Online turn based strategy game.
#7 Moderators - Reputation: 13585
Posted 04 July 2012 - 06:07 AM
Edited by Hodgman, 04 July 2012 - 06:11 AM.
#8 Members - Reputation: 555
Posted 04 July 2012 - 06:26 AM
cant i just store the normal in 15 bits using 5 bits for each axis and let one bit go to waiste? how would that compare to sperical normals
EDIT: this is probely a pretty stupid idea
.
Im going to go with the spherical normals idea wich seems perfect for my needs. Thnx a lot!
Edited by Wilhelm van Huyssteen, 04 July 2012 - 06:32 AM.
Blood Tactics - Online first person shooter.........Frost TD - 3D tower defence game.
Spheres of Madness - 2D puzzle game...............Essence - Online Go (boardgame).
Descent - 2D top down shooter...........................Dragon Wars - Online turn based strategy game.






