English Amiga Board


Go Back   English Amiga Board > Coders > Coders. System

 
 
Thread Tools
Old 18 January 2014, 21:28   #841
mfilos
Paranoid Amigoid
 
mfilos's Avatar
 
Join Date: Mar 2008
Location: Athens/Greece
Age: 45
Posts: 1,978
Wrong library thread mate.
This should be moved to the Icon.library thread instead
mfilos is offline  
Old 18 January 2014, 22:55   #842
prowler
Global Moderator
 
prowler's Avatar
 
Join Date: Aug 2008
Location: Sidcup, England
Posts: 10,300
Two posts moved to icon.library thread.

Thanks Marios!
prowler is offline  
Old 19 January 2014, 17:15   #843
PeterK
Registered User
 
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,385
Thanks prowler

Quote:
when I use the original icon.library and open my App on an own screen, the icon colors are wrong. When I use your lib, the icon colors are correct. Can you tell me why?
Hi AGS,
it's probably showing the correct colors only with direct drawing (that can't be wrong) but not in 8-bit or AGA screenmodes.

I guess, you didn't call LayoutIconA() for mapping the icons to your screen colors first.

Code:
	LayoutIconA -- Adapt a palette-mapped icon for display (V44)

   SYNOPSIS
	success = LayoutIconA(icon,screen,tags);
	D0                    A0   A1     A2

	BOOL LayoutIconA(struct DiskObject *icon,struct Screen *screen,
	                 struct TagItem *tags);

	success = LayoutIcon(icon,screen,...);

	BOOL LayoutIcon(struct DiskObject *icon,struct Screen *screen,...);

   FUNCTION
	This function will prepare an icon for display, either on a
	specific screen or using a default colour palette. It is
	useful only for palette mapped icons.

   INPUTS
	icon -- The icon to be remapped. This must be a palette mapped
	    icon.
	screen -- Pointer to a screen to remap the icon for or NULL
	    to remap the icon to use the system default colour palette
	    or something very similar to it (this means: four colours
	    only).
	tags -- Additional rendering options.
PeterK is online now  
Old 20 January 2014, 07:12   #844
AGS
XoXo/Tasko Developer
 
AGS's Avatar
 
Join Date: Dec 2013
Location: Munich
Age: 49
Posts: 450
Thanks, I think I will modify my code to use this call. Or advise the users that your lib is required?
AGS is offline  
Old 20 January 2014, 07:37   #845
PeterK
Registered User
 
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,385
No, without calling LayoutIconA() you will get the same wrong colors on all AGA screens, no matter which icon.library your users have installed. And only the direct drawing hides this missing colormapping, because it reads the RGB colors (instead of any pens) and writes them directly onto all Hi/TrueColor screens. Read the icon.library autodocs for the details, plz.
PeterK is online now  
Old 20 January 2014, 11:35   #846
Retrofan
Ruler of the Universe
 
Retrofan's Avatar
 
Join Date: Mar 2010
Location: Lanzarote/Spain
Posts: 6,195
Quote:
Originally Posted by PeterK View Post
I guess, you didn't call LayoutIconA() for mapping the icons to your screen colors first.
Hi PeterK: woudn't it be possible to add a fuction like this to your library, so the icons could use some good palette like Rebel's one?

Edit: And why the colors are better if using 16 colors I just save the icon image as png? The png has better colours than the icon. Yes, newbie quesions I know.

Last edited by Retrofan; 20 January 2014 at 11:56.
Retrofan is offline  
Old 20 January 2014, 12:01   #847
PeterK
Registered User
 
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,385
1.) LayoutIconA() is a function of the icon.library already.
Mapping to Rebel's palette is done anyway if it's defined (locked) by FullPalette.

Seems, that I miss the point in your request, where is the problem?

2.) How are you watching the PNG image, on which screen (depth) ??

It's probably because Multiview maps the RGB truecolor values in just one step and with Floyd Steinberg Dithering to the screen colors instead of reducing the number of colors first to less than 256 and then mapping without real dithering to the screen colors.

But be sure that Multiview will need much, much longer for its job !

Last edited by PeterK; 20 January 2014 at 12:40.
PeterK is online now  
Old 20 January 2014, 13:49   #848
Retrofan
Ruler of the Universe
 
Retrofan's Avatar
 
Join Date: Mar 2010
Location: Lanzarote/Spain
Posts: 6,195
Quote:
Originally Posted by PeterK View Post
1.) LayoutIconA() is a function of the icon.library already.
Mapping to Rebel's palette is done anyway if it's defined (locked) by FullPalette.

Seems, that I miss the point in your request, where is the problem?


2.) How are you watching the PNG image, on which screen (depth) ??

It's probably because Multiview maps the RGB truecolor values in just one step and with Floyd Steinberg Dithering to the screen colors instead of reducing the number of colors first to less than 256 and then mapping without real dithering to the screen colors.

But be sure that Multiview will need much, much longer for its job !
Look my pic. It is using a locked 16 colors palette. Perhaps am I missing the way to lock also the icons? The image 16CRebels is opened with Multiview, but it will be anyway different (more color) with PicShow from the original Utilities icon.


As I say the screen has just 16 colors, so the icons look greyed, but see how it looks just saving the icon as png (no palette used to save it). That's using PicShow.

http://imagizer.imageshack.us/v2/800...0/849/n5r4.png

Last edited by Retrofan; 25 January 2014 at 19:49.
Retrofan is offline  
Old 20 January 2014, 15:10   #849
PeterK
Registered User
 
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,385
Post your ENV:FullPalette.prefs file, plz. Thx.
PeterK is online now  
Old 20 January 2014, 16:32   #850
Retrofan
Ruler of the Universe
 
Retrofan's Avatar
 
Join Date: Mar 2010
Location: Lanzarote/Spain
Posts: 6,195
From EnvArc/Sys:


Edit: I would say the only icons that don't look good are ken's drawers, but as you know they are the most of them. I think it's a lack of blue what they have got using your library, Rebel's palette and 16C.
Attached Files
File Type: rar fullpalette.rar (602 Bytes, 109 views)

Last edited by Retrofan; 23 January 2014 at 21:41.
Retrofan is offline  
Old 22 January 2014, 08:36   #851
AGS
XoXo/Tasko Developer
 
AGS's Avatar
 
Join Date: Dec 2013
Location: Munich
Age: 49
Posts: 450
Peter, you are Icon-Library Expert. Is it required to match a GetDefDiskObject() with FreeDiskObject()?
AGS is offline  
Old 23 January 2014, 21:42   #852
Retrofan
Ruler of the Universe
 
Retrofan's Avatar
 
Join Date: Mar 2010
Location: Lanzarote/Spain
Posts: 6,195
Could you make perhaps a library just for Rebel's palette? Maybe I'm asking too much, but think that CWB and AK Real use it, and this thread has over 52.000 visits.

Last edited by Retrofan; 24 January 2014 at 00:50.
Retrofan is offline  
Old 24 January 2014, 17:37   #853
PeterK
Registered User
 
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,385
Quote:
Originally Posted by AGS View Post
Peter, you are Icon-Library Expert. Is it required to match a GetDefDiskObject() with FreeDiskObject()?
Quote:
GetIconTagList -- Retrieve an icon (V44)
This function is a superset of GetDefDiskObject(), GetDiskObject() and GetDiskObjectNew().
In any case you have to call FreeDiskObject():

Quote:
A FreeList structure is allocated just after the DiskObject structure; FreeDiskObject makes use of this to get rid of the memory that was allocated.
PeterK is online now  
Old 25 January 2014, 05:13   #854
Michael
A1260T/PPC/BV/SCSI/NET
 
Michael's Avatar
 
Join Date: Jan 2013
Location: Moscow / Russia
Posts: 841
We are asking to follow the standard OS prefs (borders ;-) ), as for palettes, it's not the libraries function, so you have to leave it to FullPalette, and iicon lib has a very good colour reduction/approximation algorithm, and a very fast one too. It would be nice to see an option to limit the number of free pens the icon lib can lock if it can not find a suitable available colour.
Michael is offline  
Old 25 January 2014, 06:33   #855
PeterK
Registered User
 
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,385
Quote:
Originally Posted by Retrofan View Post
Could you make perhaps a library just for Rebel's palette? Maybe I'm asking too much, but think that CWB and AK Real use it, and this thread has over 52.000 visits.
And what should that special library do?
No screenshots please !
If there are no suitable pens for the required blue in Rebel's palette then you have to change the palette. An example FullPalette.prerfs file is attached, but you can optimize it with the preferences tool of FullPalette.


@Michael
Quote:
It would be nice to see an option to limit the number of free pens the icon lib can lock ...
Icon.library locks not a single pen. These colors are all shared pens. On 256 color screens it leaves about 20 pens unused for other apps, but if I do that on low depth screens then the color mapping would give very poor results. Try to set the icon quality to a lower value in Prefs/Workbench.
Attached Files
File Type: rar fullpalette.rar (605 Bytes, 110 views)

Last edited by PeterK; 25 January 2014 at 06:56.
PeterK is online now  
Old 25 January 2014, 12:15   #856
Retrofan
Ruler of the Universe
 
Retrofan's Avatar
 
Join Date: Mar 2010
Location: Lanzarote/Spain
Posts: 6,195
Thanks PeterK. In fact I was trying that, to change the palette, but there were two things pushing me back:

-Rebel took a couple of years to make it.
-I've got deuteranopia (I confuse some greens or see as other color).

So I was waiting something like this. I will gladly try it. Thanks.

Edit: Much, much better blue on the drawer icons now (well, before there wasn't). Will try it more anyway. Thanks again.

Last edited by Retrofan; 25 January 2014 at 12:24.
Retrofan is offline  
Old 29 January 2014, 12:35   #857
Retrofan
Ruler of the Universe
 
Retrofan's Avatar
 
Join Date: Mar 2010
Location: Lanzarote/Spain
Posts: 6,195
Peter sorry if maybe it's a bit offtopic. I've got installed your Fullpalette prefs -wonderful-, and I've made six more skins to add to my version. The thing is that once using them they look marvellous. I take then a png photo with sgrab and looks the same with picboot or multiview, but when I reboot with other skin, the previous photo doesn't look as good as it was; isn't smooth. So for example with MorpheuZ that shows a preview of all the skins, only the current one will look perfect.

Do you know why?

http://imagizer.imageshack.us/v2/800...0/585/vr4x.png

Edit: On the contrary: http://imagizer.imageshack.us/v2/800x600q90/11/emuq.png

Last edited by Retrofan; 29 January 2014 at 12:43.
Retrofan is offline  
Old 29 January 2014, 17:42   #858
PeterK
Registered User
 
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,385
This behaviour may be caused by the dithering procedure of your PNG datatype. I don't know what exactly you mean with "isn't smooth", but from my point of view the first screenshot "vr4x.png" looks a little bit better.

Check the preferences of your PNG datatype for color quality and other settings.
PeterK is online now  
Old 01 March 2014, 19:12   #859
PeterK
Registered User
 
Join Date: Apr 2005
Location: digital hell, Germany, after 1984, but worse
Posts: 3,385
Update to icon.library 46.4.334

Just some very small fixes:

1) Saving a tool or project icon with IconEdit in its program directory (no path) and without a name, simply as ".info", will not change the icon type to drawer anymore. This was requested by a user to create an invisible icon by deleting the first image in order to use it as a placeholder behind LimpidClock.

2) The first default color icons that are displayed by WB 3.0/3.1, like the Ram Disk or other disk icons , won't appear in 4-color mode anymore. There was no global screen defined in the icon.library settings.
PeterK is online now  
Old 02 March 2014, 04:04   #860
Michael
A1260T/PPC/BV/SCSI/NET
 
Michael's Avatar
 
Join Date: Jan 2013
Location: Moscow / Russia
Posts: 841
Option to not modify OS4+ icon data during snapshot ? (Currently converts icons to OS35 icon format)

And default for frames ON if no env variable is set. (System default way) It will not heart anybody, since for normal WB you will have it set to no borders, if you like it so.
Michael is offline  
 


Currently Active Users Viewing This Thread: 4 (3 members and 1 guests)
peceha, pixie, DisasterIncarna
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
ClassicWB Full and icon.library 46.4 Retroplay project.ClassicWB 8 05 August 2018 13:57
WB library conflict/versions Amiga1992 support.Apps 3 22 July 2010 18:47
PNG Icon to Color Icon Converter? Leandro Jardim request.Apps 1 24 May 2010 04:39
What's the latest version of icon.library for OS3.9? NovaCoder support.Apps 3 30 June 2009 15:43
Requesting icon.library v44+... nikvest request.Other 2 16 September 2007 01:58

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 23:37.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.16977 seconds with 14 queries