Quantcast
Channel: Rainmeter Forums
Viewing all articles
Browse latest Browse all 1570

Help: Rainmeter Skins • Re: Need help about visualizer

$
0
0
Can someone help me turn the bar to the waveform like that? Or just help me rotate the wavefrom then i can place 2 wavefrom in wallpaper like this
Monstercat is a relatively complex skin that is using Bar meters, and those can have only two orientations, horizontal or vertical:
https://docs.rainmeter.net/manual/meters/bar/#BarOrientation
The approach from the other skin to use Shape meters is what's needed here, since once the coordinate arithmetic is figured out, they can be rotated:
https://docs.rainmeter.net/manual/meters/shape/#Rotate
Rotating visualizers is mentioned on the forum from time to time and I liked the idea, so here's a shorter, 10 band implementation:

Code:

[Variables]RadL=(Sqrt([#VisW]**2+[#VisH]**2)/2)VisW=(([#BarW]+[#GapW])*[#BarN]-[#GapW])VisH=([#BarH])CorR=([#BarW]/2)Mode=0StrW=1BarN=10BarW=8BarH=100GapW=8Scale=1Angle=0[Rainmeter]Update=50AccurateText=1DynamicWindowSize=1---Measures---[Out]Measure=PluginPlugin=AudioLevelPort=OutputFFTSize=1024FFTAttack=15FFTDecay=250Bands=[#BarN][Band0]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=0[Band1]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=1[Band2]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=2[Band3]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=3[Band4]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=4[Band5]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=5[Band6]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=6[Band7]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=7[Band8]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=8[Band9]Measure=PluginPlugin=AudioLevelParent=OutType=BandBandIdx=9---Meters---[Bars]Meter=ShapeX=(Round([#RadL]*[#Scale]))Y=(Round([#RadL]*[#Scale]))Shape=Ellipse 0,0,([#RadL]*[#Scale]) | Fill Color 0,0,0,32 | Stroke Color 128,128,128,(64+128*(1-[#Mode])) | StrokeWidth ([#StrW])Shape2=Rectangle (-[#VisW]/2*[#Scale]),(-[#VisH]/2*[#Scale]),([#VisW]*[#Scale]),([#VisH]*[#Scale]),([#CorR]*[#Scale]) | Fill RadialGradient GradS2 | Stroke Color 64,64,255,(64+128*[#Mode]) | StrokeWidth ([#StrW]) | Rotate ([#Angle]),([#VisW]/2*[#Scale]),([#VisH]/2*[#Scale])Shape3=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*0)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band0]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS3 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*0)*[#Scale]),(([#BarH]*[Band0]-[#VisH]/2)*[#Scale])Shape4=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*1)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band1]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS4 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*1)*[#Scale]),(([#BarH]*[Band1]-[#VisH]/2)*[#Scale])Shape5=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*2)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band2]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS5 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*2)*[#Scale]),(([#BarH]*[Band2]-[#VisH]/2)*[#Scale])Shape6=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*3)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band3]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS6 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*3)*[#Scale]),(([#BarH]*[Band3]-[#VisH]/2)*[#Scale])Shape7=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*4)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band4]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS7 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*4)*[#Scale]),(([#BarH]*[Band4]-[#VisH]/2)*[#Scale])Shape8=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*5)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band5]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS8 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*5)*[#Scale]),(([#BarH]*[Band5]-[#VisH]/2)*[#Scale])Shape9=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*6)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band6]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS9 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*6)*[#Scale]),(([#BarH]*[Band6]-[#VisH]/2)*[#Scale])Shape10=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*7)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band7]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS10 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*7)*[#Scale]),(([#BarH]*[Band7]-[#VisH]/2)*[#Scale])Shape11=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*8)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band8]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS11 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*8)*[#Scale]),(([#BarH]*[Band8]-[#VisH]/2)*[#Scale])Shape12=Rectangle ((-[#VisW]/2+([#BarW]+[#GapW])*9)*[#Scale]),([#VisH]/2*[#Scale]),([#BarW]*[#Scale]),(-[#BarH]*[Band9]*[#Scale]),([#CorR]*[#Scale]) | Fill LinearGradient GradS12 | Stroke Color 0,0,128,128 | StrokeWidth ([#StrW]) | Rotate ([#Angle]),(([#VisW]/2-([#BarW]+[#GapW])*9)*[#Scale]),(([#BarH]*[Band9]-[#VisH]/2)*[#Scale])GradS2=0,0 | 0,0,8,32 ; (0.0) | 0,0,16,32 ; (0.5) | 0,0,32,32 ; (1.0)GradS3=90 | 0,255,0,255 ; (0.0/([Band0]=0?1:[Band0])) | 255,255,0,255 ; (0.5/([Band0]=0?1:[Band0])) | 255,0,0,255 ; (1.0/([Band0]=0?1:[Band0]))GradS4=90 | 0,255,0,255 ; (0.0/([Band1]=0?1:[Band1])) | 255,255,0,255 ; (0.5/([Band1]=0?1:[Band1])) | 255,0,0,255 ; (1.0/([Band1]=0?1:[Band1]))GradS5=90 | 0,255,0,255 ; (0.0/([Band2]=0?1:[Band2])) | 255,255,0,255 ; (0.5/([Band2]=0?1:[Band2])) | 255,0,0,255 ; (1.0/([Band2]=0?1:[Band2]))GradS6=90 | 0,255,0,255 ; (0.0/([Band3]=0?1:[Band3])) | 255,255,0,255 ; (0.5/([Band3]=0?1:[Band3])) | 255,0,0,255 ; (1.0/([Band3]=0?1:[Band3]))GradS7=90 | 0,255,0,255 ; (0.0/([Band4]=0?1:[Band4])) | 255,255,0,255 ; (0.5/([Band4]=0?1:[Band4])) | 255,0,0,255 ; (1.0/([Band4]=0?1:[Band4]))GradS8=90 | 0,255,0,255 ; (0.0/([Band5]=0?1:[Band5])) | 255,255,0,255 ; (0.5/([Band5]=0?1:[Band5])) | 255,0,0,255 ; (1.0/([Band5]=0?1:[Band5]))GradS9=90 | 0,255,0,255 ; (0.0/([Band6]=0?1:[Band6])) | 255,255,0,255 ; (0.5/([Band6]=0?1:[Band6])) | 255,0,0,255 ; (1.0/([Band6]=0?1:[Band6]))GradS10=90 | 0,255,0,255 ; (0.0/([Band7]=0?1:[Band7])) | 255,255,0,255 ; (0.5/([Band7]=0?1:[Band7])) | 255,0,0,255 ; (1.0/([Band7]=0?1:[Band7]))GradS11=90 | 0,255,0,255 ; (0.0/([Band8]=0?1:[Band8])) | 255,255,0,255 ; (0.5/([Band8]=0?1:[Band8])) | 255,0,0,255 ; (1.0/([Band8]=0?1:[Band8]))GradS12=90 | 0,255,0,255 ; (0.0/([Band9]=0?1:[Band9])) | 255,255,0,255 ; (0.5/([Band9]=0?1:[Band9])) | 255,0,0,255 ; (1.0/([Band9]=0?1:[Band9]))LeftMouseUpAction=[!SetVariable Mode (1-[#Mode])][!UpdateMeter *][!Redraw]MouseScrollUpAction=[!SetVariable Scale (Clamp(([#Scale]+0.1*(1-[#Mode])),0.5,5))][!SetVariable Angle ((360+[#Angle]-1*[#Mode])%360)][!UpdateMeter *][!Redraw]MouseScrollDownAction=[!SetVariable Scale (Clamp(([#Scale]-0.1*(1-[#Mode])),0.5,5))][!SetVariable Angle ((360+[#Angle]+1*[#Mode])%360)][!UpdateMeter *][!Redraw]DynamicVariables=1
Rotated Visualizer.jpg
The math is not excessively complicated, once the rotation center / anchor point is determined correctly, as per the manual. Left click to toggle between scaling and rotating modes, scroll to scale or rotate depending on the chosen mode. Feel free to adjust this as desired or add more bands / shapes to it.

Statistics: Posted by Yincognito — 57 minutes ago



Viewing all articles
Browse latest Browse all 1570

Trending Articles