Extracted .ico's toolbar icon looks worse than the exe's
Moderators: white, Hacker, petermad, Stefan2
Extracted .ico's toolbar icon looks worse than the exe's
Hi!
I noticed that when I choose the very same icon that I extracted from an exe (via IconsExtract), and use it as the icon file it looks a lot worse than when it's loaded from the exe.
It looks rather aliased, as if it's scaled with an inferior algorithm.
Here's how they look in their original size:
Image: https://abload.de/img/ff-tc-icon-origpfs95.png
And magnified:
Image: https://abload.de/img/ff-tc-icon-3xv0ssc.png
I noticed that when I choose the very same icon that I extracted from an exe (via IconsExtract), and use it as the icon file it looks a lot worse than when it's loaded from the exe.
It looks rather aliased, as if it's scaled with an inferior algorithm.
Here's how they look in their original size:
Image: https://abload.de/img/ff-tc-icon-origpfs95.png
And magnified:
Image: https://abload.de/img/ff-tc-icon-3xv0ssc.png
Last edited by avada on 2017-05-31, 12:18 UTC, edited 3 times in total.
-
- Power Member
- Posts: 872
- Joined: 2013-09-04, 14:07 UTC
Did you extract the icon with all its possible icon sizes from the exe?
Note that icon resources are not just one image. Icons are a collection of images in different resolutions for different (standard/common) icon sizes.
I would guess you only extracted the icon image for one particular resolution, which so happened wasn't the resolution used by the toolbar. The scaled down icon looking worse would simply be due to the fact that the original icon resource in the exe also has a small image hand-crafted specifically for the small size (and thus of course appearing better than a scaled down larger version of the icon) and which you just forgot to extract...
Note that icon resources are not just one image. Icons are a collection of images in different resolutions for different (standard/common) icon sizes.
I would guess you only extracted the icon image for one particular resolution, which so happened wasn't the resolution used by the toolbar. The scaled down icon looking worse would simply be due to the fact that the original icon resource in the exe also has a small image hand-crafted specifically for the small size (and thus of course appearing better than a scaled down larger version of the icon) and which you just forgot to extract...
I'm using Resource Hacker for such tasks, and it shows pure single-size icons in Icon resource folder and all-size icons in Icon Group resource folder, so I save icons from Icon Group folder in order to get icon file with all available icon sizes.
Hi!elgonzo wrote:Did you extract the icon with all its possible icon sizes from the exe?
Note that icon resources are not just one image. Icons are a collection of images in different resolutions for different (standard/common) icon sizes.
I would guess you only extracted the icon image for one particular resolution, which so happened wasn't the resolution used by the toolbar. The scaled down icon looking worse would simply be due to the fact that the original icon resource in the exe also has a small image hand-crafted specifically for the small size (and thus of course appearing better than a scaled down larger version of the icon) and which you just forgot to extract...
I'm aware of icon files and multiple resolutions. The icon files are extracted in their totality. They show up with all resolutions in my image viewer (imagine). So I don't need to try hard to verify.
If you don't believe me why not try it yourself?
(Note: I have the button bar size set to 24, but it looks noticeable worse from 18-24)
Last edited by avada on 2017-05-31, 11:03 UTC, edited 2 times in total.
I didn't use resource hacker. But IconsExtract extracted two files of FF's main icon which are bit identical and both have all the resolutions up to 256*256.MVV wrote:I'm using Resource Hacker for such tasks, and it shows pure single-size icons in Icon resource folder and all-size icons in Icon Group resource folder, so I save icons from Icon Group folder in order to get icon file with all available icon sizes.
(Actually it extracted exactly the same stuff in the same order as TC shows for the exe when editing a toolbar icon)
So, In conclusion TC has some bug. Either it chooses the an inappropriate size for the bar in this case or a bad algorithm.
-
- Power Member
- Posts: 872
- Joined: 2013-09-04, 14:07 UTC
Hi!elgonzo wrote:What toolbar size are you using?avada wrote:So, In conclusion TC has some bug. Either it chooses the an inappropriate size for the bar in this case or a bad algorithm.
I mentioned it: 24. But it doesn't look right at sizes 18-24
Hi!Horst.Epp wrote:I extracted the FF icons with Iconext and its looking fine in TC
with Buttonbar Appearance set to 48
It looks good apart from the size range I mentioned.
-
- Power Member
- Posts: 872
- Joined: 2013-09-04, 14:07 UTC
- ghisler(Author)
- Site Admin
- Posts: 48124
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
I will check it. You can't use the same Windows functions to load icons from .exe/.dll and from .ico, so this may be causing the difference here.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
- ghisler(Author)
- Site Admin
- Posts: 48124
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Please try whether it's better with TC 9.10 beta now!
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Cool!ghisler(Author) wrote:Please try whether it's better with TC 9.10 beta now!
I tested it. The ico looks just as good as the exe now.
Image: https://abload.de/img/f56-tc1j1ruv.png
Image: https://abload.de/img/f56-tc2yeoer.png
(Not identical, so I guess the scaling algorithms are different.)
- ghisler(Author)
- Site Admin
- Posts: 48124
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Yes, the algorithms are different, but at least both are smoothly scaled now.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com