mirror of
https://github.com/SpaceManiac/SpacemanDMM.git
synced 2025-12-23 05:36:47 +00:00
Fix crop region checks on non-square maps
This commit is contained in:
parent
8917b39a2b
commit
1a652f39a2
1 changed files with 1 additions and 1 deletions
|
|
@ -38,7 +38,7 @@ pub fn generate(
|
|||
|
||||
// transform min/max from bottom-left-based to top-left-based
|
||||
// probably doesn't belong here
|
||||
let (_, len_y) = ctx.grid.dim();
|
||||
let (len_y, _) = ctx.grid.dim();
|
||||
let (min_y, max_y) = (len_y - ctx.max.1 - 1, len_y - ctx.min.1 - 1);
|
||||
let (len_x, len_y) = (ctx.max.0 - ctx.min.0 + 1, ctx.max.1 - ctx.min.1 + 1);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue