Agisoft Metashape
Agisoft Metashape => Python and Java API => Topic started by: mcstieg on December 24, 2019, 09:54:15 AM
-
Hello,
I try to rotate a model a given amount of degrees around x and y axis.
The python script for rotation around any axis is already working.
The Problem is, that the second rotation will result in an unwanted change of the first angle.
Example:
- We have 3 given Markers on a flat surface. 1 & 2 are horizontal and position 3 is anywhere on the surface.
- We also know the real angle between markers 1-2 and 2-3 because we measured them ... -20 degrees and +30 degrees.
If I rotate -20 degrees around vertical axis, 1-2 are perfectly matching -20 degrees.
How can I rotate the model now to reach a +30 degree angle between 2-3?
Thanks a lot!!!!!
-
Hello mcsteig,
Do you mean that you would like to perform the rotation around any line that should be defined as a pair of markers?
-
Dear Alexey,
sounds like what I am looking for ... :D
-
...if you have any information on how to calculate this - I would be very happy! Thank you!
Just found out how to calculate the rotation matrix for any axis and a given angle. Now I need to calculate the rotation angle only. But I think this should possible somehow.
Thank you!