Lines Matching defs:bitmap
43 static SkPaint make_paint_with_image(const SkPaint& origPaint, const SkBitmap& bitmap,
47 paint.setShader(SkMakeBitmapShaderForPaint(origPaint, bitmap, SkTileMode::kClamp,
960 void SkDraw::drawBitmapAsMask(const SkBitmap& bitmap, const SkSamplingOptions& sampling,
962 SkASSERT(bitmap.colorType() == kAlpha_8_SkColorType);
970 if (SkTreatAsSprite(ctm, bitmap.dimensions(), sampling, paint))
976 if (!bitmap.peekPixels(&pmap)) {
987 } else { // need to xform the bitmap first
991 r.setIWH(bitmap.width(), bitmap.height());
995 // set the mask's bounds to the transformed bitmap-bounds,
1015 // allocate (and clear) our temp buffer to hold the transformed bitmap
1020 // now draw our bitmap(src) into mask(dst), transformed by the matrix
1037 SkPaint paintWithShader = make_paint_with_image(tmpPaint, bitmap, sampling);
1039 rr.setIWH(bitmap.width(), bitmap.height());
1064 void SkDraw::drawBitmap(const SkBitmap& bitmap, const SkMatrix& prematrix,
1071 bitmap.width() == 0 || bitmap.height() == 0 ||
1072 bitmap.colorType() == kUnknown_SkColorType) {
1084 if (clipped_out(matrix, *fRC, bitmap.width(), bitmap.height())) {
1088 if (bitmap.colorType() != kAlpha_8_SkColorType
1089 && SkTreatAsSprite(matrix, bitmap.dimensions(), sampling, *paint)) {
1095 if (!bitmap.peekPixels(&pmap)) {
1119 if (bitmap.colorType() == kAlpha_8_SkColorType && !paint->getColorFilter()) {
1120 draw.drawBitmapAsMask(bitmap, sampling, *paint);
1122 SkPaint paintWithShader = make_paint_with_image(*paint, bitmap, sampling);
1123 const SkRect srcBounds = SkRect::MakeIWH(bitmap.width(), bitmap.height());
1132 void SkDraw::drawSprite(const SkBitmap& bitmap, int x, int y, const SkPaint& origPaint) const {
1137 bitmap.width() == 0 || bitmap.height() == 0 ||
1138 bitmap.colorType() == kUnknown_SkColorType) {
1142 const SkIRect bounds = SkIRect::MakeXYWH(x, y, bitmap.width(), bitmap.height());
1152 if (!bitmap.peekPixels(&pmap)) {
1175 SkPaint paintWithShader = make_paint_with_image(paint, bitmap, SkSamplingOptions(), &matrix);