or search for rotating bitmap mfc (or replace mfc with vc++) and you will find several links within the top 10 that will have full code examples of how to do this. Do a little bit of research and try it out. If it doesn't work right post up where you are having a problem and your code that relates to the problem.
I have retrieved the image data from the camera device. Now I need to rotate that image data using gdi+. I have using following code for rotating the image.
void RotFlipImg::FlipImgData(char* mydata,prUInt32 imgsize)
{
FILE *fptr1;
fptr1=fopen("liveimage.jpg","wb");
fwrite(mydata,imgsize,1,fptr1);
fclose(fptr1);
GdiplusStartupInput gdiplusStartupInput;
ULONG_PTR gdiplusToken;
GdiplusStartup(&gdiplusToken, &gdiplusStartupInput, NULL);
Bitmap* bitmap = new Bitmap(L"liveimage.jpg");
bitmap->RotateFlip(RotateNoneFlipX);
bitmap->Save(L"FlipImage.jpg",&guidBmp);
delete bitmap;
}
In above code, I write that data into "liveimage.jpg" after rotate liveimage.jpg to FlipImage.jpg. It will becomes late. So I have to directly rotate the image data(mydata).
How can I rotate the image as stream data without using direct image?.