Page 15 of 28

Re: Plugin: Chameleon

Posted: July 3rd, 2016, 4:38 pm
by Socks the Fox
Alright I poked around in my test app and it looks like this is what's happening:

Because of the difference in the shade of red between the center and the edges, when Chameleon reduces the image's colors it basically becomes black, dark red and light red. Because the light red is in the center and doesn't have any pixels touching the edge, Chameleon picks the dark red for the primary background color. Then since the light red is still a possible option, and there's so much of it, it picks that for the primary foreground color. Then it sees the "black" in the corners and picks that for the secondary background, leaving only the white for the secondary foreground. Because the light red and dark red don't have enough contrast, it then forces the foreground towards white.

Granted, this is for the full image; if Chameleon is doing any cropping that will affect things.

Not sure what to do about it beyond changing weights and increasing the number of colors Chameleon is allowed to work with.

Re: Plugin: Chameleon

Posted: July 4th, 2016, 4:43 pm
by Flayre1
Ah ok, thanks! It's not a big deal for me if it doesn't see the black for the foreground. Pretty interesting seeing how it decides what is what!
Thanks!

Re: Plugin: Chameleon

Posted: July 4th, 2016, 6:58 pm
by Tthaddee
Waw ! Thank you for this explanation ! I understand much better how it works. :D

Re: Plugin: Chameleon

Posted: July 5th, 2016, 4:44 pm
by FreeRaider
Hello Socks the Fox, I have two questions:
the first: if I use in parent measure File option, is it necessary to use CropDesktop=0?
the second: is Crop{X,Y, W, H} based on the real dimensions of an image?

For example: if I have an image 2048x1960 pixels but I use a meter image like this

Code: Select all

[MeterImage]
Meter=Image
MeasureName=MeasureImage
X=0
Y=0
W=250
H=150
AntiAlias=1
, to capture the colours that they are in the lower right, do I need to use CropX = 2030 and so on or CropX = 220 and so on ?

Thanks in advance

Re: Plugin: Chameleon

Posted: July 5th, 2016, 4:50 pm
by Socks the Fox
Hello! If you're using the File option instead of letting Chameleon use the desktop, then you do not need the CropDesktop option.

The cropping info is the real dimensions of the image, so you'll need to figure out whatever offsets and whatnot manually.

Re: Plugin: Chameleon

Posted: July 9th, 2016, 4:05 pm
by Tthaddee
Hi Socks The Fox,

I'm (always ^^) on my project and I'm asking me if it it possible to artificially create a third ForeGround and BackGround color ? I noticed that sometimes, Chameleon provides colors which are not "important" in the image (or simply not present in the picture). So maybe that adding a third color, the result is more likely to be "accurate" ?

:)

Have a nice day !

Re: Plugin: Chameleon

Posted: July 31st, 2016, 3:37 pm
by Flayre1
Hey,
So having a little more issues with setting it up.
I've managed to get it working with DINAJ but when I try using it in Circuitous its only showing white.
I think I have done the same thing in both, so I can't work out why it wont work.
Here is the code in the appearance.txt for C2:

Code: Select all

[ChameleonDesktop]
Measure=Plugin
Plugin=Chameleon
Type=Desktop

[DesktopFG2]
Measure=Plugin
Plugin=Chameleon
Parent=ChameleonDesktop
Color=Foreground2

[Variables]

; color settings
innerRingColor=0,0,0,255
outerRingColor=#innerRingColor#
pieBgColor=246,138,30,255
pieColor=0,0,0,255
textMainColor=[DesktopFG2]
textSubColor=#innerRingColor#
bgBarColor=0,0,0,255

; size and scaling
radius=30
innerRadius=(#radius#*0.55)
edging=(#radius#*0.3)
orient=right
pieSize=1.0
pieStart=4.712

; show and hide skin components
hideInnerEdge=0
hideOuterEdge=0
hidePieBg=0
hideDivider=0
hideSubText=0
Does anything look out of place or anything that you know could be causing this?

Re: Plugin: Chameleon

Posted: July 31st, 2016, 7:28 pm
by eclectic-tech
Flayre1 wrote:Hey,
So having a little more issues with setting it up.
I've managed to get it working with DINAJ but when I try using it in Circuitous its only showing white.
I think I have done the same thing in both, so I can't work out why it wont work.
Here is the code in the appearance.txt for C2:

Code: Select all

[ChameleonDesktop]
Measure=Plugin
Plugin=Chameleon
Type=Desktop

[DesktopFG2]
Measure=Plugin
Plugin=Chameleon
Parent=ChameleonDesktop
Color=Foreground2

[Variables]

; color settings
innerRingColor=0,0,0,255
outerRingColor=#innerRingColor#
pieBgColor=246,138,30,255
pieColor=0,0,0,255
textMainColor=[DesktopFG2]
textSubColor=#innerRingColor#
bgBarColor=0,0,0,255

; size and scaling
radius=30
innerRadius=(#radius#*0.55)
edging=(#radius#*0.3)
orient=right
pieSize=1.0
pieStart=4.712

; show and hide skin components
hideInnerEdge=0
hideOuterEdge=0
hidePieBg=0
hideDivider=0
hideSubText=0
Does anything look out of place or anything that you know could be causing this?
You need to add DynamicVariables=1 to your meters that use Chameleon colors. See this post: https://forum.rainmeter.net/viewtopic.php?p=125280#p125280

Re: Plugin: Chameleon

Posted: July 31st, 2016, 7:38 pm
by Flayre1
eclectic-tech wrote:You need to add DynamicVariables=1 to your meters that use Chameleon colors. See this post: https://forum.rainmeter.net/viewtopic.php?p=125280#p125280
Yeah, sorry about that! I did have that in, I pasted the wrong code. Even with that line in its not working correctly and the colours only show white.
Sorry to confuse that bit, thanks for the pointer though! :D

Re: Plugin: Chameleon

Posted: July 31st, 2016, 11:07 pm
by Socks the Fox
Not sure if this is the cause but could you try adding an alpha value to your textMainColor? Something like textMainColor=[DesktopFG2]FF (since the default is hex)

I just want to narrow down the possibilities :3