CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2

Threaded View

  1. #1
    Join Date
    Jun 2002
    Posts
    16

    Unhappy i just don't know whats wrong with bmp app

    i'm using Dev-C++ 4.

    it will compile and i can run the program, however the bmp is not viewable in the preview app. You can open the bmp file in paint.
    although its not the intended output for the bitmap, its an error. i've been tying to get this to work for at least a month and i just don't know how to fix this. the jist of the app is that you have an input.txt file with a many ones and zeros and the app will turn it into a bitmap by
    asking you what color you want for the zeros (red, green, blue) then it will ask what color do you want for the ones (red, green, blue) now its going to ask if you want to compress the ones and zeros you enter in the number of ones and zeros in a row you want compressed and the colors that will represent the compressed bits then it opens the txt file and calculates the needed width and height of the bitmap. after that it closes and reopens the txt file and reads it and writes the ones and zeros to the bitmap. closes the txt fille and outputs the bitmap.

    this project has 'testcompression.cpp' and 'bitmap.cpp' in it using 'bitmap.h', 'iostream.h', 'stdlib.h', and 'fstream.h'. The two files begining with bitmap are found at http://www.csse.monash.edu.au/~tonyj/raytracing/ the only thing i modified was putting " ios::trunc |" infront of " ios:ut" on line 56 of 'bitmap.cpp'.

    thanks in advance
    Attached Files Attached Files
    logical coding for functional programs

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured