Преглед изворни кода

Fix image fitter scaling images to 1 pixel too small

This previously worked in v4. Some logic has changed, so we may need to
revise how different pixel calculations are done over all of the
plugins.
cinaeco пре 3 година
родитељ
комит
abef6f0b3b
1 измењених фајлова са 2 додато и 2 уклоњено
  1. 2 2
      image_fitter_docker/image_fitter_docker.py

+ 2 - 2
image_fitter_docker/image_fitter_docker.py

@@ -112,8 +112,8 @@ class ImageFitter(DockWidget):
         # Repeated scaling does weird things to images.
         if self.scalingCheck.isChecked():
             doScaling = False
-            targetWidth = tbds['right'] - 1 - tbds['left']
-            targetHeight = tbds['bottom'] - 1 - tbds['top']
+            targetWidth = tbds['right'] - tbds['left']
+            targetHeight = tbds['bottom'] - tbds['top']
             layerWidth = bds.right() - bds.left()
             layerHeight = bds.bottom() - bds.top()
             # Deal with aspect ratio. Simply adjust target dimensions.