Re: fading trough 3 colors... how to do it?
Posted: August 8th, 2020, 11:30 am
Here is the promissed code. This time zou don!t have to use -1 for the components of the not used colors, all those components can be left empty (in the posted code the components of colors from 6 to 10 are left so).
Code: Select all
[Rainmeter]
Update=1000
[Variables]
R1=198
G1=251
B1=200
R2=196
G2=92
B2=38
R3=14
G3=175
B3=67
R4=19
G4=196
B4=118
R5=58
G5=95
B5=5
R6=
G6=
B6=
R7=
G7=
B7=
R8=
G8=
B8=
R9=
G9=
B9=
R10=
G10=
B10=
Range=0
[MeasureColor3Red]
Measure=String
String=#R3#
IfMatch=^$|^-1$|#*R3*#
IfMatchAction=[!SetVariable Color3R "0"][!SetVariable R3 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color3R "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor3Green]
Measure=String
String=#G3#
IfMatch=^$|^-1$|#*G3*#
IfMatchAction=[!SetVariable Color3G "0"][!SetVariable G3 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color3G "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor3Blue]
Measure=String
String=#B3#
IfMatch=^$|^-1$|#*B3*#
IfMatchAction=[!SetVariable Color3B "0"][!SetVariable B3 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color3B "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor4Red]
Measure=String
String=#R4#
IfMatch=^$|^-1$|#*R4*#
IfMatchAction=[!SetVariable Color4R "0"][!SetVariable R4 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color4R "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor4Green]
Measure=String
String=#G4#
IfMatch=^$|^-1$|#*G4*#
IfMatchAction=[!SetVariable Color4G "0"][!SetVariable G4 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color4G "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor4Blue]
Measure=String
String=#B4#
IfMatch=^$|^-1$|#*B4*#
IfMatchAction=[!SetVariable Color4B "0"][!SetVariable B4 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color4B "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor5Red]
Measure=String
String=#R5#
IfMatch=^$|^-1$|#*R5*#
IfMatchAction=[!SetVariable Color5R "0"][!SetVariable R5 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color5R "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor5Green]
Measure=String
String=#G5#
IfMatch=^$|^-1$|#*G5*#
IfMatchAction=[!SetVariable Color5G "0"][!SetVariable G5 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color5G "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor5Blue]
Measure=String
String=#B5#
IfMatch=^$|^-1$|#*B5*#
IfMatchAction=[!SetVariable Color5B "0"][!SetVariable B5 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color5B "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor6Red]
Measure=String
String=#R6#
IfMatch=^$|^-1$|#*R6*#
IfMatchAction=[!SetVariable Color6R "0"][!SetVariable R6 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color6R "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor6Green]
Measure=String
String=#G6#
IfMatch=^$|^-1$|#*G6*#
IfMatchAction=[!SetVariable Color6G "0"][!SetVariable G6 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color6G "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor6Blue]
Measure=String
String=#B6#
IfMatch=^$|^-1$|#*B6*#
IfMatchAction=[!SetVariable Color6B "0"][!SetVariable B6 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color6B "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor7Red]
Measure=String
String=#R7#
IfMatch=^$|^-1$|#*R7*#
IfMatchAction=[!SetVariable Color7R "0"][!SetVariable R7 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color7R "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor7Green]
Measure=String
String=#G7#
IfMatch=^$|^-1$|#*G7*#
IfMatchAction=[!SetVariable Color7G "0"][!SetVariable G7 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color7G "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor7Blue]
Measure=String
String=#B7#
IfMatch=^$|^-1$|#*B7*#
IfMatchAction=[!SetVariable Color7B "0"][!SetVariable B7 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color7B "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor8Red]
Measure=String
String=#R8#
IfMatch=^$|^-1$|#*R8*#
IfMatchAction=[!SetVariable Color8R "0"][!SetVariable R8 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color8R "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor8Green]
Measure=String
String=#G8#
IfMatch=^$|^-1$|#*G8*#
IfMatchAction=[!SetVariable Color8G "0"][!SetVariable G8 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color8G "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor8Blue]
Measure=String
String=#B8#
IfMatch=^$|^-1$|#*B8*#
IfMatchAction=[!SetVariable Color8B "0"][!SetVariable B8 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color8B "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor9Red]
Measure=String
String=#R9#
IfMatch=^$|^-1$|#*R9*#
IfMatchAction=[!SetVariable Color9R "0"][!SetVariable R9 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color9R "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor9Green]
Measure=String
String=#G9#
IfMatch=^$|^-1$|#*G9*#
IfMatchAction=[!SetVariable Color9G "0"][!SetVariable G9 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color9G "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor9Blue]
Measure=String
String=#B9#
IfMatch=^$|^-1$|#*B9*#
IfMatchAction=[!SetVariable Color9B "0"][!SetVariable B9 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color9B "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor10Red]
Measure=String
String=#R10#
IfMatch=^$|^-1$|#*R10*#
IfMatchAction=[!SetVariable Color10R "0"][!SetVariable R10 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color10R "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor10Green]
Measure=String
String=#G10#
IfMatch=^$|^-1$|#*G10*#
IfMatchAction=[!SetVariable Color10G "0"][!SetVariable G10 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color10G "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureColor10Blue]
Measure=String
String=#B10#
IfMatch=^$|^-1$|#*B10*#
IfMatchAction=[!SetVariable Color10B "0"][!SetVariable B10 "-1"][!UpdateMeasure "MeasureNumOfColors"]
IfNotMatchAction=[!SetVariable Color10B "1"][!UpdateMeasure "MeasureNumOfColors"]
UpdateDivider=-1
[MeasureNumOfColors]
Measure=Calc
Formula=( Floor (( 6 + #Color3R# + #Color3G# + #Color3B# + #Color4R# + #Color4G# + #Color4B# + #Color5R# + #Color5G# + #Color5B# + #Color6R# + #Color6G# + #Color6B# + #Color7R# + #Color7G# + #Color7B# + #Color8R# + #Color8G# + #Color8B# + #Color9R# + #Color9G# + #Color9B# + #Color10R# + #Color10G# + #Color10B# ) / 3 ))
DynamicVariables=1
UpdateDivider=-1
[MeterColor]
Meter=Image
SolidColor=(((#Range#<=(100/([MeasureNumOfColors]-1)))*(#R1#+(#Range#/(100/([MeasureNumOfColors]-1)))*(#R2#-#R1#)))+(((#Range#>(100/([MeasureNumOfColors]-1)))&&(#Range#<=(200/([MeasureNumOfColors]-1))))*(#R2#+((#Range#-(100/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R3#-#R2#)))+(((#Range#>(200/([MeasureNumOfColors]-1)))&&(#Range#<=(300/([MeasureNumOfColors]-1))))*(#R3#+((#Range#-(200/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R4#-#R3#)))+(((#Range#>(300/([MeasureNumOfColors]-1)))&&(#Range#<=(400/([MeasureNumOfColors]-1))))*(#R4#+((#Range#-(300/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R5#-#R4#)))+(((#Range#>(400/([MeasureNumOfColors]-1)))&&(#Range#<=(500/([MeasureNumOfColors]-1))))*(#R5#+((#Range#-(400/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R6#-#R5#)))+(((#Range#>(500/([MeasureNumOfColors]-1)))&&(#Range#<=(600/([MeasureNumOfColors]-1))))*(#R6#+((#Range#-(500/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R7#-#R6#)))+(((#Range#>(600/([MeasureNumOfColors]-1)))&&(#Range#<=(700/([MeasureNumOfColors]-1))))*(#R7#+((#Range#-(600/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R8#-#R7#)))+(((#Range#>(700/([MeasureNumOfColors]-1)))&&(#Range#<=(800/([MeasureNumOfColors]-1))))*(#R8#+((#Range#-(700/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R9#-#R8#)))+(((#Range#>(800/([MeasureNumOfColors]-1)))&&(#Range#<=(900/([MeasureNumOfColors]-1))))*(#R9#+((#Range#-(800/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R10#-#R9#)))),(((#Range#<=(100/([MeasureNumOfColors]-1)))*(#G1#+(#Range#/(100/([MeasureNumOfColors]-1)))*(#G2#-#G1#)))+(((#Range#>(100/([MeasureNumOfColors]-1)))&&(#Range#<=(200/([MeasureNumOfColors]-1))))*(#G2#+((#Range#-(100/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G3#-#G2#)))+(((#Range#>(200/([MeasureNumOfColors]-1)))&&(#Range#<=(300/([MeasureNumOfColors]-1))))*(#G3#+((#Range#-(200/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G4#-#G3#)))+(((#Range#>(300/([MeasureNumOfColors]-1)))&&(#Range#<=(400/([MeasureNumOfColors]-1))))*(#G4#+((#Range#-(300/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G5#-#G4#)))+(((#Range#>(400/([MeasureNumOfColors]-1)))&&(#Range#<=(500/([MeasureNumOfColors]-1))))*(#G5#+((#Range#-(400/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G6#-#G5#)))+(((#Range#>(500/([MeasureNumOfColors]-1)))&&(#Range#<=(600/([MeasureNumOfColors]-1))))*(#G6#+((#Range#-(500/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G7#-#G6#)))+(((#Range#>(600/([MeasureNumOfColors]-1)))&&(#Range#<=(700/([MeasureNumOfColors]-1))))*(#G7#+((#Range#-(600/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G8#-#G7#)))+(((#Range#>(700/([MeasureNumOfColors]-1)))&&(#Range#<=(800/([MeasureNumOfColors]-1))))*(#G8#+((#Range#-(700/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G9#-#G8#)))+(((#Range#>(800/([MeasureNumOfColors]-1)))&&(#Range#<=(900/([MeasureNumOfColors]-1))))*(#G9#+((#Range#-(800/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G10#-#G9#)))),(((#Range#<=(100/([MeasureNumOfColors]-1)))*(#B1#+(#Range#/(100/([MeasureNumOfColors]-1)))*(#B2#-#B1#)))+(((#Range#>(100/([MeasureNumOfColors]-1)))&&(#Range#<=(200/([MeasureNumOfColors]-1))))*(#B2#+((#Range#-(100/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B3#-#B2#)))+(((#Range#>(200/([MeasureNumOfColors]-1)))&&(#Range#<=(300/([MeasureNumOfColors]-1))))*(#B3#+((#Range#-(200/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B4#-#B3#)))+(((#Range#>(300/([MeasureNumOfColors]-1)))&&(#Range#<=(400/([MeasureNumOfColors]-1))))*(#B4#+((#Range#-(300/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B5#-#B4#)))+(((#Range#>(400/([MeasureNumOfColors]-1)))&&(#Range#<=(500/([MeasureNumOfColors]-1))))*(#B5#+((#Range#-(400/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B6#-#B5#)))+(((#Range#>(500/([MeasureNumOfColors]-1)))&&(#Range#<=(600/([MeasureNumOfColors]-1))))*(#B6#+((#Range#-(500/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B7#-#B6#)))+(((#Range#>(600/([MeasureNumOfColors]-1)))&&(#Range#<=(700/([MeasureNumOfColors]-1))))*(#B7#+((#Range#-(600/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B8#-#B7#)))+(((#Range#>(700/([MeasureNumOfColors]-1)))&&(#Range#<=(800/([MeasureNumOfColors]-1))))*(#B8#+((#Range#-(700/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B9#-#B8#)))+(((#Range#>(800/([MeasureNumOfColors]-1)))&&(#Range#<=(900/([MeasureNumOfColors]-1))))*(#B9#+((#Range#-(800/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B10#-#B9#))))
X=0
Y=0
W=100
H=50
DynamicVariables=1
MouseScrollDownAction=[!SetVariable Range "(Clamp((#Range#-1),0,100))"][!UpdateMeter "#CURRENTSECTION#"][!Redraw]
MouseScrollUpAction=[!SetVariable Range "(Clamp((#Range#+1),0,100))"][!UpdateMeter "#CURRENTSECTION#"][!Redraw]
Mine is just 1 measure more... Not my fault though: Rainmeter doesn't update variables in the same option (or measure, for that matter) they were changed, so...eclectic-tech wrote: ↑August 8th, 2020, 7:48 pm It's great to code as much as possible in native Rainmeter when it is practical.
But I think the Blend Color script is the easiest way to control blending colors, and controlling transparency, using a single measure.
blendcolor.gif
Lua and Rainmeter work very well together and this script provides maximum flexibility in controlling RGB color blending, and transparencies as a bonus.
Hi eclectic-techeclectic-tech wrote: ↑August 8th, 2020, 7:48 pm It's great to code as much as possible in native Rainmeter when it is practical.
But I think the Blend Color script is the easiest way to control blending colors, and controlling transparency, using a single measure.
blendcolor.gif
Lua and Rainmeter work very well together and this script provides maximum flexibility in controlling RGB color blending, and transparencies as a bonus.
Code: Select all
[Volume]
Measure=Plugin
Plugin=Win7AudioPlugin
[VolumeCalc]
Measure=Calc
Formula=Volume
MinValue=0
MaxValue=100
IfCondition=VolumeCalc <= 0
IfTrueAction=[#SO# VolIcon Text #T7#][#SO# VolIcon Padding 0,0,0,0]#U5#
IfCondition2=(VolumeCalc > 0) && (VolumeCalc <= 50)
IfTrueAction2=[#SO# VolIcon Text #T8#][#SO# VolIcon Padding -2,0,0,0]#U5#
IfCondition3=(VolumeCalc > 50)
IfTrueAction3=[#SO# VolIcon Text #T9#][#SO# VolIcon Padding 0,0,0,0]#U5#
[ExampleColorMeasure]
Measure=Script
ScriptFile=#@#BlendColor.lua
MeasureToBlend=VolumeCalc
RedScale=0,50,255,46|50,100,46,255
GreenScale=0,50,198,233|50,100,233,62
BlueScale=0,50,33,164|50,100,164,154
AlphaScale=0,100,220,220
[VolumeText]
Meter=String
MeterStyle=TextStyle
Text=VOL
[VolIcon]
Meter=String
MeterStyle=Lock
FontColor=[&ExampleColorMeasure]
DynamicVariables=1
Analized my copy of BlendColor.lua and discover at the very beginning of the file (line 1) a function Initialize() that was not commented; so i did change it in --function Initialize() (I guess I may just erase the line...) and the first error is fixed.
I think you should let that line there, as it belongs to a function. You should double check if you copied the script accordingly from eclectic-tech's post (don't mess with the encoding of the file, by the way, just paste in bare Notepad), because I tried his code again, this time in my @Resources folder and it works without issues.brax64 wrote: ↑August 9th, 2020, 12:04 am
Analized my copy of BlendColor.lua and discover at the very beginning of the file (line 1) a function Initialize() that was not commented; so i did change it in --function Initialize() (I guess I may just erase the line...) and the first error is fixed.
Now though I'm getting this:
Script: BlendColor.lua:47: attempt to index local 'inputMeter' (a nil value)
Apart from the fact that I'm not sure this is a problem with the code posted by eclectic-tech, this only confirms what I talked about earlier: when the Lua code needs to be adjusted (not sure it's the case here, but for the sake of the argument), the "practical" and "easy" Lua solution suddenly becomes a bit different for the regular user, unlike a native code one, where it is assumed the user knows more or less how to deal with it.
Why not trying to add colors into a string, like "255,0,0;0,255,0;0,0,255;..." and validate the colors or find their number based on that? I mean, I know it involves a bit of regex (or a bit more, LOL), but it would help avoid creating so many measures and allow you to do this in one or two measures instead...balala wrote: ↑August 8th, 2020, 6:48 pm Here is the promissed code. This time zou don!t have to use -1 for the components of the not used colors, all those components can be left empty (in the posted code the components of colors from 6 to 10 are left so).
Unfortunately I added even more measures (replaced the [MeasureColorX] measures with [MeasureColorXRed], [MeasureColorXGreen] and [MeasureColorXBlue]).
Please let me know your opinion.Code: Select all
[Rainmeter] Update=1000 [Variables] R1=198 G1=251 B1=200 R2=196 G2=92 B2=38 R3=14 G3=175 B3=67 R4=19 G4=196 B4=118 R5=58 G5=95 B5=5 R6= G6= B6= R7= G7= B7= R8= G8= B8= R9= G9= B9= R10= G10= B10= Range=0 [MeasureColor3Red] Measure=String String=#R3# IfMatch=^$|^-1$|#*R3*# IfMatchAction=[!SetVariable Color3R "0"][!SetVariable R3 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color3R "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor3Green] Measure=String String=#G3# IfMatch=^$|^-1$|#*G3*# IfMatchAction=[!SetVariable Color3G "0"][!SetVariable G3 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color3G "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor3Blue] Measure=String String=#B3# IfMatch=^$|^-1$|#*B3*# IfMatchAction=[!SetVariable Color3B "0"][!SetVariable B3 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color3B "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor4Red] Measure=String String=#R4# IfMatch=^$|^-1$|#*R4*# IfMatchAction=[!SetVariable Color4R "0"][!SetVariable R4 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color4R "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor4Green] Measure=String String=#G4# IfMatch=^$|^-1$|#*G4*# IfMatchAction=[!SetVariable Color4G "0"][!SetVariable G4 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color4G "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor4Blue] Measure=String String=#B4# IfMatch=^$|^-1$|#*B4*# IfMatchAction=[!SetVariable Color4B "0"][!SetVariable B4 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color4B "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor5Red] Measure=String String=#R5# IfMatch=^$|^-1$|#*R5*# IfMatchAction=[!SetVariable Color5R "0"][!SetVariable R5 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color5R "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor5Green] Measure=String String=#G5# IfMatch=^$|^-1$|#*G5*# IfMatchAction=[!SetVariable Color5G "0"][!SetVariable G5 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color5G "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor5Blue] Measure=String String=#B5# IfMatch=^$|^-1$|#*B5*# IfMatchAction=[!SetVariable Color5B "0"][!SetVariable B5 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color5B "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor6Red] Measure=String String=#R6# IfMatch=^$|^-1$|#*R6*# IfMatchAction=[!SetVariable Color6R "0"][!SetVariable R6 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color6R "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor6Green] Measure=String String=#G6# IfMatch=^$|^-1$|#*G6*# IfMatchAction=[!SetVariable Color6G "0"][!SetVariable G6 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color6G "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor6Blue] Measure=String String=#B6# IfMatch=^$|^-1$|#*B6*# IfMatchAction=[!SetVariable Color6B "0"][!SetVariable B6 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color6B "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor7Red] Measure=String String=#R7# IfMatch=^$|^-1$|#*R7*# IfMatchAction=[!SetVariable Color7R "0"][!SetVariable R7 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color7R "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor7Green] Measure=String String=#G7# IfMatch=^$|^-1$|#*G7*# IfMatchAction=[!SetVariable Color7G "0"][!SetVariable G7 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color7G "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor7Blue] Measure=String String=#B7# IfMatch=^$|^-1$|#*B7*# IfMatchAction=[!SetVariable Color7B "0"][!SetVariable B7 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color7B "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor8Red] Measure=String String=#R8# IfMatch=^$|^-1$|#*R8*# IfMatchAction=[!SetVariable Color8R "0"][!SetVariable R8 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color8R "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor8Green] Measure=String String=#G8# IfMatch=^$|^-1$|#*G8*# IfMatchAction=[!SetVariable Color8G "0"][!SetVariable G8 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color8G "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor8Blue] Measure=String String=#B8# IfMatch=^$|^-1$|#*B8*# IfMatchAction=[!SetVariable Color8B "0"][!SetVariable B8 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color8B "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor9Red] Measure=String String=#R9# IfMatch=^$|^-1$|#*R9*# IfMatchAction=[!SetVariable Color9R "0"][!SetVariable R9 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color9R "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor9Green] Measure=String String=#G9# IfMatch=^$|^-1$|#*G9*# IfMatchAction=[!SetVariable Color9G "0"][!SetVariable G9 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color9G "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor9Blue] Measure=String String=#B9# IfMatch=^$|^-1$|#*B9*# IfMatchAction=[!SetVariable Color9B "0"][!SetVariable B9 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color9B "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor10Red] Measure=String String=#R10# IfMatch=^$|^-1$|#*R10*# IfMatchAction=[!SetVariable Color10R "0"][!SetVariable R10 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color10R "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor10Green] Measure=String String=#G10# IfMatch=^$|^-1$|#*G10*# IfMatchAction=[!SetVariable Color10G "0"][!SetVariable G10 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color10G "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureColor10Blue] Measure=String String=#B10# IfMatch=^$|^-1$|#*B10*# IfMatchAction=[!SetVariable Color10B "0"][!SetVariable B10 "-1"][!UpdateMeasure "MeasureNumOfColors"] IfNotMatchAction=[!SetVariable Color10B "1"][!UpdateMeasure "MeasureNumOfColors"] UpdateDivider=-1 [MeasureNumOfColors] Measure=Calc Formula=( Floor (( 6 + #Color3R# + #Color3G# + #Color3B# + #Color4R# + #Color4G# + #Color4B# + #Color5R# + #Color5G# + #Color5B# + #Color6R# + #Color6G# + #Color6B# + #Color7R# + #Color7G# + #Color7B# + #Color8R# + #Color8G# + #Color8B# + #Color9R# + #Color9G# + #Color9B# + #Color10R# + #Color10G# + #Color10B# ) / 3 )) DynamicVariables=1 UpdateDivider=-1 [MeterColor] Meter=Image SolidColor=(((#Range#<=(100/([MeasureNumOfColors]-1)))*(#R1#+(#Range#/(100/([MeasureNumOfColors]-1)))*(#R2#-#R1#)))+(((#Range#>(100/([MeasureNumOfColors]-1)))&&(#Range#<=(200/([MeasureNumOfColors]-1))))*(#R2#+((#Range#-(100/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R3#-#R2#)))+(((#Range#>(200/([MeasureNumOfColors]-1)))&&(#Range#<=(300/([MeasureNumOfColors]-1))))*(#R3#+((#Range#-(200/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R4#-#R3#)))+(((#Range#>(300/([MeasureNumOfColors]-1)))&&(#Range#<=(400/([MeasureNumOfColors]-1))))*(#R4#+((#Range#-(300/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R5#-#R4#)))+(((#Range#>(400/([MeasureNumOfColors]-1)))&&(#Range#<=(500/([MeasureNumOfColors]-1))))*(#R5#+((#Range#-(400/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R6#-#R5#)))+(((#Range#>(500/([MeasureNumOfColors]-1)))&&(#Range#<=(600/([MeasureNumOfColors]-1))))*(#R6#+((#Range#-(500/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R7#-#R6#)))+(((#Range#>(600/([MeasureNumOfColors]-1)))&&(#Range#<=(700/([MeasureNumOfColors]-1))))*(#R7#+((#Range#-(600/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R8#-#R7#)))+(((#Range#>(700/([MeasureNumOfColors]-1)))&&(#Range#<=(800/([MeasureNumOfColors]-1))))*(#R8#+((#Range#-(700/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R9#-#R8#)))+(((#Range#>(800/([MeasureNumOfColors]-1)))&&(#Range#<=(900/([MeasureNumOfColors]-1))))*(#R9#+((#Range#-(800/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#R10#-#R9#)))),(((#Range#<=(100/([MeasureNumOfColors]-1)))*(#G1#+(#Range#/(100/([MeasureNumOfColors]-1)))*(#G2#-#G1#)))+(((#Range#>(100/([MeasureNumOfColors]-1)))&&(#Range#<=(200/([MeasureNumOfColors]-1))))*(#G2#+((#Range#-(100/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G3#-#G2#)))+(((#Range#>(200/([MeasureNumOfColors]-1)))&&(#Range#<=(300/([MeasureNumOfColors]-1))))*(#G3#+((#Range#-(200/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G4#-#G3#)))+(((#Range#>(300/([MeasureNumOfColors]-1)))&&(#Range#<=(400/([MeasureNumOfColors]-1))))*(#G4#+((#Range#-(300/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G5#-#G4#)))+(((#Range#>(400/([MeasureNumOfColors]-1)))&&(#Range#<=(500/([MeasureNumOfColors]-1))))*(#G5#+((#Range#-(400/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G6#-#G5#)))+(((#Range#>(500/([MeasureNumOfColors]-1)))&&(#Range#<=(600/([MeasureNumOfColors]-1))))*(#G6#+((#Range#-(500/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G7#-#G6#)))+(((#Range#>(600/([MeasureNumOfColors]-1)))&&(#Range#<=(700/([MeasureNumOfColors]-1))))*(#G7#+((#Range#-(600/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G8#-#G7#)))+(((#Range#>(700/([MeasureNumOfColors]-1)))&&(#Range#<=(800/([MeasureNumOfColors]-1))))*(#G8#+((#Range#-(700/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G9#-#G8#)))+(((#Range#>(800/([MeasureNumOfColors]-1)))&&(#Range#<=(900/([MeasureNumOfColors]-1))))*(#G9#+((#Range#-(800/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#G10#-#G9#)))),(((#Range#<=(100/([MeasureNumOfColors]-1)))*(#B1#+(#Range#/(100/([MeasureNumOfColors]-1)))*(#B2#-#B1#)))+(((#Range#>(100/([MeasureNumOfColors]-1)))&&(#Range#<=(200/([MeasureNumOfColors]-1))))*(#B2#+((#Range#-(100/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B3#-#B2#)))+(((#Range#>(200/([MeasureNumOfColors]-1)))&&(#Range#<=(300/([MeasureNumOfColors]-1))))*(#B3#+((#Range#-(200/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B4#-#B3#)))+(((#Range#>(300/([MeasureNumOfColors]-1)))&&(#Range#<=(400/([MeasureNumOfColors]-1))))*(#B4#+((#Range#-(300/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B5#-#B4#)))+(((#Range#>(400/([MeasureNumOfColors]-1)))&&(#Range#<=(500/([MeasureNumOfColors]-1))))*(#B5#+((#Range#-(400/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B6#-#B5#)))+(((#Range#>(500/([MeasureNumOfColors]-1)))&&(#Range#<=(600/([MeasureNumOfColors]-1))))*(#B6#+((#Range#-(500/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B7#-#B6#)))+(((#Range#>(600/([MeasureNumOfColors]-1)))&&(#Range#<=(700/([MeasureNumOfColors]-1))))*(#B7#+((#Range#-(600/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B8#-#B7#)))+(((#Range#>(700/([MeasureNumOfColors]-1)))&&(#Range#<=(800/([MeasureNumOfColors]-1))))*(#B8#+((#Range#-(700/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B9#-#B8#)))+(((#Range#>(800/([MeasureNumOfColors]-1)))&&(#Range#<=(900/([MeasureNumOfColors]-1))))*(#B9#+((#Range#-(800/([MeasureNumOfColors]-1)))/(100/([MeasureNumOfColors]-1)))*(#B10#-#B9#)))) X=0 Y=0 W=100 H=50 DynamicVariables=1 MouseScrollDownAction=[!SetVariable Range "(Clamp((#Range#-1),0,100))"][!UpdateMeter "#CURRENTSECTION#"][!Redraw] MouseScrollUpAction=[!SetVariable Range "(Clamp((#Range#+1),0,100))"][!UpdateMeter "#CURRENTSECTION#"][!Redraw]