miguel28 / imagelistview

Automatically exported from code.google.com/p/imagelistview
0 stars 0 forks source link

Some rotated images are not displayed in the thumbnail as rotated #131

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hi Ozgur

Please take a look at this screenshot:

http://twitpic.com/4s8j18/full

Here, the second picture is actually rotated but in the preview, it is not 
being displayed as rotated.

My rotate function looks like:

---------------
public void PerformRotateAnticlockwise()
{
    foreach (var item in thumbnailListView.SelectedItems)
    {
        var asset = (WebImageAsset)item.Tag;
        asset.CommitState = CommitState.Modified;

        item.BeginEdit();
        using (var img = ImageHelper.LoadImage(item.FileName))
        {
            img.RotateFlip(RotateFlipType.Rotate90FlipNone);
            ImageHelper.SaveImage(img, item.FileName);
        }
        item.Update();
        item.EndEdit();
    }

    notifyNeedUpdatePreview();
    PerformUpdateUI();
}
---------------

Can you tell me whether I'm doing some issues during rotate or whether it is a 
feature of ImageListView to e.g. take care of some EXIF information about 
rotation?

Thanks
Uwe

Original issue reported on code.google.com by uwe.k...@gmail.com on 2 May 2011 at 5:17

GoogleCodeExporter commented 9 years ago
Yes, there is the AutoRotateThumbnails property.

Original comment by oozcitak on 2 May 2011 at 9:52

GoogleCodeExporter commented 9 years ago
Cool. Thanks a lot and sorry for posting this as an issue.

Original comment by uwe.k...@gmail.com on 2 May 2011 at 9:57

GoogleCodeExporter commented 9 years ago
No problem. Nice to hear from people using the control.

Thanks,
Ozgur

Original comment by oozcitak on 2 May 2011 at 10:05

GoogleCodeExporter commented 9 years ago
After setting ImageListView.AutoRotateThumbnails to FALSE, the image still 
always gets rotated. Are there additional steps I have to perform?

Original comment by uwe.k...@gmail.com on 2 May 2011 at 10:08

GoogleCodeExporter commented 9 years ago
Sorry, it looks like Image.RotateFlip() does not set the rotation EXIF tag at 
all. Hence, this issue is not related to AutoRotateThumbnails. Can you attach 
the jellyfish image (zipped to prevent re-encoding)?

Original comment by oozcitak on 2 May 2011 at 10:32

GoogleCodeExporter commented 9 years ago
Thanks, Ozgur

Here is the image:

https://www.zeta-uploader.com/49186544

Best regards
Uwe

Original comment by uwe.k...@gmail.com on 2 May 2011 at 10:41

Attachments:

GoogleCodeExporter commented 9 years ago
Thanks, looking into it.

Original comment by oozcitak on 2 May 2011 at 10:53

GoogleCodeExporter commented 9 years ago
I extracted the EXIF thumbnail and the original image from the file (attached 
screenshot). The thumbnail and the original jellyfish image does not match. It 
seems like the original was rotated 90 degrees CCW but the thumbnail was not. 
This seems to be the cause of the issue. 

If you are dealing with such images, you can force the control to disregard the 
EXIF thumbnail by setting the UseEmbeddedThumbnails property to 
UseEmbeddedThumbnails.Never. 

Best regards,
Ozgur

Original comment by oozcitak on 2 May 2011 at 11:20

Attachments:

GoogleCodeExporter commented 9 years ago
It works. Perfekt, thank you :-)

Original comment by uwe.k...@gmail.com on 2 May 2011 at 11:24

GoogleCodeExporter commented 9 years ago
Good to hear :)

Original comment by oozcitak on 2 May 2011 at 11:27

GoogleCodeExporter commented 9 years ago
i got the same problem again and again, can you give me the "Exif Tester" 
download link .
Thanks.

Original comment by medhelpn...@gmail.com on 2 May 2011 at 12:50

GoogleCodeExporter commented 9 years ago
Sure. I've attached the exe, source code is here:

http://code.google.com/p/exiflibrary/source/browse/

Original comment by oozcitak on 2 May 2011 at 1:13

Attachments:

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Thank you So much Ozgur.

Original comment by medhelpn...@gmail.com on 2 May 2011 at 2:54

GoogleCodeExporter commented 9 years ago
Closing...

Original comment by oozcitak on 7 May 2011 at 9:24