utils: fix rects_to_bands
This commit is contained in:
parent
13bcdecd1b
commit
82a62e3fd9
1 changed files with 3 additions and 2 deletions
|
|
@ -393,11 +393,11 @@ pub fn rects_to_bands(rects_tmp: &[RectRaw]) -> Container {
|
|||
let mut res = Container::new();
|
||||
|
||||
for &[y1, y2] in ys.array_windows_ext::<2>() {
|
||||
'bands: {
|
||||
loop {
|
||||
macro_rules! check_rect {
|
||||
($rect:expr) => {{
|
||||
if $rect.y1 != y1 {
|
||||
break 'bands;
|
||||
break;
|
||||
}
|
||||
rects.pop();
|
||||
if y2 < $rect.y2 {
|
||||
|
|
@ -422,6 +422,7 @@ pub fn rects_to_bands(rects_tmp: &[RectRaw]) -> Container {
|
|||
}
|
||||
res.push(RectRaw { x1, x2, y1, y2 });
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue