Guys the problem is that although I am getting all the images, the filename is not proper. I have searched thoroughly and found that you have to use %03d but when i use it I just get 000.jpg and 001.jpg. All images are rendering properly. Please advise. Since I dont know where the problem lies I am posting my whole code
int main(int argc, char* argv[])
{
//opening input file
FILE* inptr = fopen("card.raw", "rb");
if (inptr == NULL)
{
printf("Could not open card");
return 1;
}
//some declarations
uint8_t buffer[512];
int counter = 0;
char title[7];
FILE* outptr = NULL;