Home
last modified time | relevance | path

Searched refs:fBitmap (Results 1 – 25 of 114) sorted by relevance

12345

/external/skia/gm/
Dxfermodeimagefilter.cpp38 fBitmap = sk_tool_utils::create_string_bitmap(80, 80, 0xD000D000, 15, 65, 96, "e"); in onOnceBeforeDraw()
88 DrawClippedBitmap(canvas, fBitmap, paint, x, y); in onDraw()
89 x += fBitmap.width() + MARGIN; in onDraw()
90 if (x + fBitmap.width() > WIDTH) { in onDraw()
92 y += fBitmap.height() + MARGIN; in onDraw()
98 DrawClippedBitmap(canvas, fBitmap, paint, x, y); in onDraw()
99 x += fBitmap.width() + MARGIN; in onDraw()
100 if (x + fBitmap.width() > WIDTH) { in onDraw()
102 y += fBitmap.height() + MARGIN; in onDraw()
106 DrawClippedBitmap(canvas, fBitmap, paint, x, y); in onDraw()
[all …]
Dtileimagefilter.cpp38 fBitmap = SkImage::MakeFromBitmap( in onOnceBeforeDraw()
59 sk_sp<SkImage> image = (i & 0x01) ? fCheckerboard : fBitmap; in onDraw()
76 canvas->drawImage(fBitmap.get(), 0, 0, &paint); in onDraw()
92 SkRect srcRect = SkRect::MakeWH(SkIntToScalar(fBitmap->width()), in onDraw()
93 SkIntToScalar(fBitmap->height())); in onDraw()
94 SkRect dstRect = SkRect::MakeWH(SkIntToScalar(fBitmap->width() * 2), in onDraw()
95 SkIntToScalar(fBitmap->height() * 2)); in onDraw()
105 canvas->drawImage(fBitmap.get(), 0, 0); in onDraw()
127 sk_sp<SkImage> fBitmap, fCheckerboard; member in skiagm::TileImageFilterGM
Dmorphology.cpp29 fBitmap.allocN32Pixels(135, 135); in onOnceBeforeDraw()
30 SkCanvas canvas(fBitmap); in onOnceBeforeDraw()
48 SkIntToScalar(fBitmap.width()), SkIntToScalar(fBitmap.height()))); in drawClippedBitmap()
49 canvas->drawBitmap(fBitmap, 0, 0, &paint); in drawClippedBitmap()
87 SkBitmap fBitmap; member in skiagm::MorphologyGM
/external/skqp/gm/
Dxfermodeimagefilter.cpp38 fBitmap = sk_tool_utils::create_string_bitmap(80, 80, 0xD000D000, 15, 65, 96, "e"); in onOnceBeforeDraw()
88 DrawClippedBitmap(canvas, fBitmap, paint, x, y); in onDraw()
89 x += fBitmap.width() + MARGIN; in onDraw()
90 if (x + fBitmap.width() > WIDTH) { in onDraw()
92 y += fBitmap.height() + MARGIN; in onDraw()
98 DrawClippedBitmap(canvas, fBitmap, paint, x, y); in onDraw()
99 x += fBitmap.width() + MARGIN; in onDraw()
100 if (x + fBitmap.width() > WIDTH) { in onDraw()
102 y += fBitmap.height() + MARGIN; in onDraw()
106 DrawClippedBitmap(canvas, fBitmap, paint, x, y); in onDraw()
[all …]
Dtileimagefilter.cpp38 fBitmap = SkImage::MakeFromBitmap( in onOnceBeforeDraw()
59 sk_sp<SkImage> image = (i & 0x01) ? fCheckerboard : fBitmap; in onDraw()
76 canvas->drawImage(fBitmap.get(), 0, 0, &paint); in onDraw()
92 SkRect srcRect = SkRect::MakeWH(SkIntToScalar(fBitmap->width()), in onDraw()
93 SkIntToScalar(fBitmap->height())); in onDraw()
94 SkRect dstRect = SkRect::MakeWH(SkIntToScalar(fBitmap->width() * 2), in onDraw()
95 SkIntToScalar(fBitmap->height() * 2)); in onDraw()
105 canvas->drawImage(fBitmap.get(), 0, 0); in onDraw()
127 sk_sp<SkImage> fBitmap, fCheckerboard; member in skiagm::TileImageFilterGM
Dmorphology.cpp29 fBitmap.allocN32Pixels(135, 135); in onOnceBeforeDraw()
30 SkCanvas canvas(fBitmap); in onOnceBeforeDraw()
48 SkIntToScalar(fBitmap.width()), SkIntToScalar(fBitmap.height()))); in drawClippedBitmap()
49 canvas->drawBitmap(fBitmap, 0, 0, &paint); in drawClippedBitmap()
87 SkBitmap fBitmap; member in skiagm::MorphologyGM
/external/skqp/src/image/
DSkSurface_Raster.cpp31 SkBitmap fBitmap; member in SkSurface_Raster
75 fBitmap.installPixels(info, pixels, rb, releaseProc, context); in SkSurface_Raster()
84 fBitmap.setInfo(info, pr->rowBytes()); in SkSurface_Raster()
86 fBitmap.setPixelRef(std::move(pr), 0, 0); in SkSurface_Raster()
90 SkCanvas* SkSurface_Raster::onNewCanvas() { return new SkCanvas(fBitmap, this->props()); } in onNewCanvas()
98 canvas->drawBitmap(fBitmap, x, y, paint); in onDraw()
103 SkASSERT(SkIRect::MakeWH(fBitmap.width(), fBitmap.height()).contains(*subset)); in onNewImageSnapshot()
105 dst.allocPixels(fBitmap.info().makeWH(subset->width(), subset->height())); in onNewImageSnapshot()
106 SkAssertResult(fBitmap.readPixels(dst.pixmap(), subset->left(), subset->top())); in onNewImageSnapshot()
115 if (SkPixelRef* pr = fBitmap.pixelRef()) { in onNewImageSnapshot()
[all …]
DSkImage_Raster.cpp76 return fBitmap.info(); in onImageInfo()
81 const SkBitmap* onPeekBitmap() const override { return &fBitmap; } in onPeekBitmap()
91 SkPixelRef* getPixelRef() const { return fBitmap.pixelRef(); } in getPixelRef()
99 , fBitmap(bm) in SkImage_Raster()
101 SkASSERT(bitmapMayBeMutable || fBitmap.isImmutable()); in SkImage_Raster()
111 SkASSERT(fBitmap.pixelRef()); in notifyAddedToRasterCache()
112 fBitmap.pixelRef()->notifyAddedToCache(); in notifyAddedToRasterCache()
122 SkBitmap fBitmap; member in SkImage_Raster
146 fBitmap.installPixels(info, addr, rowBytes, release_data, data.release()); in SkImage_Raster()
147 fBitmap.setImmutable(); in SkImage_Raster()
[all …]
/external/mesa3d/src/gallium/targets/haiku-softpipe/
DSoftwareRenderer.cpp47 fBitmap(NULL), in SoftwareRenderer()
80 fContextID = fContextObj->CreateContext(fBitmap); in SoftwareRenderer()
101 if (fBitmap) in ~SoftwareRenderer()
102 delete fBitmap; in ~SoftwareRenderer()
120 if (fBitmap && cs == fColorSpace && fContextObj->Validate(fWidth, fHeight)) { in LockGL()
121 fContextObj->SetCurrentContext(fBitmap, fContextID); in LockGL()
128 fContextObj->SetCurrentContext(fBitmap, fContextID); in LockGL()
148 if (!fBitmap) in SwapBuffers()
159 GLView()->DrawBitmap(fBitmap, B_ORIGIN); in SwapBuffers()
169 != fBitmap->Bounds().IntegerHeight() in SwapBuffers()
[all …]
/external/skia/src/image/
DSkSurface_Raster.cpp31 SkBitmap fBitmap; member in SkSurface_Raster
75 fBitmap.installPixels(info, pixels, rb, releaseProc, context); in SkSurface_Raster()
84 fBitmap.setInfo(info, pr->rowBytes()); in SkSurface_Raster()
86 fBitmap.setPixelRef(std::move(pr), 0, 0); in SkSurface_Raster()
90 SkCanvas* SkSurface_Raster::onNewCanvas() { return new SkCanvas(fBitmap, this->props()); } in onNewCanvas()
98 canvas->drawBitmap(fBitmap, x, y, paint); in onDraw()
103 SkASSERT(SkIRect::MakeWH(fBitmap.width(), fBitmap.height()).contains(*subset)); in onNewImageSnapshot()
105 dst.allocPixels(fBitmap.info().makeWH(subset->width(), subset->height())); in onNewImageSnapshot()
106 SkAssertResult(fBitmap.readPixels(dst.pixmap(), subset->left(), subset->top())); in onNewImageSnapshot()
115 if (SkPixelRef* pr = fBitmap.pixelRef()) { in onNewImageSnapshot()
[all …]
DSkImage_Raster.cpp76 return fBitmap.info(); in onImageInfo()
81 const SkBitmap* onPeekBitmap() const override { return &fBitmap; } in onPeekBitmap()
91 SkPixelRef* getPixelRef() const { return fBitmap.pixelRef(); } in getPixelRef()
99 , fBitmap(bm) in SkImage_Raster()
101 SkASSERT(bitmapMayBeMutable || fBitmap.isImmutable()); in SkImage_Raster()
112 SkASSERT(fBitmap.pixelRef()); in notifyAddedToRasterCache()
113 fBitmap.pixelRef()->notifyAddedToCache(); in notifyAddedToRasterCache()
124 SkBitmap fBitmap; member in SkImage_Raster
148 fBitmap.installPixels(info, addr, rowBytes, release_data, data.release()); in SkImage_Raster()
149 fBitmap.setImmutable(); in SkImage_Raster()
[all …]
/external/skqp/src/android/
DSkAnimatedImage.cpp37 if (!image->fDisplayFrame.fBitmap.getPixels()) { in Make()
56 if (!image->fDisplayFrame.fBitmap.getPixels()) { in Make()
79 if (!fDecodingFrame.fBitmap.tryAllocPixels(fDecodeInfo)) { in SkAnimatedImage()
103 if (fBitmap.getPixels()) { in init()
104 if (fBitmap.pixelRef()->unique()) { in init()
105 SkAssertResult(fBitmap.setAlphaType(info.alphaType())); in init()
118 memcpy(tmp.getPixels(), fBitmap.getPixels(), fBitmap.computeByteSize()); in init()
120 swap(tmp, fBitmap); in init()
125 return fBitmap.tryAllocPixels(info); in init()
129 if (!dst->init(fBitmap.info(), OnInit::kNoRestore)) { in copyTo()
[all …]
/external/skqp/tools/skdiff/
Dskdiff_utils.cpp57 if (!resource.fBitmap.setInfo(info.makeColorType(kN32_SkColorType))) { in get_bitmap()
67 if (!resource.fBitmap.tryAllocPixels()) { in get_bitmap()
73 if (SkCodec::kSuccess != codec->getPixels(resource.fBitmap.info(), in get_bitmap()
74 resource.fBitmap.getPixels(), resource.fBitmap.rowBytes())) { in get_bitmap()
148 const int w = drp->fBase.fBitmap.width(); in create_and_write_diff_image()
149 const int h = drp->fBase.fBitmap.height(); in create_and_write_diff_image()
151 if (w != drp->fComparison.fBitmap.width() || h != drp->fComparison.fBitmap.height()) { in create_and_write_diff_image()
154 drp->fDifference.fBitmap.allocN32Pixels(w, h); in create_and_write_diff_image()
156 drp->fWhite.fBitmap.allocN32Pixels(w, h); in create_and_write_diff_image()
179 if (write_bitmap(drp->fDifference.fFullPath, drp->fDifference.fBitmap)) { in create_and_write_diff_image()
[all …]
Dskdiff.cpp159 const int w = dr->fComparison.fBitmap.width(); in compute_diff()
160 const int h = dr->fComparison.fBitmap.height(); in compute_diff()
161 if (w != dr->fBase.fBitmap.width() || h != dr->fBase.fBitmap.height()) { in compute_diff()
177 SkPMColor c0 = *dr->fBase.fBitmap.getAddr32(x, y); in compute_diff()
178 SkPMColor c1 = *dr->fComparison.fBitmap.getAddr32(x, y); in compute_diff()
205 *dr->fDifference.fBitmap.getAddr32(x, y) = outputDifference; in compute_diff()
206 *dr->fWhite.fBitmap.getAddr32(x, y) = PMCOLOR_WHITE; in compute_diff()
208 *dr->fDifference.fBitmap.getAddr32(x, y) = 0; in compute_diff()
209 *dr->fWhite.fBitmap.getAddr32(x, y) = PMCOLOR_BLACK; in compute_diff()
/external/skia/tools/skdiff/
Dskdiff_utils.cpp57 if (!resource.fBitmap.setInfo(info.makeColorType(kN32_SkColorType))) { in get_bitmap()
67 if (!resource.fBitmap.tryAllocPixels()) { in get_bitmap()
73 if (SkCodec::kSuccess != codec->getPixels(resource.fBitmap.info(), in get_bitmap()
74 resource.fBitmap.getPixels(), resource.fBitmap.rowBytes())) { in get_bitmap()
148 const int w = drp->fBase.fBitmap.width(); in create_and_write_diff_image()
149 const int h = drp->fBase.fBitmap.height(); in create_and_write_diff_image()
151 if (w != drp->fComparison.fBitmap.width() || h != drp->fComparison.fBitmap.height()) { in create_and_write_diff_image()
154 drp->fDifference.fBitmap.allocN32Pixels(w, h); in create_and_write_diff_image()
156 drp->fWhite.fBitmap.allocN32Pixels(w, h); in create_and_write_diff_image()
179 if (write_bitmap(drp->fDifference.fFullPath, drp->fDifference.fBitmap)) { in create_and_write_diff_image()
[all …]
Dskdiff.cpp159 const int w = dr->fComparison.fBitmap.width(); in compute_diff()
160 const int h = dr->fComparison.fBitmap.height(); in compute_diff()
161 if (w != dr->fBase.fBitmap.width() || h != dr->fBase.fBitmap.height()) { in compute_diff()
177 SkPMColor c0 = *dr->fBase.fBitmap.getAddr32(x, y); in compute_diff()
178 SkPMColor c1 = *dr->fComparison.fBitmap.getAddr32(x, y); in compute_diff()
205 *dr->fDifference.fBitmap.getAddr32(x, y) = outputDifference; in compute_diff()
206 *dr->fWhite.fBitmap.getAddr32(x, y) = PMCOLOR_WHITE; in compute_diff()
208 *dr->fDifference.fBitmap.getAddr32(x, y) = 0; in compute_diff()
209 *dr->fWhite.fBitmap.getAddr32(x, y) = PMCOLOR_BLACK; in compute_diff()
/external/skia/src/android/
DSkAnimatedImage.cpp47 if (!image->fDisplayFrame.fBitmap.getPixels()) { in Make()
66 if (!image->fDisplayFrame.fBitmap.getPixels()) { in Make()
89 if (!fDecodingFrame.fBitmap.tryAllocPixels(fDecodeInfo)) { in SkAnimatedImage()
113 if (fBitmap.getPixels()) { in init()
114 if (fBitmap.pixelRef()->unique()) { in init()
115 SkAssertResult(fBitmap.setAlphaType(info.alphaType())); in init()
128 memcpy(tmp.getPixels(), fBitmap.getPixels(), fBitmap.computeByteSize()); in init()
130 swap(tmp, fBitmap); in init()
135 return fBitmap.tryAllocPixels(info); in init()
139 if (!dst->init(fBitmap.info(), OnInit::kNoRestore)) { in copyTo()
[all …]
/external/skqp/samplecode/
DSampleUnpremul.cpp99 header.appendf(" [%dx%d] %s", fBitmap.width(), fBitmap.height(), in onDrawContent()
119 bm.allocN32Pixels(fBitmap.width(), fBitmap.height()); in onDrawContent()
120 for (int i = 0; i < fBitmap.width(); ++i) { in onDrawContent()
121 for (int j = 0; j < fBitmap.height(); ++j) { in onDrawContent()
122 *bm.getAddr32(i, j) = premultiply_unpmcolor(*fBitmap.getAddr32(i, j)); in onDrawContent()
127 canvas->drawBitmap(fBitmap, 0, 0); in onDrawContent()
136 SkBitmap fBitmap; member in UnpremulView
163 fDecodeSucceeded = decode_file(fCurrFile.c_str(), &fBitmap, kN32_SkColorType, !fPremul); in decodeCurrFile()
/external/skia/samplecode/
DSampleUnpremul.cpp99 header.appendf(" [%dx%d] %s", fBitmap.width(), fBitmap.height(), in onDrawContent()
119 bm.allocN32Pixels(fBitmap.width(), fBitmap.height()); in onDrawContent()
120 for (int i = 0; i < fBitmap.width(); ++i) { in onDrawContent()
121 for (int j = 0; j < fBitmap.height(); ++j) { in onDrawContent()
122 *bm.getAddr32(i, j) = premultiply_unpmcolor(*fBitmap.getAddr32(i, j)); in onDrawContent()
127 canvas->drawBitmap(fBitmap, 0, 0); in onDrawContent()
136 SkBitmap fBitmap; member in UnpremulView
163 fDecodeSucceeded = decode_file(fCurrFile.c_str(), &fBitmap, kN32_SkColorType, !fPremul); in decodeCurrFile()
/external/skqp/src/gpu/
DGrBitmapTextureMaker.cpp24 , fBitmap(bitmap) { in GrBitmapTextureMaker()
51 proxy = proxyProvider->createMipMapProxyFromBitmap(fBitmap); in refOriginalTextureProxy()
54 proxy = GrUploadBitmapToTextureProxy(proxyProvider, fBitmap); in refOriginalTextureProxy()
64 fOriginalKey, proxyProvider->contextUniqueID(), fBitmap.pixelRef()); in refOriginalTextureProxy()
90 fBitmap.pixelRef()); in refOriginalTextureProxy()
110 GrInstallBitmapUniqueKeyInvalidator(copyKey, contextUniqueID, fBitmap.pixelRef()); in didCacheCopy()
114 return fBitmap.alphaType(); in alphaType()
118 return fBitmap.colorSpace(); in colorSpace()
/external/skia/src/gpu/
DGrBitmapTextureMaker.cpp25 , fBitmap(bitmap) { in GrBitmapTextureMaker()
52 proxy = proxyProvider->createMipMapProxyFromBitmap(fBitmap); in refOriginalTextureProxy()
55 proxy = GrUploadBitmapToTextureProxy(proxyProvider, fBitmap); in refOriginalTextureProxy()
65 fOriginalKey, proxyProvider->contextID(), fBitmap.pixelRef()); in refOriginalTextureProxy()
91 fBitmap.pixelRef()); in refOriginalTextureProxy()
111 GrInstallBitmapUniqueKeyInvalidator(copyKey, contextUniqueID, fBitmap.pixelRef()); in didCacheCopy()
115 return fBitmap.alphaType(); in alphaType()
119 return fBitmap.colorSpace(); in colorSpace()
/external/skia/bench/
DBitmapRectBench.cpp43 SkBitmap fBitmap; member in BitmapRectBench
59 fBitmap.setInfo(SkImageInfo::MakeN32Premul(kWidth, kHeight)); in BitmapRectBench()
72 fBitmap.allocPixels(); in onDelayedSetup()
73 fBitmap.setAlphaType(kOpaque_SkAlphaType); in onDelayedSetup()
74 fBitmap.eraseColor(SK_ColorBLACK); in onDelayedSetup()
75 draw_into_bitmap(fBitmap); in onDelayedSetup()
100 canvas->drawBitmapRect(fBitmap, fSrcR, fDstR, &paint, in onDraw()
DRepeatTileBench.cpp39 SkBitmap fBitmap; member in RepeatTileBench
45 fBitmap.setInfo(SkImageInfo::Make(w, h, ct, at)); in RepeatTileBench()
56 fBitmap.allocPixels(); in onDelayedSetup()
57 fBitmap.eraseColor(kOpaque_SkAlphaType == fAlphaType ? SK_ColorWHITE : 0); in onDelayedSetup()
59 draw_into_bitmap(fBitmap); in onDelayedSetup()
61 fPaint.setShader(SkShader::MakeBitmapShader(fBitmap, in onDelayedSetup()
/external/skqp/bench/
DBitmapRectBench.cpp43 SkBitmap fBitmap; member in BitmapRectBench
59 fBitmap.setInfo(SkImageInfo::MakeN32Premul(kWidth, kHeight)); in BitmapRectBench()
72 fBitmap.allocPixels(); in onDelayedSetup()
73 fBitmap.setAlphaType(kOpaque_SkAlphaType); in onDelayedSetup()
74 fBitmap.eraseColor(SK_ColorBLACK); in onDelayedSetup()
75 draw_into_bitmap(fBitmap); in onDelayedSetup()
100 canvas->drawBitmapRect(fBitmap, fSrcR, fDstR, &paint, in onDraw()
DRepeatTileBench.cpp39 SkBitmap fBitmap; member in RepeatTileBench
45 fBitmap.setInfo(SkImageInfo::Make(w, h, ct, at)); in RepeatTileBench()
56 fBitmap.allocPixels(); in onDelayedSetup()
57 fBitmap.eraseColor(kOpaque_SkAlphaType == fAlphaType ? SK_ColorWHITE : 0); in onDelayedSetup()
59 draw_into_bitmap(fBitmap); in onDelayedSetup()
61 fPaint.setShader(SkShader::MakeBitmapShader(fBitmap, in onDelayedSetup()

12345