Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

2D All the way! / How do you read the BMP file format?

Author
Message
Arkheii
20
Years of Service
User Offline
Joined: 15th Jun 2003
Location: QC, Philippines
Posted: 2nd Aug 2003 02:48
Can anyone explain to me the BMP file format? I need some sort of reader to return the rgb values of each pixel so that I can use it for matrix heightmaps, alphamaps, etc. Does anyone know of a tutorial or something?
IanM
Retired Moderator
21
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 2nd Aug 2003 02:55
You can go here : http://www.wotsit.org/

Alternatively, you can reverse-engineer this bitmap save code I wrote:

ReD_eYe
20
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 2nd Aug 2003 20:05
if you just want to get the colour values of each pixel
use load bitmap "filename",0 to load it to the screen
and then use point(x,y),rgbr(),rgbb() and rgbg() to extract the value, theres a very good tutorial on it for dbpro.

I have a website!!!
So go there: http://www.freewebs.com/darkb/index.htm
on second thought you probably shouldn't

Login to post a reply

Server time is: 2024-02-26 10:18:56
Your offset time is: 2024-02-26 10:18:56