Skip to content

Commit

Permalink
UI: fixed fpe
Browse files Browse the repository at this point in the history
  • Loading branch information
mgerhardy committed Mar 26, 2022
1 parent d58d2b3 commit a337eca
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/modules/ui/imgui/dearimgui/imstb_truetype.h
Original file line number Diff line number Diff line change
Expand Up @@ -3201,7 +3201,9 @@ static void stbtt__fill_active_edges_new(float *scanline, float *scanline_fill,
// check if final y_crossing is blown up; no test case for this
if (y_final > y_bottom) {
y_final = y_bottom;
if (x2 - (x1+1) != 0) {
dy = (y_final - y_crossing ) / (x2 - (x1+1)); // if denom=0, y_final = y_crossing, so y_final <= y_bottom
}
}

// in second pixel, area covered by line segment found in first pixel
Expand Down

0 comments on commit a337eca

Please sign in to comment.