This topic is now archived and is closed to further replies.

8-bit Bitmap palette index inconsistencies.

This topic is 5397 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I thought about posting this in a graphics-related forum, but i figured programmers would have the experience to help me out on this one. Im working on a terrain engine (isn''t everybody?) based off of a 256/grayscale bitmap heightmap. Note: Color black should be indexed as 0 and white as 255. The problem is that some maps appear way above the camera while other maps appear where it should be. Question #1 - I made some height maps with Photoshop and always saved them as grayscale. But with Paintbrush, i dont have that option, just a 256 color mode. Does this make a difference with the height values (color indeces)? Question #2 - I noticed that with smaller height maps, such as a simple 2 color image where theres only black and white, the value for black may be 0, but the value for white may be 1 (not 255). How can I ensure that white is always 255 and black is always 0...etc? I hope my questions are clear and precise. thanks.

Share this post

Link to post
Share on other sites