: some one do help me.... i need to save the picture on my
: Paintbrush(which i made using C in BGI mode) drawing area to a
: file.. can anyone help me in that????
: it is very urgent...
: i think we have to do it pixell by pixel...but how to do it???//
Yes, it is useually done pixel by pixel (or looped memcpy()'s),
but this depends on the current video mode in order to copy
If you already have the image in memory, just write it to a file
following the file format you want to use (or just dump it as
a raw image) ...A simple fwrite() (or fstream::write() will do the
Or, if its really *That* urgent, with the program running press
ctrl+prtscr (or alt+prtscr), Open an image editing program and paste
btw, there is no "C BGI Mode". BGI is a Borland extension
for support of graphics, and is Borland specific.
I dont use BGI as it being old and nonportable.