Home
last modified time | relevance | path

Searched refs:srcRect (Results 1 – 25 of 67) sorted by relevance

123

/external/skia/src/gpu/
DSkGpuDevice_drawTexture.cpp31 static bool has_aligned_samples(const SkRect& srcRect, const SkRect& transformedRect) { in has_aligned_samples() argument
35 SkScalarAbs(transformedRect.width() - srcRect.width()) < kColorBleedTolerance && in has_aligned_samples()
36 SkScalarAbs(transformedRect.height() - srcRect.height()) < kColorBleedTolerance) { in has_aligned_samples()
42 static bool may_color_bleed(const SkRect& srcRect, in may_color_bleed() argument
48 SkASSERT(!has_aligned_samples(srcRect, transformedRect)); in may_color_bleed()
49 SkRect innerSrcRect(srcRect), innerTransformedRect, outerTransformedRect(transformedRect); in may_color_bleed()
72 const SkRect& srcRect, in can_ignore_bilerp_constraint() argument
78 srcRectToDeviceSpace.mapRect(&transformedRect, srcRect); in can_ignore_bilerp_constraint()
80 if (has_aligned_samples(srcRect, transformedRect) || in can_ignore_bilerp_constraint()
81 !may_color_bleed(srcRect, transformedRect, srcRectToDeviceSpace, isMSAA)) { in can_ignore_bilerp_constraint()
[all …]
DSkGrPixelRef.cpp64 SkIRect srcRect; in copy_to_new_texture_pixelref() local
69 srcRect = SkIRect::MakeWH(texture->width(), texture->height()); in copy_to_new_texture_pixelref()
75 srcRect = *subset; in copy_to_new_texture_pixelref()
89 context->copySurface(dst, texture, srcRect, SkIPoint::Make(0,0)); in copy_to_new_texture_pixelref()
DSkGpuDevice.cpp731 static inline int get_tile_count(const SkIRect& srcRect, int tileSize) { in get_tile_count() argument
732 int tilesX = (srcRect.fRight / tileSize) - (srcRect.fLeft / tileSize) + 1; in get_tile_count()
733 int tilesY = (srcRect.fBottom / tileSize) - (srcRect.fTop / tileSize) + 1; in get_tile_count()
911 SkRect srcRect = SkRect::MakeIWH(bitmap.width(), bitmap.height()); in drawBitmap() local
933 if (this->shouldTileBitmap(bitmap, viewMatrix, params, &srcRect, in drawBitmap()
935 this->drawTiledBitmap(bitmap, viewMatrix, srcRect, clippedSrcRect, params, paint, in drawBitmap()
982 const SkRect& srcRect, in drawTiledBitmap() argument
1024 if (!tileR.intersect(srcRect)) { in drawTiledBitmap()
1037 tmpM.setTranslate(offset.fX - srcRect.fLeft, offset.fY - srcRect.fTop); in drawTiledBitmap()
1051 srcRect.roundOut(&iClampRect); in drawTiledBitmap()
[all …]
/external/skia/src/effects/
DSkGpuBlurUtils.cpp99 const SkRect& srcRect, in convolve_gaussian() argument
107 SkRect dstRect = SkRect::MakeWH(srcRect.width(), srcRect.height()); in convolve_gaussian()
182 SkRect srcRect; in GaussianBlur() local
184 srcRect = localSrcBounds = *srcBounds; in GaussianBlur()
185 srcRect.offset(srcOffset); in GaussianBlur()
188 srcRect = localDstBounds; in GaussianBlur()
191 scale_rect(&srcRect, 1.0f / scaleFactorX, 1.0f / scaleFactorY); in GaussianBlur()
192 srcRect.roundOut(&srcRect); in GaussianBlur()
193 scale_rect(&srcRect, static_cast<float>(scaleFactorX), in GaussianBlur()
232 SkRect dstRect(srcRect); in GaussianBlur()
[all …]
DSkTileImageFilter.cpp20 SkImageFilter* SkTileImageFilter::Create(const SkRect& srcRect, const SkRect& dstRect, in Create() argument
22 if (!SkIsValidRect(srcRect) || !SkIsValidRect(dstRect)) { in Create()
25 if (srcRect.width() == dstRect.width() && srcRect.height() == dstRect.height()) { in Create()
27 if (!ir.intersect(srcRect)) { in Create()
31 return SkOffsetImageFilter::Create(dstRect.x() - srcRect.x(), in Create()
32 dstRect.y() - srcRect.y(), in Create()
35 return new SkTileImageFilter(srcRect, dstRect, input); in Create()
60 SkRect srcRect; in onFilterImageDeprecated() local
61 ctx.ctm().mapRect(&srcRect, fSrcRect); in onFilterImageDeprecated()
63 srcRect.roundOut(&srcIRect); in onFilterImageDeprecated()
DSkMorphologyImageFilter.cpp454 const SkIRect& srcRect, in apply_morphology_rect() argument
468 SkRect::Make(srcRect)); in apply_morphology_rect()
474 const SkIRect& srcRect, in apply_morphology_rect_no_bounds() argument
486 SkRect::Make(srcRect)); in apply_morphology_rect_no_bounds()
492 const SkIRect& srcRect, in apply_morphology_pass() argument
498 SkIRect lowerSrcRect = srcRect, lowerDstRect = dstRect; in apply_morphology_pass()
499 SkIRect middleSrcRect = srcRect, middleDstRect = dstRect; in apply_morphology_pass()
500 SkIRect upperSrcRect = srcRect, upperDstRect = dstRect; in apply_morphology_pass()
502 bounds[0] = (SkIntToScalar(srcRect.left()) + 0.5f) / texture->width(); in apply_morphology_pass()
503 bounds[1] = (SkIntToScalar(srcRect.right()) - 0.5f) / texture->width(); in apply_morphology_pass()
[all …]
DSkMagnifierImageFilter.cpp235 SkImageFilter* SkMagnifierImageFilter::Create(const SkRect& srcRect, SkScalar inset, in Create() argument
238 if (!SkScalarIsFinite(inset) || !SkIsValidRect(srcRect)) { in Create()
242 if (srcRect.fLeft < 0 || srcRect.fTop < 0) { in Create()
245 return new SkMagnifierImageFilter(srcRect, inset, input); in Create()
249 SkMagnifierImageFilter::SkMagnifierImageFilter(const SkRect& srcRect, SkScalar inset, in SkMagnifierImageFilter() argument
251 : INHERITED(1, &input), fSrcRect(srcRect), fInset(inset) { in SkMagnifierImageFilter()
252 SkASSERT(srcRect.x() >= 0 && srcRect.y() >= 0 && inset >= 0); in SkMagnifierImageFilter()
DSkImageSource.cpp22 const SkRect& srcRect, in Create() argument
25 return image ? new SkImageSource(image, srcRect, dstRect, filterQuality) : nullptr; in Create()
36 const SkRect& srcRect, in SkImageSource() argument
41 , fSrcRect(srcRect) in SkImageSource()
/external/skia/gm/
Dpictureimagefilter.cpp57 SkRect srcRect = SkRect::MakeXYWH(20, 20, 30, 30); in onDraw() local
63 SkPictureImageFilter::Create(fPicture, srcRect)); in onDraw()
90 canvas->scale(200 / srcRect.width(), 200 / srcRect.height()); in onDraw()
91 canvas->translate(-srcRect.fLeft, -srcRect.fTop); in onDraw()
92 fillRectFiltered(canvas, srcRect, pictureSource); in onDraw()
95 canvas->translate(srcRect.width(), 0); in onDraw()
96 fillRectFiltered(canvas, srcRect, pictureSourceResampled); in onDraw()
99 canvas->translate(srcRect.width(), 0); in onDraw()
100 fillRectFiltered(canvas, srcRect, pictureSourcePixelated); in onDraw()
Dresizeimagefilter.cpp64 SkRect srcRect = SkRect::MakeWH(96, 96); in onDraw() local
68 srcRect, in onDraw()
72 canvas->translate(srcRect.width() + SkIntToScalar(10), 0); in onDraw()
74 srcRect, in onDraw()
78 canvas->translate(srcRect.width() + SkIntToScalar(10), 0); in onDraw()
80 srcRect, in onDraw()
84 canvas->translate(srcRect.width() + SkIntToScalar(10), 0); in onDraw()
86 srcRect, in onDraw()
105 canvas->translate(srcRect.width() + SkIntToScalar(10), 0); in onDraw()
107 srcRect, in onDraw()
Dmatriximagefilter.cpp50 SkRect srcRect = SkRect::MakeWH(96, 96); variable
53 draw(canvas, srcRect, checkerboard, matrix, kNone_SkFilterQuality);
55 canvas->translate(srcRect.width() + margin, 0);
56 draw(canvas, srcRect, checkerboard, matrix, kLow_SkFilterQuality);
60 canvas->translate(srcRect.width() + margin, 0);
61 draw(canvas, srcRect, checkerboard, matrix, kMedium_SkFilterQuality);
63 canvas->translate(srcRect.width() + margin, 0);
64 draw(canvas, srcRect, checkerboard, matrix, kHigh_SkFilterQuality);
Dtileimagefilter.cpp60 SkRect srcRect = SkRect::MakeXYWH(SkIntToScalar(image->width()/4), in onDraw() local
70 SkTileImageFilter::Create(srcRect, dstRect, tileInput)); in onDraw()
76 canvas->drawRect(srcRect, red); in onDraw()
91 SkRect srcRect = SkRect::MakeWH(SkIntToScalar(fBitmap->width()), in onDraw() local
95 SkAutoTUnref<SkImageFilter> tile(SkTileImageFilter::Create(srcRect, dstRect, nullptr)); in onDraw()
107 canvas->drawRect(srcRect, red); in onDraw()
Dimagesource.cpp43 SkRect srcRect = SkRect::MakeXYWH(20, 20, 30, 30); in onDraw() local
49 SkImageSource::Create(fImage, srcRect, srcRect, kHigh_SkFilterQuality)); in onDraw()
51 SkImageSource::Create(fImage, srcRect, dstRect, kHigh_SkFilterQuality)); in onDraw()
Ddrawbitmaprect.cpp174 SkIRect srcRect = SkIRect::MakeXYWH((gBmpSize - w) / 2, (gBmpSize - h) / 2, w, h); in onDraw() local
175 fProc(canvas, fImage, fLargeBitmap, srcRect, dstRect); in onDraw()
206 SkIRect srcRect; in onDraw() local
213 srcRect.setXYWH(1, 1, 3, 3); in onDraw()
220 canvas->drawBitmapRect(bm, srcRect, dstRect, &paint); in onDraw()
/external/webrtc/webrtc/modules/video_render/android/java/src/org/webrtc/videoengine/
DViESurfaceRenderer.java39 private Rect srcRect = new Rect(); field in ViESurfaceRenderer
68 " srcRect.left:" + srcRect.left + in surfaceChanged()
69 " srcRect.top:" + srcRect.top + in surfaceChanged()
70 " srcRect.right:" + srcRect.right + in surfaceChanged()
71 " srcRect.bottom:" + srcRect.bottom + in surfaceChanged()
89 " srcRect.left:" + srcRect.left + in surfaceCreated()
90 " srcRect.top:" + srcRect.top + in surfaceCreated()
91 " srcRect.right:" + srcRect.right + in surfaceCreated()
92 " srcRect.bottom:" + srcRect.bottom + in surfaceCreated()
119 srcRect.left = 0; in CreateBitmap()
[all …]
/external/skia/samplecode/
DSampleTextureDomain.cpp47 SkRect srcRect; in onDrawContent() local
54 srcRect.setXYWH(1, 1, 3, 3); in onDrawContent()
56 canvas->drawBitmapRect(fBM, srcRect, dstRect, &paint, SkCanvas::kStrict_SrcRectConstraint); in onDrawContent()
65 srcRect.setXYWH(1, 1, 3, 3); in onDrawContent()
67 surface->getCanvas()->drawBitmapRect(fBM, srcRect, dstRect, &paint, in onDrawContent()
72 srcRect.setXYWH(1, 1, 3, 3); in onDrawContent()
74 canvas->drawImageRect(image, srcRect, dstRect, &paint); in onDrawContent()
78 srcRect.setXYWH(1, 1, 3, 3); in onDrawContent()
86 canvas->drawImageRect(image, srcRect, dstRect, &paint); in onDrawContent()
/external/skia/tests/
DCopySurfaceTest.cpp61 for (auto srcRect : kSrcRects) { in DEF_GPUTEST_FOR_RENDERING_CONTEXTS() local
84 bool result = context->copySurface(dst, src, srcRect, dstPoint); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
87 SkIPoint dstOffset = { dstPoint.fX - srcRect.fLeft, in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
88 dstPoint.fY - srcRect.fTop }; in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
91 srcRect.width(), in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
92 srcRect.height()); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
95 if (!copiedSrcRect.intersect(srcRect, SkIRect::MakeWH(kW, kH))) { in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
100 copiedDstRect.fLeft += copiedSrcRect.fLeft - srcRect.fLeft; in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
101 copiedDstRect.fTop += copiedSrcRect.fTop - srcRect.fTop; in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
102 copiedDstRect.fRight -= copiedSrcRect.fRight - srcRect.fRight; in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
[all …]
DReadPixelsTest.cpp184 SkIRect srcRect = SkIRect::MakeXYWH(x, y, bw, bh); in check_read() local
186 if (!clippedSrcRect.intersect(srcRect)) { in check_read()
192 int devx = bx + srcRect.fLeft; in check_read()
193 int devy = by + srcRect.fTop; in check_read()
332 const SkIRect& srcRect = gReadPixelsTestRects[rect]; in test_readpixels() local
336 init_bitmap(&bmp, srcRect, bmi, in test_readpixels()
346 bool success = canvas->readPixels(&bmp, srcRect.fLeft, srcRect.fTop); in test_readpixels()
351 bool expectSuccess = SkIRect::Intersects(srcRect, DEV_RECT); in test_readpixels()
358 check_read(reporter, bmp, srcRect.fLeft, srcRect.fTop, in test_readpixels()
369 bool success = canvas->readPixels(srcRect, &wkbmp); in test_readpixels()
[all …]
/external/skia/src/gpu/batches/
DGrCopySurfaceBatch.h25 const SkIRect& srcRect,
30 static GrBatch* Create(GrSurface* dst, GrSurface* src, const SkIRect& srcRect,
51 GrCopySurfaceBatch(GrSurface* dst, GrSurface* src, const SkIRect& srcRect, in GrCopySurfaceBatch() argument
56 , fSrcRect(srcRect) in GrCopySurfaceBatch()
59 SkIntToScalar(srcRect.width()), SkIntToScalar(srcRect.height())); in GrCopySurfaceBatch()
DGrCopySurfaceBatch.cpp14 const SkIRect& srcRect, in ClipSrcRectAndDstPoint() argument
18 *clippedSrcRect = srcRect; in ClipSrcRectAndDstPoint()
62 GrBatch* GrCopySurfaceBatch::Create(GrSurface* dst, GrSurface* src, const SkIRect& srcRect, in Create() argument
70 if (!ClipSrcRectAndDstPoint(dst, src, srcRect, dstPoint, &clippedSrcRect, &clippedDstPoint)) { in Create()
/external/deqp/framework/platform/raspi/
DtcuRaspiPlatform.cpp127 VC_RECT_T dstRect, srcRect; in Window() local
134 srcRect.x = 0; in Window()
135 srcRect.y = 0; in Window()
136 srcRect.width = width << 16; in Window()
137 srcRect.height = height << 16; in Window()
145 …nt_add(dispmanUpdate, m_dispmanDisplay, 0/*layer*/, &dstRect, 0/*src*/, &srcRect, DISPMANX_PROTECT… in Window()
/external/skia/src/core/
DSkMatrixImageFilter.cpp64 SkRect srcRect = SkRect::Make(srcBounds); in onFilterImageDeprecated() local
71 matrix.mapRect(&dstRect, srcRect); in onFilterImageDeprecated()
86 canvas.drawBitmap(src, srcRect.x(), srcRect.y(), &paint); in onFilterImageDeprecated()
/external/pdfium/xfa/src/fdp/src/fde/
Dfde_gdidevice.cpp95 CFX_RectF srcRect; in DrawImage() local
97 srcRect = *pSrcRect; in DrawImage()
99 srcRect.left = srcRect.top = 0; in DrawImage()
100 srcRect.width = (FX_FLOAT)pImg->GetImageWidth(); in DrawImage()
101 srcRect.height = (FX_FLOAT)pImg->GetImageHeight(); in DrawImage()
110 matrix.Scale((dstRect.width / srcRect.width), in DrawImage()
111 (dstRect.height / srcRect.height), TRUE); in DrawImage()
117 dstPoints[1].Set(srcRect.width, 0); in DrawImage()
118 dstPoints[2].Set(0, srcRect.height); in DrawImage()
121 srcRect.left, srcRect.top, srcRect.width, in DrawImage()
[all …]
/external/skia/include/effects/
DSkImageSource.h19 const SkRect& srcRect,
37 const SkRect& srcRect,
DSkTileImageFilter.h38 SkTileImageFilter(const SkRect& srcRect, const SkRect& dstRect, SkImageFilter* input) in SkTileImageFilter() argument
39 : INHERITED(1, &input, NULL), fSrcRect(srcRect), fDstRect(dstRect) {} in SkTileImageFilter()

123