[nodes] PanoramaInit: fisheyeCenterOffset x/y are now 2 parameters on command line

Avoid error with negative values on "y" interpreted as a new argument
This commit is contained in:
Fabien Castan 2020-03-06 18:25:00 +01:00
parent 517014faf6
commit dcf91c244e
2 changed files with 7 additions and 6 deletions

View file

@ -242,14 +242,14 @@ FocusScope {
anchors.centerIn: parent
active: (_reconstruction.panoramaInit && displayFisheyeCircleLoader.checked)
sourceComponent: CircleGizmo {
x: _reconstruction.panoramaInit.attribute("fisheyeCenterOffset.x").value
y: _reconstruction.panoramaInit.attribute("fisheyeCenterOffset.y").value
x: _reconstruction.panoramaInit.attribute("fisheyeCenterOffset.fisheyeCenterOffset_x").value
y: _reconstruction.panoramaInit.attribute("fisheyeCenterOffset.fisheyeCenterOffset_y").value
radius: (imgContainer.image ? Math.min(imgContainer.image.width, imgContainer.image.height) : 1.0) * 0.5 * (_reconstruction.panoramaInit.attribute("fisheyeRadius").value * 0.01)
border.width: Math.max(1, (3.0 / imgContainer.scale))
onMoved: {
_reconstruction.setAttribute(_reconstruction.panoramaInit.attribute("fisheyeCenterOffset.x"), x)
_reconstruction.setAttribute(_reconstruction.panoramaInit.attribute("fisheyeCenterOffset.y"), y)
_reconstruction.setAttribute(_reconstruction.panoramaInit.attribute("fisheyeCenterOffset.fisheyeCenterOffset_x"), x)
_reconstruction.setAttribute(_reconstruction.panoramaInit.attribute("fisheyeCenterOffset.fisheyeCenterOffset_y"), y)
}
}
}