2 ===================================================================
3 --- sgl/SkEdge.cpp (revision 42965)
4 +++ sgl/SkEdge.cpp (working copy)
12 In setLine, setQuadratic, setCubic, the first thing we do is to convert
15 fX = SkFDot6ToFixed(x0 + SkFixedMul(slope, (32 - y0) & 63)); // + SK_Fixed1/2
17 - fFirstY = SkToS16(top);
18 - fLastY = SkToS16(bot - 1);
19 + fFirstY = (int16_t)(top); // inlined skToS16()
20 + if (top != (long)fFirstY) {
21 + if (fFirstY < top) {
22 + fFirstY = std::numeric_limits<int16_t>::max();
24 + fFirstY = std::numeric_limits<int16_t>::min();
26 + fX -= fDX * (top - (long)fFirstY);
28 + fLastY = (int16_t)(bot - 1); // inlined SkToS16()
29 + if (bot-1 != (long)fLastY) {
30 + if (fLastY < bot-1) {
31 + fLastY = std::numeric_limits<int16_t>::max();
33 + fLastY = std::numeric_limits<int16_t>::min();
37 fWinding = SkToS8(winding);