mirror of
https://github.com/alicevision/Meshroom.git
synced 2025-06-08 05:42:02 +02:00
[ui] fix uvCenterOffset
Fix changes of principal point coord system from https://github.com/alicevision/meshroom/pull/1509.
This commit is contained in:
parent
1c66c6d9ab
commit
cd15a92318
1 changed files with 1 additions and 3 deletions
|
@ -345,9 +345,7 @@ class ViewpointWrapper(QObject):
|
||||||
return None
|
return None
|
||||||
pp = self.solvedIntrinsics["principalPoint"]
|
pp = self.solvedIntrinsics["principalPoint"]
|
||||||
# compute principal point offset in UV space
|
# compute principal point offset in UV space
|
||||||
uvPP = QVector2D(float(pp[0]) / self.imageSize.width(), float(pp[1]) / self.imageSize.height())
|
offset = QVector2D(float(pp[0]) / self.imageSize.width(), float(pp[1]) / self.imageSize.height())
|
||||||
# convert to offset
|
|
||||||
offset = uvPP - QVector2D(0.5, 0.5)
|
|
||||||
# apply orientation to principal point correction
|
# apply orientation to principal point correction
|
||||||
if self.orientation == 6:
|
if self.orientation == 6:
|
||||||
offset = QVector2D(-offset.y(), offset.x())
|
offset = QVector2D(-offset.y(), offset.x())
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue