aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorVladimir Mandic <mandic00@live.com>2023-03-10 11:21:48 -0500
committerGitHub <noreply@github.com>2023-03-10 11:21:48 -0500
commit1226028b9c1b153b6ceef62d8678ecb84c9d4fcd (patch)
tree1d5b774165a221920ce19867d4bfcd06b9e5e967 /scripts
parent3c6459154fb115ea7cf1a0c5f3f0761a192dfea3 (diff)
fix silly math error
Diffstat (limited to 'scripts')
-rw-r--r--scripts/xyz_grid.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/xyz_grid.py b/scripts/xyz_grid.py
index 1ba954ac..8c816a73 100644
--- a/scripts/xyz_grid.py
+++ b/scripts/xyz_grid.py
@@ -485,7 +485,7 @@ class Script(scripts.Script):
zs = process_axis(z_opt, z_values)
# this could be moved to common code, but unlikely to be ever triggered anywhere else
- Image.MAX_IMAGE_PIXELS = opts.img_max_size_mp * 1.1 # allow 10% overhead for margins and legend
+ Image.MAX_IMAGE_PIXELS = opts.img_max_size_mp * 1000000 * 1.1 # allow 10% overhead for margins and legend
grid_mp = round(len(xs) * len(ys) * len(zs) * p.width * p.height / 1000000)
if grid_mp > opts.img_max_size_mp:
return Processed(p, [], p.seed, info=f'Error: Resulting grid would be too large ({grid_mp} MPixels) (max configured size is {opts.img_max_size_mp} MPixels)')