It is currently March 28th, 2024, 5:18 pm

Specialised moving text.

Get help with creating, editing & fixing problems with skins
User avatar
kyriakos876
Posts: 919
Joined: January 30th, 2017, 2:01 am
Location: Greece

Re: Specialised moving text.

Post by kyriakos876 »

SilverDarkBlade wrote:Thank you :D

hopefully i wont need any more help
No problem ^_^ glad to help.

Even if you do I'm here :D
User avatar
SilverDarkBlade
Posts: 29
Joined: March 7th, 2017, 7:18 am

Re: Specialised moving text.

Post by SilverDarkBlade »

kyriakos876 wrote:No problem ^_^ glad to help.

Even if you do I'm here :D
hmm. while modifying your code slightly to fit my needs it seems to be overlapping again (albeit a lot less) im not sure what im doing wrong. im not sure what variables could effect this.

Code: Select all

[Rainmeter]
Group=SongInfo
Update=1000
DynamicWindowSize=1
SkinWidth=#Width#

; = IMPORTANT =
; = For configuring the rainmeter skin, right-click the visualizer and click on "Open variables".
; = You can also open the variables.ini file located in:
; = "My Documents\Rainmeter\Skins\Monstercat Visualizer\@Resources"

; Small context menu when you right-click the skin
ContextTitle=" Open settings"
ContextAction=[!ActivateConfig "#ROOTCONFIG#\Settings" "general.ini"]

[Metadata]
Name=Monstercat Visualizer for Rainmeter
Author=marcopixel
License=MIT License
Information=An realtime audio visualizer for Rainmeter similar to the ones used in the Monstercat videos.

[Variables]
; Width and speed used for calculations of scrolling text
Width=875
XValue=0
Repeat=0
; Includes the variables/styles used for the skin.
@include=#@#variables.ini
; Include MeasureGenre and Chameleon for dynamic colors.
@include2=#@#include\Measure#MPMode#.inc
@include3=#@#include\MeasureStyling.inc

; Meter - artist and track

[MeterArtist]
Meter=String
MeasureName=MeasureArtist
X=(#BarGap#*#ScaleVisualizer#)
Y=(30*#ScaleSongInformation#)
H=(100*#ScaleSongInformation#)
W=(#BarWidth#+#BarGap#)*(#BarCount#-12)*#ScaleVisualizer#
FontFace=#Font1#
FontSize=(#FontSize1#*#ScaleSongInformation#)
StringCase=Upper
AntiAlias=1
ClipString=2
Text="%1"
Group=SongMeta
Hidden=1

[MeterTrack]
Meter=String
MeasureName=MeasureTrack
X=(8*#ScaleSongInformation#)r
Y=104
H=(100*#ScaleSongInformation#)
W=(#BarWidth#+#BarGap#)*(#BarCount#-12)*#ScaleVisualizer#-(8*#ScaleSongInformation#)
FontFace=#Font2#
FontSize=(#FontSize2#*#ScaleSongInformation#)
StringCase=Upper
AntiAlias=1
ClipString=2
Text="%1"
Group=SongMeta
Hidden=0

; ------------------- This line seperates my testing of moving text from the rest of the monstercat stuff --------------------------
; ------------------- Track Text ---------------------------------------------------------------------------------------------------
[TextStyle]
MeasureName=MeasureTrack
FontSize=(#FontSize2#*#ScaleSongInformation#)
FontFace=#Font2#
StringCase=Upper
AntiAlias=1
Text="%1"

;  ------------------- Artist Text --------------------------------------------------------------------------------------------------

[TextStyle2]
MeasureName=MeasureArtist
FontSize=(#FontSize1#*#ScaleSongInformation#)
FontFace=#Font1#
StringCase=Upper
AntiAlias=1
Text="%1"

; ==Measures==
[MeasureRepeat]
Measure=Calc
Formula=((([MeterText2:W]>#Width#)*([MeterText2:W]*2)) + (([MeterText2:W]<#Width#)*((#Width#+[MeterText2:W])+[MeterText2:W])))
;Formula=((#Width#+[MeterText2:W])+([MeterText2:W]>#Width#)*([MeterText2:W]) )
IfCondition=1
IfTrueAction=[!SetVariable Repeat "[MeasureRepeat]"][!Update]
DynamicVariables=1

[MeasureX1]
Measure=Plugin
Plugin=ActionTimer
ActionList1=Repeat Action1 , 25 , #Repeat#
ActionList2=| Wait 3000 | Action2 | Repeat Action1 , 25 , #Repeat#
Action1=[!SetVariable XValue "(Clamp(#XValue#-2,(-#Width#-([MeterText2:W]>#Width#)*[MeterText2:W] ),#Width#))"][!Update]
Action2=[!SetVariable XValue "0"][!Update]
DynamicVariables=1

[MeasureWait2]
Measure=Calc
Formula=-[MeterText2:W]
IfCondition=(((#XValue#=-#Width#) && ([MeterText2:W]<#Width#)) || (([MeterText2:W]>#Width#) && (#XValue#<=[MeasureWait2])))
IfTrueAction=[!CommandMeasure MeasureX1 "Stop 1"][!CommandMeasure MeasureX1 "Stop 2"][!CommandMeasure MeasureX1 "Execute 2"]
DynamicVariables=1

;==== METERS ====            

[MeterText2]
Meter=String
MeterStyle=TextStyle2
X=(#XValue#+(#BarGap#*#ScaleVisualizer#))
Y=(30*#ScaleSongInformation#)
W=(#BarWidth#+#BarGap#)*(#BarCount#-12)*#ScaleVisualizer#-(8*#ScaleSongInformation#)
H=(100*#ScaleSongInformation#)
FontColor=255,255,255
AntiAlias=1
DynamicVariables=1

[MeterText2Mirror]
Meter=String
MeterStyle=TextStyle2
X=((([MeterText2:W]>#Width#)*(([MeterText2:W]) + (#XValue#)))+(([MeterText2:W]<#Width#)*(#Width#+#XValue#))+(#BarGap#*#ScaleVisualizer#))
Y=(30*#ScaleSongInformation#)
W=(#BarWidth#+#BarGap#)*(#BarCount#-12)*#ScaleVisualizer#-(8*#ScaleSongInformation#)
H=(100*#ScaleSongInformation#)
FontColor=255,255,255
AntiAlias=1
DynamicVariables=1

[MeterBackground2]
Meter=Image
SolidColor=0,0,0,1
MouseOverAction=[!CommandMeasure MeasureX1 "Execute 1"]
MouseLeaveAction=[!CommandMeasure MeasureX1 "Stop 1"][!CommandMeasure MeasureX1 "Stop 2"][!SetVariable XValue "0"][!Update]
W=#Width#
H=([MeterText2:H])
DynamicVariables=1
User avatar
kyriakos876
Posts: 919
Joined: January 30th, 2017, 2:01 am
Location: Greece

Re: Specialised moving text.

Post by kyriakos876 »

SilverDarkBlade wrote:hmm. while modifying your code slightly to fit my needs it seems to be overlapping again (albeit a lot less) im not sure what im doing wrong. im not sure what variables could effect this.
Do you mind uploading your whole skin? I want to check something in your measures, as those are the only variables that could cause an issue.
User avatar
SilverDarkBlade
Posts: 29
Joined: March 7th, 2017, 7:18 am

Re: Specialised moving text.

Post by SilverDarkBlade »

kyriakos876 wrote:Do you mind uploading your whole skin? I want to check something in your measures, as those are the only variables that could cause an issue.
alright here they are, i also included my layout (its on a second monitor so idk how useful it might be

keep in mind this is the test version. the file in song info named test is the one i have began integrating your code into (unfinished) and "Left" is what i am moving code from into yours.

so far the only part worked on is artist name, song name is unimplemented.
Monstercatlayout.zip
the layout. careful as this includes my wallpaper so it may overwrite yours. also it contains some plugins you wont have so ignore those. also its on my second monitor lol.
(144.94 KiB) Downloaded 27 times
Monstercat-Visualizer.zip
the skin
(3.58 MiB) Downloaded 26 times
User avatar
kyriakos876
Posts: 919
Joined: January 30th, 2017, 2:01 am
Location: Greece

Re: Specialised moving text.

Post by kyriakos876 »

SilverDarkBlade wrote:alright here they are, i also included my layout (its on a second monitor so idk how useful it might be

keep in mind this is the test version. the file in song info named test is the one i have began integrating your code into (unfinished) and "Left" is what i am moving code from into yours.

so far the only part worked on is artist name, song name is unimplemented.
Ok, now I need you to describe me when does the overlapping happens.
1) What .ini file are you running when this occurs?
2) What Meters work as expected and what meters don't?
3) Does the overlapping happens only when the text it greater than the width or does it happen in all cases?
4) Are you moving my code into "Left.ini" or the code from "Left.ini to my code? (Just to make sure I got it right.)
5) When you say "...i have began integrating your code into (unfinished)..." you mean you haven't completely modified my code into the other file? Because if that's the case you should do that first and when you are done modifying it check again. Even a dot misplaced, could mess everything up, let alone if you have yet to add a whole measure/meter into the file.

Make sure 5 is out of the way and then answer me 1-4 :D

(Sorry I can't check it myself but I don't have/use spotify so I can't really check the whole skin. I just need to know when this happens and on what meters so that I can tell you what variables could effect it.)
User avatar
SilverDarkBlade
Posts: 29
Joined: March 7th, 2017, 7:18 am

Re: Specialised moving text.

Post by SilverDarkBlade »

kyriakos876 wrote:Ok, now I need you to describe me when does the overlapping happens.
1) What .ini file are you running when this occurs?
2) What Meters work as expected and what meters don't?
3) Does the overlapping happens only when the text it greater than the width or does it happen in all cases?
4) Are you moving my code into "Left.ini" or the code from "Left.ini to my code? (Just to make sure I got it right.)
5) When you say "...i have began integrating your code into (unfinished)..." you mean you haven't completely modified my code into the other file? Because if that's the case you should do that first and when you are done modifying it check again. Even a dot misplaced, could mess everything up, let alone if you have yet to add a whole measure/meter into the file.

Make sure 5 is out of the way and then answer me 1-4 :D

(Sorry I can't check it myself but I don't have/use spotify so I can't really check the whole skin. I just need to know when this happens and on what meters so that I can tell you what variables could effect it.)
5.everything is moved over correctly (i think) its just i haven't started moving the song text, only artist. (two lines of text in the same code)

4.im moving it from left to test. (test being originally your code).

3.overlapping seems to only happen when over 22ish letters. (which is about 3 letters longer than the textwidth)

2. everything including the meters works as expected except the overlapping

1. the running ini is "Test" in "Song Information". there is a lot more meters running aswell bt it happens when test is the only running one too

hope this helps you figure out whats happening.
User avatar
kyriakos876
Posts: 919
Joined: January 30th, 2017, 2:01 am
Location: Greece

Re: Specialised moving text.

Post by kyriakos876 »

SilverDarkBlade wrote:
hope this helps you figure out whats happening.
You have done everything correctly in the modification except for one thing. I noticed that in "Test.ini" the width of the [MeterText2:W] never changes no matter the content of the text. This happens because you have set it as static. In the code you have:

Code: Select all

[MeterText2]
Meter=String
MeterStyle=TextStyle2
X=(#XValue#+(#BarGap#*#ScaleVisualizer#))
Y=(30*#ScaleSongInformation#)
W=(#BarWidth#+#BarGap#)*(#BarCount#-12)*#ScaleVisualizer#-(8*#ScaleSongInformation#)
H=(100*#ScaleSongInformation#)
FontColor=255,255,255
AntiAlias=1
DynamicVariables=1
The line W=(#BarWidth#+#BarGap#)*(#BarCount#-12)*#ScaleVisualizer#-(8*#ScaleSongInformation#)
Will set the width of this meter to 1158 no matter what. You want to delete that line and you should be okay.

Keep in mind that this is probably there for some reason so if you remove it you might see something else messed up. In the best case scenario, this is just a safety border set from the writer of the original skin.
User avatar
SilverDarkBlade
Posts: 29
Joined: March 7th, 2017, 7:18 am

Re: Specialised moving text.

Post by SilverDarkBlade »

kyriakos876 wrote:You have done everything correctly in the modification except for one thing. I noticed that in "Test.ini" the width of the [MeterText2:W] never changes no matter the content of the text. This happens because you have set it as static. In the code you have:

Code: Select all

[MeterText2]
Meter=String
MeterStyle=TextStyle2
X=(#XValue#+(#BarGap#*#ScaleVisualizer#))
Y=(30*#ScaleSongInformation#)
W=(#BarWidth#+#BarGap#)*(#BarCount#-12)*#ScaleVisualizer#-(8*#ScaleSongInformation#)
H=(100*#ScaleSongInformation#)
FontColor=255,255,255
AntiAlias=1
DynamicVariables=1
The line W=(#BarWidth#+#BarGap#)*(#BarCount#-12)*#ScaleVisualizer#-(8*#ScaleSongInformation#)
Will set the width of this meter to 1158 no matter what. You want to delete that line and you should be okay.

Keep in mind that this is probably there for some reason so if you remove it you might see something else messed up. In the best case scenario, this is just a safety border set from the writer of the original skin.
ah thank you. il try experimenting with that
User avatar
kyriakos876
Posts: 919
Joined: January 30th, 2017, 2:01 am
Location: Greece

Re: Specialised moving text.

Post by kyriakos876 »

SilverDarkBlade wrote:ah thank you. il try experimenting with that
Let me know how it works.

P.S. You have set in both, [TextStyle2] and [MeterText2] the command AntiAlias=1. I find that one is enough and you can delete it from either [TextStyle2] or both the [MeterText2] and [MeterText2Mirror]. Or leave it as it is, it won't affect the code, it just that 1 isn't needed.
User avatar
SilverDarkBlade
Posts: 29
Joined: March 7th, 2017, 7:18 am

Re: Specialised moving text.

Post by SilverDarkBlade »

kyriakos876 wrote:Let me know how it works.

P.S. You have set in both, [TextStyle2] and [MeterText2] the command AntiAlias=1. I find that one is enough and you can delete it from either [TextStyle2] or both the [MeterText2] and [MeterText2Mirror]. Or leave it as it is, it won't affect the code, it just that 1 isn't needed.
thank you. i had just changed the W option and it fixed it. il remove some of the redundant in my code :P

however another issue i ran into lol. Increasing the space between the 2 text versions makes it reset early.
Post Reply