It is currently March 28th, 2024, 1:58 pm

Performance issues with ImageRotate Parameter

Report bugs with the Rainmeter application and suggest features.
Post Reply
User avatar
LGP123
Posts: 60
Joined: November 5th, 2016, 12:15 pm

Performance issues with ImageRotate Parameter

Post by LGP123 »

By doing my skins and so, I went to a big issue : Changing the ImageRotate option (via !Setoption bang seems to lag rainmeter.

Here is a small test skin :

Code: Select all

[Rainmeter]
Update=-1

[MeImg]
Meter=Image
ImageName=Icon.png
X=0
Y=0
H=70
W=70
MouseActionCursor=2
AntiAlias=1
MouseOverAction=[!SetOption MeImg ImageRotate "90"][!UpdateMeter "MeImg"][!Update]
MouseLeaveAction=[!SetOption MeImg ImageRotate "0"][!UpdateMeter "MeImg"][!Update]
UpdateDivider=-1
And the Image used :
Icon.png
So here, when we have our mouse over the meter it rotates it and when we leave the mouse it place it back.
The issue here is that there is a delay (~100ms) before the image to be rotated and it freezes all the skins (so it freezes rainmeter) until it does finish the rotation. You can see it with a VU meter or with animations in skins (like a rotating thing) ...
And the issue seems really to be because of the ImageRotate. For example, if we change the !Setoption imagerotate bang by a !Setoption Showmeter or things like so it is instant.

edit : The ImageTint parameter does also lag rainmeter (less than ImageRotate).
I think that the issue might come by the fact that changing those parameters makes rainmeter completely reload the Image (I'm not sure cuz I don't know how rainmeter is made)
User avatar
Brian
Developer
Posts: 2673
Joined: November 24th, 2011, 1:42 am
Location: Utah

Re: Performance issues with ImageRotate Parameter

Post by Brian »

I am not seeing much lag with this skin.

Adding some simple logging when the action is taken shows this:
ImageRotate.With.Update.png

Really, you should be using !Redraw instead of !Update here...but that only improves a little bit:
ImageRotate.With.Redraw.png
Here is what I used:

Code: Select all

[Rainmeter]
Update=-1

[MeImg]
Meter=Image
ImageName=Icon.png
X=0
Y=0
H=70
W=70
AntiAlias=1
MouseOverAction=[!Log "Over: Start"][!SetOption MeImg ImageRotate "90"][!UpdateMeter "MeImg"][!Redraw][!Log "Over: End"]
MouseLeaveAction=[!Log "Leave: Start"][!SetOption MeImg ImageRotate "0"][!UpdateMeter "MeImg"][!Redraw][!Log "Leave: End"]
UpdateDivider=-1
SolidColor=0,0,0,1
Note the use of SolidColor=0,0,0,1.

Also, MouseActionCursor=2 is not valid.

-Brian
User avatar
balala
Rainmeter Sage
Posts: 16109
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Performance issues with ImageRotate Parameter

Post by balala »

Brian wrote:I am not seeing much lag with this skin.
Completely agree. LGP123 I tested your code and couldn't find any delay, error messages or nothing else unusual. I also tried to load a visualizer skin, and it also works well, the rotation is made immediately. So, I don't see anything wrong.
User avatar
LGP123
Posts: 60
Joined: November 5th, 2016, 12:15 pm

Re: Performance issues with ImageRotate Parameter

Post by LGP123 »

Well I do have some delay :
1.png
It seems like my computer has hard time with this :(. (Maybe I have too much skins loaded :3)
Great that it doesn't concern everyone.
User avatar
balala
Rainmeter Sage
Posts: 16109
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Performance issues with ImageRotate Parameter

Post by balala »

LGP123 wrote:(Maybe I have too much skins loaded :3)
How many do you have?
User avatar
LGP123
Posts: 60
Joined: November 5th, 2016, 12:15 pm

Re: Performance issues with ImageRotate Parameter

Post by LGP123 »

balala wrote:How many do you have?
Got 12.

Well, even after unloading all my skins exept the test one, I still have some delay :
1.png
User avatar
balala
Rainmeter Sage
Posts: 16109
Joined: October 11th, 2010, 6:27 pm
Location: Gheorgheni, Romania

Re: Performance issues with ImageRotate Parameter

Post by balala »

LGP123 wrote:Got 12.
12 isn't too much, usually shouldn't have to create problems.
LGP123 wrote:Well, even after unloading all my skins exept the test one, I still have some delay :
Ok, please pack and upload the whole config. I'd like to check.
User avatar
LGP123
Posts: 60
Joined: November 5th, 2016, 12:15 pm

Re: Performance issues with ImageRotate Parameter

Post by LGP123 »

balala wrote:Ok, please pack and upload the whole config. I'd like to check.
I'll send them on PM since there are skins that aren't made by be.
User avatar
LGP123
Posts: 60
Joined: November 5th, 2016, 12:15 pm

Re: Performance issues with ImageRotate Parameter

Post by LGP123 »

Also, I have the issue with "SysInfo/Bin", just mouse over the green icon.
You can also compare it with the mouseover of "cleaner desktop" (Such a bad name, not mean to be published anyway :3)
And I made a mistake with cleaner desktop, you shall remove the "\" before the "Shortcut" at

Code: Select all

[MeFileView]
.
.
.
Path="#ROOTCONFIGPATH#\Shortcuts"
Post Reply