| Index: src/core/SkBitmapProcState_matrix_template.h
|
| diff --git a/src/core/SkBitmapProcState_matrix_template.h b/src/core/SkBitmapProcState_matrix_template.h
|
| index 468013c30da958fda88e9cb60e53e04ad18263e2..2504a82f1d3ccf44e4137a98c588cf14ec9d4917 100644
|
| --- a/src/core/SkBitmapProcState_matrix_template.h
|
| +++ b/src/core/SkBitmapProcState_matrix_template.h
|
| @@ -25,10 +25,10 @@ void NoFilterProc_Scale(const SkBitmapProcState& s, uint32_t xy[],
|
| SkPoint pt;
|
| s.fInvProc(s.fInvMatrix, SkIntToScalar(x) + SK_ScalarHalf,
|
| SkIntToScalar(y) + SK_ScalarHalf, &pt);
|
| - fx = SkScalarToFractionalInt(pt.fY);
|
| + fx = SkScalarToFractionalInt(pt.fY) + SkFixedToFractionalInt(s.fInvBiasY);
|
| const unsigned maxY = s.fPixmap.height() - 1;
|
| *xy++ = TileProc::Y(s, SkFractionalIntToFixed(fx), maxY);
|
| - fx = SkScalarToFractionalInt(pt.fX);
|
| + fx = SkScalarToFractionalInt(pt.fX) + SkFixedToFractionalInt(s.fInvBiasX);
|
| }
|
|
|
| if (0 == maxX) {
|
| @@ -85,8 +85,8 @@ void NoFilterProc_Affine(const SkBitmapProcState& s, uint32_t xy[],
|
| SkIntToScalar(x) + SK_ScalarHalf,
|
| SkIntToScalar(y) + SK_ScalarHalf, &srcPt);
|
|
|
| - SkFractionalInt fx = SkScalarToFractionalInt(srcPt.fX);
|
| - SkFractionalInt fy = SkScalarToFractionalInt(srcPt.fY);
|
| + SkFractionalInt fx = SkScalarToFractionalInt(srcPt.fX) + SkFixedToFractionalInt(s.fInvBiasX);
|
| + SkFractionalInt fy = SkScalarToFractionalInt(srcPt.fY) + SkFixedToFractionalInt(s.fInvBiasY);
|
| SkFractionalInt dx = s.fInvSxFractionalInt;
|
| SkFractionalInt dy = s.fInvKyFractionalInt;
|
| int maxX = s.fPixmap.width() - 1;
|
| @@ -107,6 +107,7 @@ void NoFilterProc_Persp(const SkBitmapProcState& s, uint32_t* SK_RESTRICT xy,
|
| int maxX = s.fPixmap.width() - 1;
|
| int maxY = s.fPixmap.height() - 1;
|
|
|
| + // TODO: inv bias support
|
| SkPerspIter iter(s.fInvMatrix,
|
| SkIntToScalar(x) + SK_ScalarHalf,
|
| SkIntToScalar(y) + SK_ScalarHalf, count);
|
|
|