Hi,
I have problem with copy the bitmap* to char* using memcpy.
Here I given my code,
char* cbuffer;
int size = 240000;
Bitmap *bitmap = new Bitmap(L"Image. bmp");
bitmap->Rotate(RotateN oneFlipX);
memcpy(cbuffer, bitmap,size);
FILE *fptr;
fptr = fopen("image2.b mp","wb");
fwrite(cbuffer, 1,size,fptr);
fclose(fptr);
In My above code, the image2.bmp has not saving.
What is the problem?
I have problem with copy the bitmap* to char* using memcpy.
Here I given my code,
char* cbuffer;
int size = 240000;
Bitmap *bitmap = new Bitmap(L"Image. bmp");
bitmap->Rotate(RotateN oneFlipX);
memcpy(cbuffer, bitmap,size);
FILE *fptr;
fptr = fopen("image2.b mp","wb");
fwrite(cbuffer, 1,size,fptr);
fclose(fptr);
In My above code, the image2.bmp has not saving.
What is the problem?
Comment