Need Help with meters

Help with creating, editing & fixing problems with skins

Need Help with meters

May 19th, 2017, 4:11 pm
Cellinarac
   [24 posts]

Hi everyone, I am new to the forums but have been using rainmeter for a while, mostly have been figuring out things on my own or doing some quick google searches. But now I have come across something that I can't figure out or find any real help on. I am making a new full desktop and making "modules" for everything. and for the most part it's all going very well, however here is my issue. I am trying to make a curved meter bar that fills depending on load, whether it be CPU, GPU, Ram or whatever. making a straight bar is no problem at all, however getting this curved bar has totally stumped me and I am looking for help figuring this out. I am attaching an image of the bar I am trying to make for reference.
BAR.png

any help would be much appreciated
thanks
User avatar

Re: Need Help with meters

May 19th, 2017, 4:22 pm
CyberTheWorm
   [441 posts]

You could try using shapes, https://docs.rainmeter.net/manual/meters/shape/#Arc
or try adapting the code from Simple Left/Right volume levels here https://docs.rainmeter.net/manual/plugins/audiolevel/

Better would be try and write something and then post your code. I'm sure someone will post something later.
User avatar

Re: Need Help with meters

May 19th, 2017, 4:26 pm
jsmorley
Developer   [16247 posts]

While it's tempting to jump to the Shape meter for this, it might be a lot simpler to just use an image in a Bar meter.

https://forum.rainmeter.net/viewtopic.php?f=118&t=16758

Re: Need Help with meters

May 19th, 2017, 4:46 pm
Cellinarac
   [24 posts]

jsmorley wrote:While it's tempting to jump to the Shape meter for this, it might be a lot simpler to just use an image in a Bar meter.

https://forum.rainmeter.net/viewtopic.php?f=118&t=16758


Thanks for the reply and link, which I am looking over now.
this is basically exactly what I was trying to do but not straight bars, those I can do (however I didn't know how to do the gradients until reading this). it's getting the curved meter working right that is killing me. basically the image above is what it would look like when filled. so say I am using 30% RAM, then 30% of the meter should be filled in and the rest either black (blank) or show the solidcolor 255,255,255,10 I set it to.
User avatar

Re: Need Help with meters

May 19th, 2017, 4:46 pm
jsmorley
Developer   [16247 posts]

It's going to be difficult to get what you are really looking for though. If you use BarImage like this:

Curve.png

Curve1.png


Code: Select all

[Rainmeter]
Update=100
DynamicWindowSize=1
AccurateText=1

[Variables]

[MeasureLoop]
Measure=Loop
StartValue=0
EndValue=50

[MeterBack]
Meter=Image
ImageName=#@#Images\Curve.png

[MeterBar]
Meter=Bar
MeasureName=MeasureLoop
BarImage=#@#Images\Curve1.png
BarOrientation=Horizontal


You get:
gif.gif


As you can see, while the visible part of the the image is "curved", it is treated as a rectangular meter, as are all meters in Rainmeter. So while it will "fill" to the current percentage, it's not filling in a curved way. It is just displaying the part of the red image that corresponds to the percentage, in a very linear, horizontal way.

I do think you can get better behavior with a Shape meter, but that is probably going to be a bit more complicated.

Re: Need Help with meters

May 19th, 2017, 4:54 pm
Cellinarac
   [24 posts]

Thank you!, I think I see one of my mistakes looking over your example. I will rework this and see how it comes out. I have to redo the whole thing anyway because I was getting aggravated and deleted the whole thing since I planned on starting over anyway after I got some "insight" on it :D

Re: Need Help with meters

May 20th, 2017, 12:22 pm
Cellinarac
   [24 posts]

ok, well I got this working but have come across another issue, when I use a non-transparent png, it works fine, but when I use a transparent png to make the background invisible so that only the bar shows, it doesn't show anything at all. is there any way to make this bar so that the rectangular background doesn't show up? this is what I am working on just for reference.

myself as well as a few friends of mine are big Knight Rider fans of the old 80s show so I have been working on making a fully functional desktop in the form of KITT's dash. this is one of the few problems I am having so far. but I think it feels "naked" without the functional meters that normally represent the RPM and MPH gauges of the car. which I would rather use those in place of some of the readouts I have on there now. one for CPU usage and one for RAM usage, network speed or something like that. another issue is, I am having a heck of a time getting the voice box to work as I entend it to. I have yet to figure out how to make a 3 band mirrored graphic EQ. I have even downloaded several and tried to rewrite them, but it never works right (if at all) to get the actual look of the 3 band voice modulation box in the center...
User avatar

Re: Need Help with meters

May 20th, 2017, 12:27 pm
jsmorley
Developer   [16247 posts]

Attach the image you are using to a reply here and also paste in the snippet of code that is displaying the bar meter in question.

Re: Need Help with meters

May 20th, 2017, 12:54 pm
Cellinarac
   [24 posts]

this is how everything looks,

so I am now trying to figure out why transparency doesn't work on the bar even though I have set the actual animation as.

Code: Select all

[Rainmeter]
Update=100
AccurateText=1
DynamicWindowSize=1

[MeasureInc]
Measure=Calc
Formula=(MeasureInc + 1) % 101
MinValue=0
MaxValue=100

[MeterBar1]
Meter=Bar
Y=100
MeasureName=MeasureInc
BarImage=#@#Images\CPU\KITTCPU.png
SolidColor=47,47,47,1
BarOrientation=Horizontal


this is a non-transparent png, when I try to use a transparent png created in photoshop to remove the rectangle, nothing displays at all, not even the bar. I would hope there is a way to enable transparency for this, because to me, it just feels naked not having those meters on the theme, and being able to use them for system monitor (CPU, RAM or network speed) would make it that much better because I hate non-functional things on my desktop, and if I am putting all this time into it for myself and also a few friends. I don't want an unfinished product, even if it is free lol
Last edited by fonpaolo on May 20th, 2017, 2:53 pm, edited 1 time in total.
Reason: Please use the [code] tags

Re: Need Help with meters

May 20th, 2017, 2:50 pm
Cellinarac
   [24 posts]

I thnk I got what I was looking for figured out


the code is

Code: Select all

[Rainmeter]
Update=900
MiddleMouseDownAction=!RainmeterDeactivateConfig

....................................................................................................................................................

[Variables]
FontName=LCDMono2 Bold
FontColor=255,0,0,255
FontSize=20
...................................................................................................................................................

[MeasureCPULoad]
Measure=CPU
MaxValue=100
MinValue=0

;[MeasureCPULoad]
Measure=Plugin
Plugin=Plugins\CoreTemp.dll
CoreTempType=Load
MaxValue=100
MinValue=0

[MeasureCPUModel]
Measure=Plugin
Plugin=Plugins\CoreTemp.dll
CoreTempType=CPUName

;Measure=CPU

;Plugin=Plugins\OpenHardwareMonitor.dll
;Hardware=AMD Phenom II X4 955 Processor
;Type=Load
;Sensor=CPU Total

........................................................................................................................................................

[Bar Background]
Meter=Image
SolidColor=25,25,25,0
X=1
Y=0


[MeterBar]
Meter=BAR
MeasureName=MeasureCPULoad
BarOrientation=Horizontal
BarImage=#@#Images\CPU\KITTCPU.bmp
SolidColor=47,47,47,1
BarOrientation=Horizontal
Last edited by fonpaolo on May 20th, 2017, 2:53 pm, edited 1 time in total.
Reason: Please use the [code] tags

Return to “Help: Rainmeter Skins”



Who is online

Users browsing this forum: Bing [Bot] and 6 guests