Hello !
I am attempting to create a Python script to easily convert simple camera poses from Colmap to Agisoft, and the other way around.
I'm facing an issue with the camera coordinate system. I discovered that Colmap uses the following frame (from the camera's point of view):
[right, down, forwards] or [x, -y, -z].
However, I'm unable to find the coordinate frame used by Agisoft.
Do you have any insights into how I might resolve this issue?
My code is available here :
https://github.com/BCDavid/AgiPoses/Colmap camera1 0.97385556446084887 0.0013754180278881748 0.22599387574296945 0.023026417883844571 -5.4855674554568541 -0.73764511114013154 3.3757266221556628 1 DSC07956.JPG
Quaternion :
0.97385556446084887 0.0013754180278881748 0.22599387574296945 0.023026417883844571
Quaternion to 3x3 matrice :
0.8967931 -0.04422714 0.44023413
0.04547048 0.99893578 0.00772874
-0.44010744 0.01308658 0.89784975
Translation :
-5.4855674554568541
-0.73764511114013154
3.3757266221556628
Colmap camera matrice :
X (Right) -y (Down) -Z (Forwards) Translation
0.8967931 -0.04422714 0.44023413 -5.48556746
0.04547048 0.99893578 0.00772874 -0.73764511
-0.44010744 0.01308658 0.89784975 3.37572662
Agisoft camera<transform>7.7821820478012271e-01 8.1507179109980107e-02 -6.2268210629689480e-01 2.4353860387551292e+00 1.4932407108378803e-01 -9.8712015548332599e-01 5.7411849243326533e-02 -2.3594825709565909e-01 -6.0998257970516445e-01 -1.3766037335452860e-01 -7.8036585910976708e-01 -1.1088427336932636e+00 0 0 0 1</transform>
3x3 matrice :
7.7821820478012271e-01 8.1507179109980107e-02 -6.2268210629689480e-01
1.4932407108378803e-01 -9.8712015548332599e-01 5.7411849243326533e-02
-6.0998257970516445e-01 -1.3766037335452860e-01 -7.8036585910976708e-01
Translation :
2.4353860387551292e+00
-2.3594825709565909e-01
-1.1088427336932636e+00
Agisoft camera matrice :
7.7821820478012271e-01 8.1507179109980107e-02 -6.2268210629689480e-01 2.4353860387551292e+00
1.4932407108378803e-01 -9.8712015548332599e-01 5.7411849243326533e-02 -2.3594825709565909e-01
-6.0998257970516445e-01 -1.3766037335452860e-01 -7.8036585910976708e-01 -1.1088427336932636e+00