#41: Stop iterator when y exceeds one pixel beyond quadrant bounds.

This commit is contained in:
Andrew 2021-05-09 12:45:24 -07:00
parent 4bb355aec6
commit a68b24ab9c

View file

@ -317,8 +317,8 @@ impl Iterator for QuadrantIterator {
self.p.x = -(self.radius as i16);
self.p.y += 1;
}
if self.p.y > 0 as i16 {
break item;
if self.p.y > 1 as i16 {
break None;
}
if item.is_some() {
break item;
@ -329,8 +329,8 @@ impl Iterator for QuadrantIterator {
self.p.x = 0;
self.p.y += 1;
}
if self.p.y > 0 as i16 {
break item;
if self.p.y > 1 as i16 {
break None;
}
if item.is_some() {
break item;