Skip to content

Commit

Permalink
Merge pull request rust-windowing#478 from s3bk/patch-3
Browse files Browse the repository at this point in the history
  • Loading branch information
jdm authored Oct 24, 2021
2 parents 6ce65b2 + 9909e44 commit a82bad9
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions renderer/src/tiler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -287,10 +287,16 @@ fn process_line_segment(line_segment: LineSegment2F,
match next_step_direction {
None => break,
Some(StepDirection::X) => {
if tile_coords.x() == to_tile_coords.x() {
break;
}
t_max += vec2f(t_delta.x(), 0.0);
tile_coords += vec2i(step.x(), 0);
}
Some(StepDirection::Y) => {
if tile_coords.y() == to_tile_coords.y() {
break;
}
t_max += vec2f(0.0, t_delta.y());
tile_coords += vec2i(0, step.y());
}
Expand Down

0 comments on commit a82bad9

Please sign in to comment.