Page 1 of 1

Performance issues with ImageRotate Parameter

Posted: August 4th, 2018, 11:18 pm
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)

Re: Performance issues with ImageRotate Parameter

Posted: August 5th, 2018, 3:05 am
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

Re: Performance issues with ImageRotate Parameter

Posted: August 5th, 2018, 8:29 am
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.

Re: Performance issues with ImageRotate Parameter

Posted: August 5th, 2018, 2:48 pm
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.

Re: Performance issues with ImageRotate Parameter

Posted: August 5th, 2018, 2:53 pm
by balala
LGP123 wrote:(Maybe I have too much skins loaded :3)
How many do you have?

Re: Performance issues with ImageRotate Parameter

Posted: August 5th, 2018, 3:09 pm
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

Re: Performance issues with ImageRotate Parameter

Posted: August 5th, 2018, 3:17 pm
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.

Re: Performance issues with ImageRotate Parameter

Posted: August 5th, 2018, 4:43 pm
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.

Re: Performance issues with ImageRotate Parameter

Posted: August 5th, 2018, 4:51 pm
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"