It is currently March 29th, 2024, 1:50 pm

Help me do this control brightnesses

Get help with creating, editing & fixing problems with skins
Vladik
Posts: 2
Joined: November 30th, 2020, 1:58 pm

Help me do this control brightnesses

Post by Vladik »

Use the volume slider to make the brightness slider.
Thanks in advance.

Code:

Code: Select all

[Rainmeter]
Update=100
AccurateText=1
DynamicWindowSize=1
BackgroundMode=2
SolidColor=0,0,0,1

[Variables]
VolumeIncrement=1

[MeasurePlayer]
Measure=Plugin
Plugin=Win7AudioPlugin.dll
MinValue=0
MaxValue=100

[MeasureVolume%]
Measure=Calc
Formula=MeasurePlayer
MinValue=0
MaxValue=100
UpdateDivider=1

[MeasureSetVolumeLevel]
Measure=Calc
Formula=#VolumeLevel#
DynamicVariables=1

[Volume]
Meter=Bar
BarOrientation=Vertical
MeasureName=MeasurePlayer
BarColor=243,255,8S
SolidColor=0,0,0
x=5
y=0
W=10
H=100
LeftMouseUpAction=[!SetVariable VolumeLevel "(100-$MouseY:%$)"][!Update][!CommandMeasure "MeasurePlayer" "SetVolume [MeasureSetVolumeLevel]"]
MouseScrollDownAction=[!CommandMeasure MeasurePlayer "ChangeVolume -#VolumeIncrement#"][!Update]
MouseScrollUpAction=[!CommandMeasure MeasurePlayer "ChangeVolume +#VolumeIncrement#"][!Update]
DynamicVariables=1

[MeterVolumeLevel]
MeasureName=MeasureVolume%
Meter=STRING
X=-5r
Y=3R
FontColor=220,220,220
SolidColor=0,0,0,1
FontEffectColor=0,0,0
StringEffect=Shadow
FontSize=8
FontFace=Segoe UI
StringStyle=BOLD
StringAlign=LEFT
AntiAlias=1
Text=%1%
DynamicVariables=1
Last edited by jsmorley on November 30th, 2020, 2:12 pm, edited 1 time in total.
Reason: Please use the code tags for embedding your code. It's the </> button at the top.
User avatar
nuxsh
Posts: 14
Joined: November 27th, 2020, 11:29 am

Re: Help me do this control brightnesses

Post by nuxsh »

You can use 'A screen brightness plugin' by Flying Hyrax

https://github.com/FlyingHyrax/rm-brightness-plugin/blob/master/README.md

I guess this is the part that you require...

Code: Select all

[meterBarBg]
Meter=Image
SolidColor=50,50,50,100
X=5
Y=30
W=140
H=10
LeftMouseUpAction=[!CommandMeasure "measureBrightness" "set $MouseX:%$"][!Update]
MouseScrollDownAction=[!CommandMeasure "measureBrightness" "lower"][!Update]
MouseScrollUpAction=[!CommandMeasure "measureBrightness" "raise"][!Update]
-- nuxsh
Vladik
Posts: 2
Joined: November 30th, 2020, 1:58 pm

Re: Help me do this control brightnesses

Post by Vladik »

nuxsh wrote: November 30th, 2020, 3:20 pm You can use 'A screen brightness plugin' by Flying Hyrax

https://github.com/FlyingHyrax/rm-brightness-plugin/blob/master/README.md

I guess this is the part that you require...

Code: Select all

[meterBarBg]
Meter=Image
SolidColor=50,50,50,100
X=5
Y=30
W=140
H=10
LeftMouseUpAction=[!CommandMeasure "measureBrightness" "set $MouseX:%$"][!Update]
MouseScrollDownAction=[!CommandMeasure "measureBrightness" "lower"][!Update]
MouseScrollUpAction=[!CommandMeasure "measureBrightness" "raise"][!Update]
Where to insert it? Could you change my code?
User avatar
nuxsh
Posts: 14
Joined: November 27th, 2020, 11:29 am

Re: Help me do this control brightnesses

Post by nuxsh »

Install the plugin to Documents\Rainmeter\Skins\@Vault\Plugins

This is your measure:

Code: Select all

[measureBrightness]
Measure=Plugin
Plugin=ScreenBrightness.dll
UpdateDivider=5
replace your first two measures with this one.

replace [Volume] with the meter that i have given in my first reply.
-- nuxsh
User avatar
balala
Rainmeter Sage
Posts: 16110
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Help me do this control brightnesses

Post by balala »

nuxsh wrote: December 1st, 2020, 2:37 am Install the plugin to Documents\Rainmeter\Skins\@Vault\Plugins
In fact the plugins have to be installed to c:\Users\<YourName>\AppData\Roaming\Rainmeter\Plugins\, according to the x64 or x86 version of your system.
The @Vault folder is used by Rainmeter to store a copy of the installed plugins, to let the user to have a backup copy of these plugins if later wants to use it.
Vladik wrote: November 30th, 2020, 3:38 pm Where to insert it? Could you change my code?
The easiest way to install a plugin is not to copy it manually, but to find a skin installer which contains the desired plugin and install it. This way you get installed the proper version of the plugin, to the proper folder. Unfortunately I couldn't find a skin installer which has this plugin, but there is another one, similar plugin, named Backlight. On this link there is a skin installer which if is run, installes the correct version of the plugin into the correct location, so you can use it. Try out the skin if you are intereseted, to see how does it work (for first simply download and install the previously posted Backlight_0.9.3.rmskin skin installer from the above link) and if it does what are you looking for, let me know, to further assist you in getting exactly what you need.
User avatar
nuxsh
Posts: 14
Joined: November 27th, 2020, 11:29 am

Re: Help me do this control brightnesses

Post by nuxsh »

balala wrote: December 1st, 2020, 8:56 am In fact the plugins have to be installed to c:\Users\<YourName>\AppData\Roaming\Rainmeter\Plugins\, according to the x64 or x86 version of your system.
The @Vault folder is used by Rainmeter to store a copy of the installed plugins, to let the user to have a backup copy of these plugins if later wants to use it.
Thank you. I didn't know that.
-- nuxsh
User avatar
balala
Rainmeter Sage
Posts: 16110
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Help me do this control brightnesses

Post by balala »

nuxsh wrote: December 1st, 2020, 12:03 pm Thank you. I didn't know that.
Yeah, it can be deceptive sometimes, I think.