/external/skia/gm/ |
D | anisotropic.cpp | 34 fBM.allocN32Pixels(kImageSize, kImageSize, true); in onOnceBeforeDraw() 36 SkCanvas canvas(fBM); in onOnceBeforeDraw() 58 canvas->drawBitmapRect(fBM, r, &p); in draw() 68 int height = SkScalarFloorToInt(fBM.height() * gScales[i]); in onDraw() 72 yOff = kSpacer + i * (fBM.height() + kSpacer); in onDraw() 75 yOff = (SK_ARRAY_COUNT(gScales) - i) * (fBM.height() + kSpacer) - height; in onDraw() 78 this->draw(canvas, kSpacer, yOff, fBM.width(), height); in onDraw() 83 int width = SkScalarFloorToInt(fBM.width() * gScales[i]); in onDraw() 87 xOff = fBM.width() + 2*kSpacer; in onDraw() 88 yOff = kSpacer + i * (fBM.height() + kSpacer); in onDraw() [all …]
|
D | filterbitmap.cpp | 50 SkScalar cx = SkScalarHalf(fBM.width()); in onOnceBeforeDraw() 51 SkScalar cy = SkScalarHalf(fBM.height()); in onOnceBeforeDraw() 63 SkBitmap fBM; member in FilterBitmapGM 89 SkSize size = computeSize(fBM, fMatrix[i]); in onDraw() 93 draw_row(canvas, fBM, fMatrix[i], size.fWidth); in onDraw() 118 fBM.allocN32Pixels(int(fTextSize * 8), int(fTextSize * 6)); in makeBitmap() 119 SkCanvas canvas(fBM); in makeBitmap() 158 fBM.allocN32Pixels(fSize, fSize); in makeBitmap() 161 SkPMColor* s = fBM.getAddr32(x, y); in makeBitmap() 173 fBM.copyTo(&tmp, kGray_8_SkColorType); in makeBitmap() [all …]
|
D | downsamplebitmap.cpp | 39 SkBitmap fBM; member in DownsampleBitmapGM 66 return SkISize::Make(fBM.width(), 4 * fBM.height()); in onISize() 95 canvas->drawBitmap(fBM, 0, 0, &paint); in onDraw() 98 curHeight = (int) (fBM.height() * curScale + 2); in onDraw() 101 } while (curHeight >= 2 && curY < 4*fBM.height()); in onDraw() 120 fBM.allocN32Pixels(int(fTextSize * 8), int(fTextSize * 6)); in make_bitmap() 121 SkCanvas canvas(fBM); in make_bitmap() 155 make_checker(&fBM, fSize, fNumChecks); in make_bitmap() 182 codec->decode(&stream, &fBM, kN32_SkColorType, SkImageDecoder::kDecodePixels_Mode); in make_bitmap() 185 fBM.allocN32Pixels(1, 1); in make_bitmap() [all …]
|
D | giantbitmap.cpp | 22 SkBitmap* fBM; member in GiantBitmapGM 28 if (nullptr == fBM) { in getBitmap() 29 fBM = new SkBitmap; in getBitmap() 30 fBM->allocN32Pixels(W, H); in getBitmap() 31 fBM->eraseColor(SK_ColorWHITE); in getBitmap() 37 SkCanvas canvas(*fBM); in getBitmap() 59 return *fBM; in getBitmap() 63 GiantBitmapGM(SkShader::TileMode mode, bool doFilter, bool doRotate) : fBM(nullptr) { in GiantBitmapGM() 69 virtual ~GiantBitmapGM() { delete fBM; } in ~GiantBitmapGM()
|
D | filterindiabox.cpp | 49 SkScalar cx = SkScalarHalf(fBM.width()); in onOnceBeforeDraw() 50 SkScalar cy = SkScalarHalf(fBM.height()); in onOnceBeforeDraw() 60 SkBitmap fBM; member in FilterIndiaBoxGM 84 SkSize size = computeSize(fBM, fMatrix[i]); in onDraw() 88 draw_row(canvas, fBM, fMatrix[i], size.fWidth); in onDraw() 110 codec->decode(&stream, &fBM, kN32_SkColorType, SkImageDecoder::kDecodePixels_Mode); in makeBitmap() 113 fBM.allocN32Pixels(1, 1); in makeBitmap() 114 *(fBM.getAddr32(0,0)) = 0xFF0000FF; // red == bad in makeBitmap() 116 fSize = fBM.height(); in makeBitmap()
|
D | showmiplevels.cpp | 78 SkBitmap fBM[4]; member in ShowMipLevels 110 fBM[0] = sk_tool_utils::create_checkerboard_bitmap(N, N, SK_ColorBLACK, SK_ColorWHITE, 2); in ShowMipLevels() 111 fBM[1] = make_bitmap(N, N); in ShowMipLevels() 112 fBM[2] = make_bitmap2(N, N); in ShowMipLevels() 113 fBM[3] = make_bitmap3(N, N); in ShowMipLevels() 203 for (const auto& bm : fBM) { in onDraw() 222 SkBitmap fBM[4]; member in ShowMipLevels2 226 fBM[0] = sk_tool_utils::create_checkerboard_bitmap(w, h, SHOW_MIP_COLOR, SK_ColorWHITE, 2); in ShowMipLevels2() 227 fBM[1] = make_bitmap(w, h); in ShowMipLevels2() 228 fBM[2] = make_bitmap2(w, h); in ShowMipLevels2() [all …]
|
D | pixelxorxfermode.cpp | 35 codec->decode(&stream, &fBM, kN32_SkColorType, SkImageDecoder::kDecodePixels_Mode); in onOnceBeforeDraw() 38 fBM.allocN32Pixels(1, 1); in onOnceBeforeDraw() 39 fBM.eraseARGB(255, 255, 0 , 0); // red == bad in onOnceBeforeDraw() 44 canvas->drawBitmap(fBM, 0, 0); in onDraw() 86 SkBitmap fBM; member in PixelXorXfermodeGM
|
D | avoidxfermode.cpp | 35 codec->decode(&stream, &fBM, kN32_SkColorType, SkImageDecoder::kDecodePixels_Mode); in onOnceBeforeDraw() 38 fBM.allocN32Pixels(1, 1); in onOnceBeforeDraw() 39 fBM.eraseARGB(255, 255, 0 , 0); // red == bad in onOnceBeforeDraw() 44 canvas->drawBitmap(fBM, 0, 0); in onDraw() 92 SkBitmap fBM; member in AvoidXfermodeGM
|
D | image_pict.cpp | 111 RasterGenerator(const SkBitmap& bm) : SkImageGenerator(bm.info()), fBM(bm) { in RasterGenerator() 112 fBM.lockPixels(); in RasterGenerator() 117 SkASSERT(fBM.width() == info.width()); in onGetPixels() 118 SkASSERT(fBM.height() == info.height()); in onGetPixels() 121 if (SkColorTable* ct = fBM.getColorTable()) { in onGetPixels() 130 memcpy(pixels, fBM.getAddr8(0, y), fBM.width()); in onGetPixels() 138 return fBM.readPixels(info, pixels, rowBytes, 0, 0); in onGetPixels() 142 SkBitmap fBM; member in RasterGenerator
|
D | bitmaprect.cpp | 231 SkBitmap fBM; member in BitmapRectRounding 248 fBM.allocN32Pixels(10, 10); in onOnceBeforeDraw() 249 fBM.eraseColor(SK_ColorBLUE); in onOnceBeforeDraw() 266 canvas->drawBitmapRect(fBM, r, nullptr); in onDraw()
|
/external/skia/samplecode/ |
D | SampleSubpixelTranslate.cpp | 37 codec->decode(&stream, &fBM, kN32_SkColorType, SkImageDecoder::kDecodePixels_Mode); in SubpixelTranslateView() 40 fBM.allocN32Pixels(1, 1); in SubpixelTranslateView() 41 *(fBM.getAddr32(0,0)) = 0xFF0000FF; // red == bad in SubpixelTranslateView() 48 SkBitmap fBM; member in SubpixelTranslateView 80 canvas->drawBitmapRect( fBM, r, &paint ); in onDrawContent() 89 canvas->drawBitmapRect( fBM, r, &paint ); in onDrawContent() 96 …canvas->drawBitmap( fBM, fCurPos.fX + i * (fBM.width() + 10), fCurPos.fY + 2*(fSize + 10), &paint … in onDrawContent() 99 …o Scale", strlen("AA No Scale"), fCurPos.fX + SK_ARRAY_COUNT(gQualitys) * (fBM.width() + 10), fCur… in onDrawContent() 104 …canvas->drawBitmap( fBM, fCurPos.fX + i * (fBM.width() + 10), fCurPos.fY + 2*(fSize + 10) + fBM.he… in onDrawContent() 107 …cale"), fCurPos.fX + SK_ARRAY_COUNT(gQualitys) * (fBM.width() + 10), fCurPos.fY + 2*(fSize + 10) +… in onDrawContent()
|
D | SampleDither.cpp | 114 SkBitmap fBM, fBMPreDither, fBM16; member in DitherView 118 make_bm(&fBM); in DitherView() 121 fBM.copyTo(&fBM16, kARGB_4444_SkColorType); in DitherView() 142 const SkScalar DX = SkIntToScalar(fBM.width() + 10); in onDrawContent() 147 canvas->drawBitmap(fBM, x, y, &paint); in onDrawContent() 150 canvas->drawBitmap(fBM, x, y, &paint); in onDrawContent() 161 draw_sweep(canvas, fBM.width(), fBM.height(), fAngle); in onDrawContent() 163 draw_sweep(canvas, fBM.width()>>1, fBM.height()>>1, fAngle); in onDrawContent() 165 draw_sweep(canvas, fBM.width()>>2, fBM.height()>>2, fAngle); in onDrawContent()
|
D | SampleIdentityScale.cpp | 35 codec->decode(&stream, &fBM, kN32_SkColorType, SkImageDecoder::kDecodePixels_Mode); in IdentityScaleView() 38 fBM.allocN32Pixels(1, 1); in IdentityScaleView() 39 *(fBM.getAddr32(0,0)) = 0xFF0000FF; // red == bad in IdentityScaleView() 44 SkBitmap fBM; member in IdentityScaleView 80 canvas->drawBitmap( fBM, 100, 100, &paint ); in onDrawContent()
|
D | SampleTextureDomain.cpp | 29 SkBitmap fBM; member in TextureDomainView 33 fBM = make_bitmap(); in TextureDomainView() 56 canvas->drawBitmapRect(fBM, srcRect, dstRect, &paint, SkCanvas::kStrict_SrcRectConstraint); in onDrawContent() 67 surface->getCanvas()->drawBitmapRect(fBM, srcRect, dstRect, &paint, in onDrawContent() 101 canvas->drawBitmapRect(fBM, dstRect, &paint); in onDrawContent()
|
D | SampleTinyBitmap.cpp | 42 SkBitmap fBM; member in TinyBitmapView 45 fBM = make_bitmap(); in TinyBitmapView() 65 SkShader* s = SkShader::CreateBitmapShader(fBM, SkShader::kRepeat_TileMode, in onDrawContent()
|
D | SampleBlur.cpp | 54 SkBitmap fBM; member in BlurView 58 fBM = make_bitmap(); in BlurView()
|
/external/skia/src/utils/ |
D | SkImageGeneratorUtils.cpp | 24 GeneratorFromBitmap(const SkBitmap& bm) : SkImageGenerator(bm.info()), fBM(bm) { in GeneratorFromBitmap() 26 bm.copyTo(&fBM); in GeneratorFromBitmap() 33 return fBM.readPixels(info, pixels, rowBytes, 0, 0); in onGetPixels() 37 SkBitmap fBM; member in GeneratorFromBitmap
|
/external/skia/src/ports/ |
D | SkFontHost_win.cpp | 421 fBM = 0; in HDCOffscreen() 431 if (fBM) { in ~HDCOffscreen() 432 DeleteObject(fBM); in ~HDCOffscreen() 445 HBITMAP fBM; member in HDCOffscreen 473 if (fBM && (fIsBW != isBW || fWidth < glyph.fWidth || fHeight < glyph.fHeight)) { in draw() 474 DeleteObject(fBM); in draw() 475 fBM = 0; in draw() 484 if (0 == fBM) { in draw() 502 fBM = CreateDIBSection(fDC, &info, DIB_RGB_COLORS, &fBits, 0, 0); in draw() 503 if (0 == fBM) { in draw() [all …]
|