Просмотр исходного кода

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 лет назад
Родитель
Сommit
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.