After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 338632 - Missing frames on some image thumbnails
Missing frames on some image thumbnails
Status: RESOLVED OBSOLETE
Product: nautilus
Classification: Core
Component: Thumbnails
2.20.x
Other All
: Normal normal
: ---
Assigned To: Nautilus Maintainers
Nautilus Maintainers
: 338633 500081 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2006-04-15 17:38 UTC by Giacomo Perale
Modified: 2008-03-17 23:23 UTC
See Also:
GNOME target: ---
GNOME version: 2.19/2.20



Description Giacomo Perale 2006-04-15 17:38:09 UTC
Please describe the problem:
When Nautilus create the thumbnails for images, some of the images show the
frame around the content and other don't. This bug occurs indifferently with
png, gif and jpeg. See this screenshot for an example:
http://img460.imageshack.us/img460/4822/nautilus2ii.png

Those images were generated in different days with gimp, imagemagick and the PNG
exporter of Matlab. The problem is generally reproducible, but after I've
upgraded nautilus 2.12.x to nautilus 2.14.x some images that were displayed with
the frame suffer from this problem.

At first I thought that the bug could be related to the presence of an embedded
thumbnail, but I think that for consistency sake the frame should be always added.

Steps to reproduce:


Actual results:


Expected results:


Does this happen every time?


Other information:
Comment 1 Giacomo Perale 2006-04-15 17:43:46 UTC
*** Bug 338633 has been marked as a duplicate of this bug. ***
Comment 2 Sergej Kotliar 2006-04-15 19:29:25 UTC
I noticed this when doing an upgrade, that the old pictures didn't have a frame, and the newly thumbnailed ones did.

By removing the ~/.thumbnails/ directory I didn't see this bug anymore.

Could that be the same case for you? That images that were thumbnailed by an older version are still cached?
Comment 3 Giacomo Perale 2006-04-25 18:36:29 UTC
I removed ~/.thumbnails/, and the situation worsened. Now more or less one out of four of my image files gets the frame around the thumbnail. Also, it seems that, randomly, some video files don't thumbnailed anymore.
Comment 4 Sergej Kotliar 2006-04-25 19:02:03 UTC
The video issue needs to be taken with totem, but most probably, some plugins aren't installed that were, and you're now unable to open them...

Can you tell any system between images that do have borders and those that don't?
File type? Size (in pixels)? Filesize (in bytes)? anything of that matter you could add?
Comment 5 Giacomo Perale 2006-04-25 20:17:21 UTC
I'm afraid that it is not a totem problem, because restarting nautilus the file get thumbnailed, and removing .thumbnails/ and restarting nautilus again can end with those files thumbnailed and some others, previously working, not.

The images haven't got common properties, as far as I can remember. Size varies from 50x50 to 1024x768, the format can be jpeg, png, gif or svg, the images were generated (or edited) by imagemagick, gimp, inkscape, gnome-screenshot, the png exporter of Matlab, or downloaded from internet.
Comment 6 Giacomo Perale 2006-05-25 21:01:04 UTC
sorry for the bugspam, but is there any news?
Comment 7 Giacomo Perale 2006-07-26 20:10:17 UTC
ah-ehm...
Comment 8 sebastian.starosielec 2006-10-09 08:33:21 UTC
Maybe it's a artefact of

(changelog)
2004-12-17  Alexander Larsson  <alexl@redhat.com>

	* libnautilus-private/nautilus-icon-factory.c: (load_icon_file):
	Don't use frames for images with alpha.

Comment 9 Gilles Dartiguelongue 2007-01-24 22:32:05 UTC
Indeed, it might be related. I've looked at some of these picture-with-no-frame and they are all using an alpha channel and as soon as I remove the alpha channel, the thumbnail is generated with the frame.
Comment 10 Giacomo Perale 2007-02-07 13:38:39 UTC
(In reply to comment #9)
> Indeed, it might be related. I've looked at some of these picture-with-no-frame
> and they are all using an alpha channel and as soon as I remove the alpha
> channel, the thumbnail is generated with the frame.
> 

I reverted that change and now every thumbnail has its frame. I'm afraid that this is not a bug but a design choice.
I think however that this behavior is acceptable when the transparency is effectively used (for example icons with blank space around the represented object) but gives bad results when the alpha channel is present but unused (for example a screenshot or a picture with white background).
Comment 11 Gilles Dartiguelongue 2007-02-07 14:03:08 UTC
I agree, maybe we could patch it to check that alpha channel values changes.

Something like :

check_alpha_use(img) {
 for( x=0; x<img.width; x++)
   for( y=0; y<img.height; y++)
     b = a;
     a = img[x][y];
     if (a!=b) return true;

 return false;
}

Complexity would be o(img.width*img.height) (if I'm not mistaken) but I don't know if it is acceptable.
Comment 12 sebastian.starosielec 2007-02-07 14:13:10 UTC
It might be a good idea to restrict those alpha-channel tests to the four border lines of the image. If the image is an icon, it would have alpha-channel used at at least any of the border.
Comment 13 Pavel Šefránek 2008-03-17 17:13:56 UTC
Occurs in 2.20
Comment 14 Cosimo Cecchi 2008-03-17 23:21:50 UTC
*** Bug 500081 has been marked as a duplicate of this bug. ***
Comment 15 Cosimo Cecchi 2008-03-17 23:23:11 UTC
This is fixed now since 2.21. Closing as OBSOLETE, thanks for reporting this bug. Please feel free to report any other bug you find!