Go Back   CodingForums.com > :: Computing & Sciences > Computer Programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 12-24-2002, 11:38 PM   PM User | #1
Josh Campbell
New Coder

 
Join Date: Jun 2002
Posts: 66
Thanks: 0
Thanked 0 Times in 0 Posts
Josh Campbell is an unknown quantity at this point
Reading Bmps in C

I am going to try to make a program that converts a bitmap into a format suitable for the gba.

My big problem is how to read a .bmp file into my C program. I am not sure how they are formatted and how I would go about reading them in since i think they are binary, and not text.

Thanks
Josh Campbell is offline   Reply With Quote
Old 12-25-2002, 08:45 AM   PM User | #2
codefox
Regular Coder

 
Join Date: Nov 2002
Location: India
Posts: 159
Thanks: 0
Thanked 0 Times in 0 Posts
codefox is an unknown quantity at this point
You can find details regarding bitmaps and reading bmp files in c here: http://www.brackeen.com/home/vga/bitmaps.html
codefox is offline   Reply With Quote
Old 10-07-2009, 09:15 AM   PM User | #3
semperaltus
New to the CF scene

 
Join Date: Oct 2009
Location: Bucharest, Romania
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
semperaltus is an unknown quantity at this point
Hello,

thou i see this post its 7 years old, i think i am trying to make same thing as Josh Campbell.
i am trying to make a c program that reads .bmp files and then create them in a format i can use for my DS application .

for start i am having problems even at the reading the bitmap . thou i think i only need to read the rgb from the bitmap and put that in a file , and then use it for DS , because i will be using only 1 type of bmps and with certain size .

do you have anything that could put me on the right track ?

Thank you
semperaltus is offline   Reply With Quote
Old 10-07-2009, 03:26 PM   PM User | #4
Josh Campbell
New Coder

 
Join Date: Jun 2002
Posts: 66
Thanks: 0
Thanked 0 Times in 0 Posts
Josh Campbell is an unknown quantity at this point
I have no experience with the DS, and I stopped working with the GBA shortly before the DS came out.

Some resources that might be helpful:
  • gbadev - I've heard that the DS is very similar to the GBA, so maybe some of the graphics tools they have will prove useful. Also have forums devoted to the DS.
  • FreeImage - I've used it before. Makes loading/saving image files really easy. Supports a bunch of formats, too.
Josh Campbell is offline   Reply With Quote
Old 10-07-2009, 05:23 PM   PM User | #5
oesxyl
Master Coder


 
Join Date: Dec 2007
Posts: 6,682
Thanks: 436
Thanked 890 Times in 879 Posts
oesxyl is a jewel in the roughoesxyl is a jewel in the roughoesxyl is a jewel in the rough
I guess you can add this to your resources:

http://www.imagemagick.org/script/index.php

the library can be linked with any program you write and provide reading/writing and manipulation of different formats.
There also have bindings for other languages in case you need.

best regards
oesxyl is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 11:32 PM.


Advertisement
Log in to turn off these ads.