View Full Version : Transparent text background in the OSD + Win2k
l.s
August 20th, 2005, 04:13 PM
If I'm trying to get a semi transparent background for the OSD displayed text on my Win2k box, the actual background color is always some shade of black. So I assume, that this funktionality is not avalible on systems <NT5.1?
example:
BGColor1 = osd.MakeARGB(10,255,218,4),
BGColor2 = osd.MakeARGB(10,255,218,4),
Regards, Lars
Ron
August 20th, 2005, 04:33 PM
That will not make the bg transparant. The transparancy in there is only meant for subsequent draw operation in that window.
Erstam
August 21st, 2005, 01:26 AM
First thing: I don't know if this works in W2k. But you can at least try.
Use SetTransparency(Transparency, TransparencyColorKey) on the osd. Transparency is any value between 0 (completely opaque) and 255 (solid), TransparencyColorKey is used to set a specific color to transparent.
Erstam
l.s
August 21st, 2005, 05:51 AM
Use SetTransparency(Transparency, TransparencyColorKey) on the osd. Transparency is any value between 0 (completely opaque) and 255 (solid), TransparencyColorKey is used to set a specific color to transparent.
I tried all possible combinations allready, but it seems that any value other than 0 or 255 isn't working as intendet with Win2k. And even with 0 one gets messed up font borders.
The one thing that was first confusing me for hours in regards of the usage of BGColor1/2 was caused by the font "Windings". It somehow prevents the gradient Background colors to be used as intended?
Regards, Lars
Promixis
August 21st, 2005, 10:13 AM
does win2k support transparency?
l.s
August 21st, 2005, 10:41 AM
does win2k support transparency?
Out of the box only partly. But GDI+ should do the trick.
Regards, Lars
Promixis
August 21st, 2005, 10:52 AM
can you try the win.FadeWindow function?
l.s
August 21st, 2005, 11:37 AM
can you try the win.FadeWindow function?
I'm a total lua newbee and have no idea how to create a proper window to apply the function onto it. But window transparency (and fading) is usually handled quite well by Windows 2000. And so is the Transparency setting in the osd option the only thing working properly. What is not working out of the box are things like alpha+antialiasing. Easy to be seen in the first screen shot.
That it can be done under Win2k using the GDI+ libs can be nicely seen on the second screenshot (showing an Foobar2000 OSD pluging).
Regards, Lars
Promixis
August 21st, 2005, 11:40 AM
Ron?
I am not we have antialiasing enabled...
Ron
August 21st, 2005, 12:09 PM
I have mentioned this to you before. I think you should probably use the shaped window extensions to do this without artifacts.
look into
osd:SetRegion(path)
for the path use a text path.
Powered by vBulletin® Version 4.1.8 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.