It is currently April 27th, 2024, 4:16 pm

Non-rectangle Transform

Report bugs with the Rainmeter application and suggest features.
Unight
Posts: 19
Joined: November 20th, 2012, 5:12 am

Non-rectangle Transform

Post by Unight »

All meter area is a rectangular area, there is no possibility of establishing a non-rectangular changing? for example We can make some coordinate points used to determine the Transform effect

[imagedemo]
Meter=image
Imagename=”…”
X=0
Y=0
W=100
H=100
;Following the establishment of a few changes with the coordinates of the point,respectively, said the upper left corner,upper right corner,lower left corner,lower right corner
Dx1=10
Dy1=10
Dx2=100
Dy2=0
Dx3=10
Dy3=90
Dx4=100
Dy4=100

Then the image displayed is a trapezoidal appearance, the original image will be conducted to the corresponding scaling then the visual impact is more powerful.
You do not have the required permissions to view the files attached to this post.
User avatar
MerlinTheRed
Rainmeter Sage
Posts: 889
Joined: September 6th, 2011, 6:34 am

Re: Non-rectangle Transform

Post by MerlinTheRed »

There is the TransformationMatrix setting which can be used to scale, stretch, shear and rotate meters. Unfortunately it cannot do trapezoidal transformations yet.

If such a functionality is to be implemented (which I would very much appreciate and which I actually already suggested some time ago), I think it should be implemented in this TransformationMatrix framework rather than adding 8 new settings for each meter.

The downside of this would be that TransformationMatrix requires you to know linear algebra while your suggestion does not. The downside of your suggestion is that placing the four points incorrectly might lead to mathematical problems.
Have more fun creating skins with Sublime Text 2 and the Rainmeter Package!
poiru
Developer
Posts: 2872
Joined: April 17th, 2009, 12:18 pm

Re: Non-rectangle Transform

Post by poiru »

MerlinTheRed wrote:If such a functionality is to be implemented (which I would very much appreciate and which I actually already suggested some time ago), I think it should be implemented in this TransformationMatrix framework rather than adding 8 new settings for each meter.
We're currently using GDI+ to render content, which is strictly a 2D graphics framework (and an outdated one at that). Consequently, it does not natively support perspective transformations (AFAIK, the only way using GDI+ is to roll our own implementation an individually modify the pixels).

Our graphics situation may/will change in the future, but unfortunately the time frame is still very much open.
Unight
Posts: 19
Joined: November 20th, 2012, 5:12 am

Re: Non-rectangle Transform

Post by Unight »

MerlinTheRed wrote:There is the TransformationMatrix setting which can be used to scale, stretch, shear and rotate meters. Unfortunately it cannot do trapezoidal transformations yet.

If such a functionality is to be implemented (which I would very much appreciate and which I actually already suggested some time ago), I think it should be implemented in this TransformationMatrix framework rather than adding 8 new settings for each meter.

The downside of this would be that TransformationMatrix requires you to know linear algebra while your suggestion does not. The downside of your suggestion is that placing the four points incorrectly might lead to mathematical problems.
yes,I know TransformationMatrix,The above is just a simple proposal,As you say,By improve TransformationMatrix to achieve this effect may be a better idea :)