I have code to batch resize digital photos.
Some photos are taken in portrait orientation.
For the photos in portrait orientation, I have to rotate them.
I am using the following C# code to rotate the photo:
bmpOrig.RotateFlip(System.Drawing.RotateFlipType.Rotate90FlipNone);
bmpOrig.Save(filename, ImageFormat.Jpeg);
It works fine (displays the way I want in a web browser).
However, if I view the new image in Photoshop (and HP photo viewer) it displays rotated.
I have done a lot of research and I believe there is EXIF data that flags the image is rotated.
My question is: How do I reset this EXIF data to indicate that the image does not need to be rotated?
I'm developing in VS 2010.
Thanks