From 9daa34f39272d43b85dc2c642a775d33da5a6ba8 Mon Sep 17 00:00:00 2001 From: David Manthey Date: Mon, 29 Jan 2024 13:58:52 -0500 Subject: [PATCH] Bypass some scaling code when compositing multi sources --- CHANGELOG.md | 6 ++++++ sources/multi/large_image_source_multi/__init__.py | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 131779763..d5e35ec62 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Change Log +## 1.27.2 + +### Improvements +- Support range requests when downloading DICOMweb files ([#1444](../../pull/1444)) +- Bypass some scaling code when compositing multi sources ([#1447](../../pull/1447)) + ## 1.27.1 ### Improvements diff --git a/sources/multi/large_image_source_multi/__init__.py b/sources/multi/large_image_source_multi/__init__.py index d1f87176a..06478ae47 100644 --- a/sources/multi/large_image_source_multi/__init__.py +++ b/sources/multi/large_image_source_multi/__init__.py @@ -1112,7 +1112,8 @@ def _addSourceToTile(self, tile, sourceEntry, corners, scale): transform[0][0] > 0 and transform[0][1] == 0 and transform[1][0] == 0 and transform[1][1] > 0 and transform[0][2] % scaleX == 0 and transform[1][2] % scaleY == 0)) and - (scaleX % scale) == 0 and (scaleY % scale) == 0): + ((scaleX % scale) == 0 or math.log(scaleX, 2).is_integer) and + ((scaleY % scale) == 0 or math.log(scaleY, 2).is_integer)) and False: srccorners = ( list(np.dot(bbox['inverse'], np.array(corners).T).T) if transform is not None else corners)