Thread: bmp tutorials

  1. #1
    Registered User
    Join Date
    Oct 2006
    New York

    bmp tutorials

    is there any good tutorials on programming C to read/write .Bmp format

  2. #2
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    I bet if you had put that into a search engine you'd have already gotten your answer.

    Hope is the first step on the road to disappointment.

  3. #3
    Dr Dipshi++ mike_g's Avatar
    Join Date
    Oct 2006
    On me hyperplane
    I mostly code in basic. I made a prog to pack BMPs into an exe all i really needed was this info: wikipedia windows BMP file format. Unfortunately I cant help you with file commands in C, havent used em yet myself.

  4. #4
    pwns nooblars
    Join Date
    Oct 2005
    Portland, Or
    Very easy to read and write to bmp, open the file in binary read mode, read in what you want, open another file in binary write mode and write it back out.

    Displaying the image is where it gets a little more tricky, for that you need to look into a library that can make a window and allow you to draw to it. Win32 (windows only), or wxWidgets are recommended such libraries.

  5. #5
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Have a look at's BMP format download:
    Also see's VGA BMP page:

    Finally, if you're not just reading and writing BMPs but also want to display them, you'll also need a graphics library. Besides what Wraithan mentioned, I believe the SDL and Allegro can load BMPs natively. I use the SDL myself.

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell

    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ:

    My website:
    Projects: codeform, xuni, atlantis, nort, etc.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. using basic library to write curve to bmp
    By CIO in forum C Programming
    Replies: 3
    Last Post: 02-21-2009, 02:25 PM
  2. Problem reading BMP
    By Mortissus in forum C Programming
    Replies: 4
    Last Post: 02-02-2006, 06:32 AM
  3. Strange problem with bmp
    By Victor in forum Linux Programming
    Replies: 2
    Last Post: 04-04-2005, 02:48 PM
  4. should update their tutorials.
    By PorkyChop in forum C++ Programming
    Replies: 17
    Last Post: 09-19-2004, 10:51 PM
  5. adding encryption to bmp
    By GiraffeMan in forum C Programming
    Replies: 10
    Last Post: 04-16-2002, 01:42 PM