Greyscale in Raw-format doesn't control heightmap properly (5.6.3f1)
Hello!
I'm trying to import a raw heightmap into my scene. My goal is to have the 0 level of the terrain at 20m y+, so that I can have up to 20m depths in my terrain. From 20m y+ I'd like to have 5 more meters upwards, so 25m Terrain height (see settings, 1st screenshot) on the whole.
However I tried to control this by using a heightmap. So I should get 25 for a 100% value and 0m for a 0% value. This works for the absolute height of 25m as well as for the absolut depth of 0m.
But it seems like as if all the values in between are offsetted. On the 2nd screenshot you can see the absolute height of the terrain on the right (25m) and and the 20m height on the left.
80% value (25*0,8=20m) in my original PS file (res. 1025*1025).
exported it from PS in 16bit greyscale format as a raw file (windows pc byte order)
imported it in Unity as heightmap with same settings (Terrain scale is 250x25x250)
Why is there a 1.31m difference to where I expect the 20m level to be? Shouldn't 80% value be equal to 20m in this example?
When I reimport the raw file to photoshop it only has 8bit and seems to be compressed (it has artifacts).
I hope you understand my issue with the settings + screenshots attached below.
I thought it should be possible to have absolute control about heights with the greyvalues of the heightmap. Don't know if I made a mistake somewhere in my settings..
[2]: /storage/temp/109820-screenshot-2018-01-22-233634.png
Your answer
Follow this Question
Related Questions
Checking if ground is flat with GetHeights() 0 Answers
How to detect surrounding terrain height for minimap (comparable to a sonar) 0 Answers
Heightmaps, Raw files, and Photoshop 0 Answers
unity terrain apply texture by altitude 0 Answers
I cant import my heightmap because the resolution is not a power of two? 0 Answers