Content originally posted in LPCWare by borla.ramesh@gmail.com on Fri Feb 14 22:47:16 MST 2014
hi iam doing image processing with NXP LPC1768. for this iam reading a .bmp image and storing pixels in a file. but unfortunately the file is not creating when iam executing the code..
code is:::::::::
#include<stdio.h>
FILE *fp,*fp1;
int main()
{
unsigned int ch;
fp1=fopen("lena3.txt","w"); //output file
fp=fopen("lena.bmp","r"); /// source file
while((ch=fgetc(fp))!=EOF)
{
fprintf(fp1,"%.2x,",ch);
}
fclose(fp1);
fclose(fp);
//printf("%x",ch);
return 0;
}
while compiling the code it's showing :
no errors no warnings
but file is not creating in the project execution folder
please help me on this
thanq in advance