I've created this program as a part of a project 'Image Enhancer'. This Program can be used to check whether the given file is a valid BMP file or not. Just compile the source code and enter the absolute file path in the prompt. (Ex-c:\test\text.bmp)
//Checking and validation of an BMP ImageFile
#include<>
#include<>
#include<>
#include<>
#include<>
#include<>
#include<>
#define BMPTYPE (((WORD) 'M' << must="="'BM'" ex="c:\tc\text.bmp):" length =" strlen(inname);" i =" 0;">= 'a') && (inname[i] <= 'z')){
inname[i] = toupper(inname[i]);
}
}
//fpath=inname;
FILE *infp;
//strcpy( inname, argv[1]);
infp = fopen( inname, "r");
if( ! infp)
{
printf("\n Unable to open %s for input\n", inname);
printf("Try again..");
getch();
//main();
// exit(1);
}
printf("Verifying file....");
delay(1000);
bmp(infp);
fclose(infp);
printf("\nPress any key to exit\n");
getch();
// exit(0);
}
Thursday, April 2, 2009
Subscribe to:
Posts (Atom)
Popular Posts
-
1. Open the Firefox “config” page: click into the Firefox address location bar, and type about:config , press Enter. 2. Search the line br...
-
Holograms have long been a staple of science fiction, but in recent years, they’ve become more of a reality than ever before. Thanks to adva...
-
In PHP there are so many ways to perform the same task. Normally developers are using the way which is most comfortable for them or which ...
-
Some times when you connect to the webhost via FileZilla you may encounter this error message. "421 Sorry, cleartext sessions are ...
-
When we are pulling date from the server having UTC, it may display in local timezone format in Arshaw's Full Calendar . This is due...
-
1. The Menu menu This another great CSS menu Stu Nicholls that’s unique – hovering over a menu item reveals a submenu. If you want get...
-
Wordpress WP E-Commerce Plugin, There is a widget called Product Category Widget which lists all the product categories. During the site d...
-
This only applies to cars that can be unlocked by remote control. Should you lock your keys in the car and the spare keys are home. If some ...
-
I'm now using Windows 7 the new Windows OS which is working fine with my PC. It was a long time i had installed Turbo C++ in my system. ...
-
Q: Can I start my own company on oDesk? A: Yes! oDesk allows you to build and manage a team of workers, colleagues and collaborators. Yo...