Hy I worked my way throu TransformationMatrix Guide.
I did get my head around skewing and rotating so far so good. But what I acualy want to do is using TransformationMatrix to create Perspektive.
so to transform a plain square into some thing like this
Simple skewing does not do the trick since the the angle in all corners are difrent and the length of the vertical / horizontal are diffrent as well.
Has any one got the hang of this and can give me a hint.
It is currently April 27th, 2024, 10:55 am
Can I use TransformationMatrix to create perspektiv
-
- Posts: 49
- Joined: December 16th, 2020, 8:30 am
- Location: Switzerland
Can I use TransformationMatrix to create perspektiv
You do not have the required permissions to view the files attached to this post.
-
- Rainmeter Sage
- Posts: 1399
- Joined: April 24th, 2021, 8:13 pm
Re: Can I use TransformationMatrix to create perspektiv
No. But you can use MagickMeter if you are prepared to go to greater lengths to achieve it.sa1nt4ch wrote: ↑August 8th, 2021, 12:30 pm Hy I worked my way throu TransformationMatrix Guide.
I did get my head around skewing and rotating so far so good. But what I acualy want to do is using TransformationMatrix to create Perspektive.
so to transform a plain square into some thing like this Unbenannt.png
Simple skewing does not do the trick since the the angle in all corners are difrent and the length of the vertical / horizontal are diffrent as well.
Has any one got the hang of this and can give me a hint.
https://github.com/khanhas/MagickMeter
https://github.com/khanhas/MagickMeter#how-to-install
https://github.com/khanhas/MagickMeter/wiki
https://github.com/khanhas/MagickMeter/wiki/Effects#perspective
from the Realm of Death
-
- Posts: 49
- Joined: December 16th, 2020, 8:30 am
- Location: Switzerland
Re: Can I use TransformationMatrix to create perspektiv
sounds intersting will have a look at it.
can it distort only images or Meters as well. cose that will be the final goal.
can it distort only images or Meters as well. cose that will be the final goal.
-
- Rainmeter Sage
- Posts: 1399
- Joined: April 24th, 2021, 8:13 pm
Re: Can I use TransformationMatrix to create perspektiv
It can create images or distort images. And you need an image meter to use the image created.
So no, it can not distort meters. But you can create text and shapes with it and use it as meters.
https://github.com/khanhas/MagickMeter/wiki#measure-options
from the Realm of Death
-
- Posts: 49
- Joined: December 16th, 2020, 8:30 am
- Location: Switzerland
Re: Can I use TransformationMatrix to create perspektiv
Pitty, I intendet to do histograms and lines that disapere into the distance.
Some thing like this
Some thing like this
You do not have the required permissions to view the files attached to this post.
-
- Rainmeter Sage
- Posts: 7175
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Can I use TransformationMatrix to create perspektiv
You can use Path Shape meters and sin() and cos() to create perspective histograms, but it will be quite complicated and probably not worth the effort. You could even use a set of Line Shapes moving on the X axis and stretched on the Y axis to easier achieve your goal, but you won't be able to use the "histogram meter" for it, you'll have to simulate it manually, so to speak.
-
- Posts: 49
- Joined: December 16th, 2020, 8:30 am
- Location: Switzerland
Re: Can I use TransformationMatrix to create perspektiv
I went over the Matrix again, and figured that if I wanted to creat perspektiv I would need to muliply not with x but with a funktion.
-
- Rainmeter Sage
- Posts: 1399
- Joined: April 24th, 2021, 8:13 pm
Re: Can I use TransformationMatrix to create perspektiv
Perspective, by nature, needs z level transformation matrix. So, I don't think you can do it in Rainmeter, since it doesn't support it.
from the Realm of Death
-
- Rainmeter Sage
- Posts: 16176
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
Re: Can I use TransformationMatrix to create perspektiv
You can't by TransformationMatrix. See and read the last paragraph before the Help! It's not working! section and / or the first paragraph of the same Help! It's not working! section of TransformationMatrix Guide.
-
- Rainmeter Sage
- Posts: 7175
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Can I use TransformationMatrix to create perspektiv
Like balala mentioned, you can't achieve perspective with TransformationMatrix, because if you have two parallel lines, they'll still be parallel after skewing. In other words, you can't create a trapezoid from a rectangle, only a parallelogram.
What you want can only be achieved by building your shape more or less "manually". For example, here (and especially in the post afterwards) I built a histogram using a Path Shape. Now, if one appropriately modifies the angles between the path lines and gradually reduces the height of the histogram, he can create a perspective effect. Bear in mind though, that this is not particularly easy to do - but it's doable nevertheless. It only depends on how much you want it.