Skip to content

Commit

Permalink
use scale instead of targetSize
Browse files Browse the repository at this point in the history
  • Loading branch information
servantftechnicolor authored and cbentejac committed Oct 7, 2024
1 parent ebcbf9d commit ba739a5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions meshroom/ui/qml/Viewer/Viewer2D.qml
Original file line number Diff line number Diff line change
Expand Up @@ -476,6 +476,7 @@ FocusScope {
property int previousWidth: 0
property int previousHeight: 0
property real targetSize: Math.max(width, height) * imgContainer.scale
property real resizeRatio: imgContainer.scale
onHeightChanged: {
/* Image size is not updated through a single signal with the floatImage viewer, unlike
* the simple QML image viewer: instead of updating straight away the width and height to x and
Expand Down Expand Up @@ -520,6 +521,7 @@ FocusScope {
'cropFisheye': false,
'sequence': Qt.binding(function() { return ((root.enableSequencePlayer && (_reconstruction || (root.displayedNode && root.displayedNode.hasSequenceOutput))) ? getSequence() : []) }),
'targetSize': Qt.binding(function() { return floatImageViewerLoader.targetSize }),
'resizeRatio': Qt.binding(function() { return floatImageViewerLoader.resizeRatio }),
'useSequence': Qt.binding(function() {
return (root.enableSequencePlayer && !useExternal && (_reconstruction || (root.displayedNode && root.displayedNode.hasSequenceOutput && (displayedAttr.desc.semantic === "imageList" || displayedAttr.desc.semantic === "sequence"))))
}),
Expand Down

0 comments on commit ba739a5

Please sign in to comment.