BUG=skia:
R=bungeman@google.com, alokp@google.com
Author: reed@google.com
Review URL: https://codereview.chromium.org/
200643003
git-svn-id: http://skia.googlecode.com/svn/trunk@13817
2bbb7eff-a529-9590-31e7-
b0007b416f81
#endif
static bool tooBigForLCD(const SkScalerContext::Rec& rec) {
- SkScalar area = SkScalarMul(rec.fPost2x2[0][0], rec.fPost2x2[1][1]) -
- SkScalarMul(rec.fPost2x2[1][0], rec.fPost2x2[0][1]);
- SkScalar size = SkScalarMul(area, rec.fTextSize);
- return SkScalarAbs(size) > SkIntToScalar(SK_MAX_SIZE_FOR_LCDTEXT);
+ SkScalar area = rec.fPost2x2[0][0] * rec.fPost2x2[1][1] -
+ rec.fPost2x2[1][0] * rec.fPost2x2[0][1];
+ SkScalar size = SkScalarSqrt(SkScalarAbs(area)) * rec.fTextSize;
+ return size > SkIntToScalar(SK_MAX_SIZE_FOR_LCDTEXT);
}
/*