Home
last modified time | relevance | path

Searched refs:subset (Results 1 - 25 of 236) sorted by relevance

12345678910

/third_party/skia/src/core/
H A DSkSpecialImage.cpp37 SkSpecialImage_Base(const SkIRect& subset, uint32_t uniqueID, const SkSurfaceProps& props) in SkSpecialImage_Base() argument
38 : INHERITED(subset, uniqueID, props) { in SkSpecialImage_Base()
55 // This subset is relative to the backing store's coordinate frame, it has already been mapped
57 virtual sk_sp<SkSpecialImage> onMakeSubset(const SkIRect& subset) const = 0;
63 // This subset (when not null) is relative to the backing store's coordinate frame, it has
65 virtual sk_sp<SkImage> onAsImage(const SkIRect* subset) const = 0;
80 SkSpecialImage::SkSpecialImage(const SkIRect& subset, in SkSpecialImage() argument
84 , fSubset(subset) in SkSpecialImage()
127 sk_sp<SkSpecialImage> SkSpecialImage::makeSubset(const SkIRect& subset) const { in makeSubset()
128 SkIRect absolute = subset in makeSubset()
155 MakeFromImage(GrRecordingContext* rContext, const SkIRect& subset, sk_sp<SkImage> image, const SkSurfaceProps& props) MakeFromImage() argument
186 SkSpecialImage_Raster(const SkIRect& subset, const SkBitmap& bm, const SkSurfaceProps& props) SkSpecialImage_Raster() argument
269 MakeFromRaster(const SkIRect& subset, const SkBitmap& bm, const SkSurfaceProps& props) MakeFromRaster() argument
292 CopyFromRaster(const SkIRect& subset, const SkBitmap& bm, const SkSurfaceProps& props) CopyFromRaster() argument
334 SkSpecialImage_Gpu(GrRecordingContext* context, const SkIRect& subset, uint32_t uniqueID, GrSurfaceProxyView view, GrColorType ct, SkAlphaType at, sk_sp<SkColorSpace> colorSpace, const SkSurfaceProps& props) SkSpecialImage_Gpu() argument
462 MakeDeferredFromGpu(GrRecordingContext* context, const SkIRect& subset, uint32_t uniqueID, GrSurfaceProxyView view, GrColorType colorType, sk_sp<SkColorSpace> colorSpace, const SkSurfaceProps& props, SkAlphaType at) MakeDeferredFromGpu() argument
[all...]
H A DSkSpecialSurface.cpp19 SkSpecialSurface_Base(const SkIRect& subset, const SkSurfaceProps& props) in SkSpecialSurface_Base() argument
20 : INHERITED(subset, props) in SkSpecialSurface_Base()
44 SkSpecialSurface::SkSpecialSurface(const SkIRect& subset, in SkSpecialSurface() argument
47 , fSubset(subset) { in SkSpecialSurface()
69 const SkIRect& subset, in SkSpecialSurface_Raster()
71 : INHERITED(subset, props) { in SkSpecialSurface_Raster()
77 fCanvas->clipRect(SkRect::Make(subset)); in SkSpecialSurface_Raster()
86 return SkSpecialImage::MakeFromRaster(this->subset(), fBitmap, this->props());
95 sk_sp<SkSpecialSurface> SkSpecialSurface::MakeFromBitmap(const SkIRect& subset, SkBitmap& bm, in MakeFromBitmap() argument
97 if (subset in MakeFromBitmap()
67 SkSpecialSurface_Raster(const SkImageInfo& info, sk_sp<SkPixelRef> pr, const SkIRect& subset, const SkSurfaceProps& props) SkSpecialSurface_Raster() argument
114 const SkIRect subset = SkIRect::MakeWH(info.width(), info.height()); MakeRaster() local
126 SkSpecialSurface_Gpu(sk_sp<skgpu::BaseDevice> device, SkIRect subset) SkSpecialSurface_Gpu() argument
173 const SkIRect subset = SkIRect::MakeSize(ii.dimensions()); MakeRenderTarget() local
[all...]
H A DSkSpecialImage.h46 * Note: the contents of the backing storage outside of the subset rect are undefined.
57 const SkIRect& subset() const { return fSubset; } in subset() function in SkSpecialImage
66 * Draw this SpecialImage into the canvas, automatically taking into account the image's subset
74 const SkIRect& subset,
77 static sk_sp<SkSpecialImage> MakeFromRaster(const SkIRect& subset,
80 static sk_sp<SkSpecialImage> CopyFromRaster(const SkIRect& subset,
85 const SkIRect& subset,
115 * Extract a subset of this special image and return it as a special image.
116 * It may or may not point to the same backing memory. The input 'subset' is relative to the
119 sk_sp<SkSpecialImage> makeSubset(const SkIRect& subset) cons
[all...]
/third_party/skia/tests/
H A DSpecialImageTest.cpp60 const SkIRect subset = img->subset(); in test_image() local
61 REPORTER_ASSERT(reporter, kPad == subset.left()); in test_image()
62 REPORTER_ASSERT(reporter, kPad == subset.top()); in test_image()
63 REPORTER_ASSERT(reporter, kSmallerSize == subset.width()); in test_image()
64 REPORTER_ASSERT(reporter, kSmallerSize == subset.height()); in test_image()
87 // Test that draw restricts itself to the subset in test_image()
114 SkIRect newSubset = SkIRect::MakeWH(subset.width(), subset.height()); in test_image()
118 REPORTER_ASSERT(reporter, tightImg->width() == subset in test_image()
145 const SkIRect& subset = SkIRect::MakeXYWH(kPad, kPad, kSmallerSize, kSmallerSize); DEF_TEST() local
170 const SkIRect& subset = SkIRect::MakeXYWH(kPad, kPad, kSmallerSize, kSmallerSize); test_specialimage_image() local
205 const SkIRect& subset = SkIRect::MakeXYWH(kPad, kPad, kSmallerSize, kSmallerSize); DEF_GPUTEST_FOR_RENDERING_CONTEXTS() local
[all...]
H A DImageFilterCacheTest.cpp42 const sk_sp<SkSpecialImage>& subset) { in test_find_existing()
47 SkImageFilterCacheKey key1(0, SkMatrix::I(), clip, image->uniqueID(), image->subset()); in test_find_existing()
48 SkImageFilterCacheKey key2(0, SkMatrix::I(), clip, subset->uniqueID(), subset->subset()); in test_find_existing()
65 const sk_sp<SkSpecialImage>& subset) { in test_dont_find_if_diff_key()
71 SkImageFilterCacheKey key0(0, SkMatrix::I(), clip1, image->uniqueID(), image->subset()); in test_dont_find_if_diff_key()
72 SkImageFilterCacheKey key1(1, SkMatrix::I(), clip1, image->uniqueID(), image->subset()); in test_dont_find_if_diff_key()
74 image->uniqueID(), image->subset()); in test_dont_find_if_diff_key()
75 SkImageFilterCacheKey key3(0, SkMatrix::I(), clip2, image->uniqueID(), image->subset()); in test_dont_find_if_diff_key()
40 test_find_existing(skiatest::Reporter* reporter, const sk_sp<SkSpecialImage>& image, const sk_sp<SkSpecialImage>& subset) test_find_existing() argument
63 test_dont_find_if_diff_key(skiatest::Reporter* reporter, const sk_sp<SkSpecialImage>& image, const sk_sp<SkSpecialImage>& subset) test_dont_find_if_diff_key() argument
116 test_explicit_purging(skiatest::Reporter* reporter, const sk_sp<SkSpecialImage>& image, const sk_sp<SkSpecialImage>& subset) test_explicit_purging() argument
159 const SkIRect& subset = SkIRect::MakeXYWH(kPad, kPad, kSmallerSize, kSmallerSize); DEF_TEST() local
180 const SkIRect& subset = SkIRect::MakeXYWH(kPad, kPad, kSmallerSize, kSmallerSize); test_image_backed() local
271 const SkIRect& subset = SkIRect::MakeXYWH(kPad, kPad, kSmallerSize, kSmallerSize); DEF_GPUTEST_FOR_RENDERING_CONTEXTS() local
[all...]
H A DBitmapCopyTest.cpp90 SkBitmap subset; in DEF_TEST() local
92 // Extract a subset which has the same width as the original. This in DEF_TEST()
96 if (kUnknown_SkColorType != bitmap.colorType() && bitmap.extractSubset(&subset, r)) { in DEF_TEST()
97 REPORTER_ASSERT(reporter, subset.width() == W); in DEF_TEST()
98 REPORTER_ASSERT(reporter, subset.height() == 2); in DEF_TEST()
99 REPORTER_ASSERT(reporter, subset.alphaType() == bitmap.alphaType()); in DEF_TEST()
101 // Test copying an extracted subset. in DEF_TEST()
104 bool success = ToolUtils::copy_to(&copy, gPairs[j].fColorType, subset); in DEF_TEST()
112 // When performing a copy of an extracted subset, the gen id should in DEF_TEST()
114 REPORTER_ASSERT(reporter, copy.getGenerationID() != subset in DEF_TEST()
[all...]
H A DDeviceTest.cpp58 SkASSERT(SkIRect::MakeWH(kWidth, kHeight) == special->subset());
67 SkASSERT(SkIRect::MakeWH(kWidth, kHeight) == special->subset());
74 SkASSERT(SkIRect::MakeWH(2*kWidth, 2*kHeight) == special->subset());
101 SkASSERT(SkIRect::MakeWH(kWidth, kHeight) == special->subset()); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
111 SkASSERT(SkIRect::MakeWH(kWidth, kHeight) == special->subset()); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
120 SkASSERT(SkIRect::MakeWH(kWidth, kHeight) == special->subset()); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
127 SkASSERT(SkIRect::MakeWH(2*kWidth, 2*kHeight) == special->subset()); in DEF_GPUTEST_FOR_RENDERING_CONTEXTS()
/third_party/skia/client_utils/android/
H A DBitmapRegionDecoderPriv.h20 * Corrects image subset offsets and dimensions in order to perform a valid decode.
21 * Also indicates if the image subset should be placed at an offset within the
27 * @param subset As input, the subset that the client requested.
28 * As output, the image subset that we will decode.
29 * @param outX The left offset of the image subset within the output bitmap.
30 * @param outY The top offset of the image subset within the output bitmap.
32 * @return An indication of how the subset is contained in the image.
35 inline SubsetType adjust_subset_rect(const SkISize& imageDims, SkIRect* subset, int* outX, in adjust_subset_rect() argument
38 int left = std::max(0, subset in adjust_subset_rect()
[all...]
H A DBitmapRegionDecoder.cpp58 // requested subset, not by the size of the intersection of the subset in decodeRegion()
68 SkIRect subset = desiredSubset; in decodeRegion() local
69 SubsetType type = adjust_subset_rect(fCodec->getInfo().dimensions(), &subset, &outX, &outY); in decodeRegion()
74 // Ask the codec for a scaled subset in decodeRegion()
75 if (!fCodec->getSupportedSubset(&subset)) { in decodeRegion()
76 SkCodecPrintf("Error: Could not get subset.\n"); in decodeRegion()
79 SkISize scaledSize = fCodec->getSampledSubsetDimensions(sampleSize, subset); in decodeRegion()
94 // We need to be safe here because getSupportedSubset() may have modified the subset. in decodeRegion()
95 const int extraX = std::max(0, desiredSubset.width() - outX - subset in decodeRegion()
[all...]
/third_party/skia/third_party/externals/harfbuzz/test/api/
H A Dtest-subset.c28 #include "hb-subset-test.h"
30 /* Unit tests for hb-subset-glyf.h */
39 hb_face_t *subset; in test_subset_32_tables() local
45 subset = hb_subset_or_fail (face, input); in test_subset_32_tables()
46 g_assert (subset); in test_subset_32_tables()
47 g_assert (subset != hb_face_get_empty ()); in test_subset_32_tables()
50 hb_face_destroy (subset); in test_subset_32_tables()
57 hb_face_t *face = hb_test_open_font_file ("../fuzzing/fonts/clusterfuzz-testcase-minimized-hb-subset-fuzzer-5521982557782016"); in test_subset_no_inf_loop()
61 hb_face_t *subset; in test_subset_no_inf_loop() local
67 subset in test_subset_no_inf_loop()
82 hb_face_t *subset; test_subset_crash() local
[all...]
H A Dtest-subset-drop-tables.c28 #include "hb-subset-test.h"
30 /* Unit tests for hb-subset.cc drop tables functionality */
45 hb_face_t* subset = hb_subset_or_fail (face, input); in test_subset_drop_tables() local
46 g_assert (subset); in test_subset_drop_tables()
48 hb_blob_t *hdmx = hb_face_reference_table (subset, HB_TAG ('h', 'd', 'm', 'x')); in test_subset_drop_tables()
49 hb_blob_t *hmtx = hb_face_reference_table (subset, HB_TAG ('h', 'm', 't', 'x')); in test_subset_drop_tables()
50 hb_blob_t *cmap = hb_face_reference_table (subset, HB_TAG ('c', 'm', 'a', 'p')); in test_subset_drop_tables()
58 hb_face_destroy (subset); in test_subset_drop_tables()
/third_party/skia/third_party/externals/harfbuzz/test/subset/
H A Dsubset_test_suite.py5 # A single test in a subset test suite. Identifies a font
6 # a subsetting profile, and a subset to be cut.
8 def __init__(self, font_path, profile_path, subset):
11 self.subset = subset
15 if self.subset == '*':
16 return self.subset[0]
17 elif re.match("^U\+", self.subset):
18 s = re.sub (r"U\+", "", self.subset)
21 return ",".join("%X" % ord(c) for (i, c) in enumerate(self.subset))
[all...]
/third_party/skia/docs/examples/
H A DBitmap_pixelRef.cpp7 SkBitmap subset; in REG_FIDDLE() local
8 source.extractSubset(&subset, SkIRect::MakeXYWH(32, 64, 128, 256)); in REG_FIDDLE()
9 SkDebugf("src ref %c= sub ref\n", source.pixelRef() == subset.pixelRef() ? '=' : '!'); in REG_FIDDLE()
10 SkDebugf("src pixels %c= sub pixels\n", source.getPixels() == subset.getPixels() ? '=' : '!'); in REG_FIDDLE()
11 SkDebugf("src addr %c= sub addr\n", source.getAddr(32, 64) == subset.getAddr(0, 0) ? '=' : '!'); in REG_FIDDLE()
H A DImage_uniqueID.cpp8 sk_sp<SkImage> subset = image->makeSubset({10, 20, 90, 100}); in REG_FIDDLE() local
10 canvas->drawImage(subset, 128, 0); in REG_FIDDLE()
15 s.printf("subset id: %d", subset->uniqueID()); in REG_FIDDLE()
16 canvas->drawString(s, 148, subset->height() + 20, paint); in REG_FIDDLE()
/third_party/skia/src/pdf/
H A DSkPDFSubsetFont.cpp13 #include "hb-subset.h"
96 HBFace subset = SkPDFHarfBuzzSubset<hb_subset_input_t*>::Make(input.get(), face.get());
97 if (!subset) {
100 HBBlob result(hb_face_reference_blob(subset.get()));
124 std::vector<unsigned> subset;
125 glyphUsage.getSetValues([&subset](unsigned v) { subset.push_back(v); });
134 subset.data(),
135 subset.size(),
142 subset
[all...]
H A DSkKeyedImage.cpp33 SkKeyedImage SkKeyedImage::subset(SkIRect subset) const { in subset() function in SkKeyedImage
35 if (fImage && subset.intersect(fImage->bounds())) { in subset()
36 img.fImage = fImage->makeSubset(subset); in subset()
38 img.fKey = {subset.makeOffset(fKey.fSubset.topLeft()), fKey.fID}; in subset()
/third_party/skia/src/image/
H A DSkImage.cpp182 sk_sp<SkImage> SkImage::makeSubset(const SkIRect& subset, GrDirectContext* direct) const { in makeSubset() argument
183 if (subset.isEmpty()) { in makeSubset()
188 if (!bounds.contains(subset)) { in makeSubset()
200 // optimization : return self if the subset == our bounds in makeSubset()
201 if (bounds == subset) { in makeSubset()
205 return as_IB(this)->onMakeSubset(subset, direct); in makeSubset()
317 const SkRect* subset, in asFragmentProcessor()
329 return this->onAsFragmentProcessor(rContext, sampling, tileModes, m, subset, domain); in asFragmentProcessor()
339 const SkRect* subset, in MakeFragmentProcessorFromView()
348 if (subset) { in MakeFragmentProcessorFromView()
312 asFragmentProcessor( GrRecordingContext* rContext, SkSamplingOptions sampling, const SkTileMode tileModes[2], const SkMatrix& m, const SkRect* subset, const SkRect* domain) const asFragmentProcessor() argument
332 MakeFragmentProcessorFromView( GrRecordingContext* rContext, GrSurfaceProxyView view, SkAlphaType at, SkSamplingOptions sampling, const SkTileMode tileModes[2], const SkMatrix& m, const SkRect* subset, const SkRect* domain) MakeFragmentProcessorFromView() argument
510 makeWithFilter(GrRecordingContext* rContext, const SkImageFilter* filter, const SkIRect& subset, const SkIRect& clipBounds, SkIRect* outSubset, SkIPoint* offset) const makeWithFilter() argument
[all...]
H A DSkSurface_Raster.cpp24 sk_sp<SkImage> onNewImageSnapshot(const SkIRect* subset) override;
90 sk_sp<SkImage> SkSurface_Raster::onNewImageSnapshot(const SkIRect* subset) { in onNewImageSnapshot() argument
91 if (subset) { in onNewImageSnapshot()
92 SkASSERT(SkIRect::MakeWH(fBitmap.width(), fBitmap.height()).contains(*subset)); in onNewImageSnapshot()
94 dst.allocPixels(fBitmap.info().makeDimensions(subset->size())); in onNewImageSnapshot()
95 SkAssertResult(fBitmap.readPixels(dst.pixmap(), subset->left(), subset->top())); in onNewImageSnapshot()
/third_party/node/deps/icu-small/source/common/
H A Duniset_closure.cpp157 const UnicodeSet &maybeOnlyCaseSensitive(const UnicodeSet &src, UnicodeSet &subset) { in maybeOnlyCaseSensitive() argument
158 // The subset must have been constructed with all code points, in maybeOnlyCaseSensitive()
160 U_ASSERT(subset.contains(0, 0x10ffff)); in maybeOnlyCaseSensitive()
175 subset.retainAll(*sensitive); in maybeOnlyCaseSensitive()
176 subset.retainAll(src); in maybeOnlyCaseSensitive()
178 subset.retainAll(src); in maybeOnlyCaseSensitive()
179 subset.retainAll(*sensitive); in maybeOnlyCaseSensitive()
181 return subset; in maybeOnlyCaseSensitive()
257 UnicodeSet subset(0, 0x10ffff); in closeOverCaseInsensitive()
258 const UnicodeSet &codePoints = maybeOnlyCaseSensitive(*this, subset); in closeOverCaseInsensitive()
[all...]
/third_party/skia/third_party/externals/swiftshader/src/Device/
H A DBC_Decoder.cpp1471 auto &subset = subsets[i]; in decode() local
1472 subset[0].rgb.r = Get(mode.Red(i * 2 + 0)); in decode()
1473 subset[0].rgb.g = Get(mode.Green(i * 2 + 0)); in decode()
1474 subset[0].rgb.b = Get(mode.Blue(i * 2 + 0)); in decode()
1475 subset[0].a = (mode.AB > 0) ? Get(mode.Alpha(i * 2 + 0)) : 255; in decode()
1477 subset[1].rgb.r = Get(mode.Red(i * 2 + 1)); in decode()
1478 subset[1].rgb.g = Get(mode.Green(i * 2 + 1)); in decode()
1479 subset[1].rgb.b = Get(mode.Blue(i * 2 + 1)); in decode()
1480 subset[1].a = (mode.AB > 0) ? Get(mode.Alpha(i * 2 + 1)) : 255; in decode()
1497 auto &subset in decode() local
1515 auto &subset = subsets[i]; decode() local
[all...]
/third_party/skia/src/codec/
H A DSkSampledCodec.cpp76 const SkIRect* subset = options.fSubset; in onGetAndroidPixels() local
77 if (!subset || subset->size() == this->codec()->dimensions()) { in onGetAndroidPixels()
86 // We are performing a subset decode. in onGetAndroidPixels()
94 // Calculate the scaled subset bounds. in onGetAndroidPixels()
95 int scaledSubsetX = subset->x() / sampleSize; in onGetAndroidPixels()
96 int scaledSubsetY = subset->y() / sampleSize; in onGetAndroidPixels()
173 // Check if there is a subset. in sampledDecode()
174 SkIRect subset; in sampledDecode() local
181 // Update the subset t in sampledDecode()
[all...]
H A DSkWebpCodec.cpp21 // A WebP decoder on top of (subset of) libwebp
208 // decode this exact subset. in onGetValidSubset()
209 // Leave right and bottom unmodified, so we suggest a slightly larger subset than requested. in onGetValidSubset()
383 SkIRect subset = *options.fSubset; in onGetPixels() local
384 SkASSERT(this->bounds().contains(subset)); in onGetPixels()
385 SkASSERT(SkIsAlign2(subset.fLeft) && SkIsAlign2(subset.fTop)); in onGetPixels()
386 SkASSERT(this->getValidSubset(&subset) && subset == *options.fSubset); in onGetPixels()
388 if (!SkIRect::Intersects(subset, frameRec in onGetPixels()
[all...]
/third_party/skia/src/gpu/effects/
H A DGrTextureEffect.cpp40 const SkRect& subset, in Sampling()
70 auto resolve = [&](int size, Wrap wrap, Span subset, Span domain, float linearFilterInset) { in Sampling()
83 if (canDoModeInHW && size > 0 && subset.fA <= 0 && subset.fB >= size) { in Sampling()
90 r.fShaderSubset = subset; in Sampling()
93 Span isubset{sk_float_floor(subset.fA), sk_float_ceil(subset.fB)}; in Sampling()
102 r.fShaderClamp = subset.makeInset(linearFilterInset); in Sampling()
108 // The domain of coords that will be used won't access texels outside of the subset. in Sampling()
123 Span subsetX{subset in Sampling()
38 Sampling(const GrSurfaceProxy& proxy, GrSamplerState sampler, const SkRect& subset, const SkRect* domain, const float border[4], bool alwaysUseShaderTileMode, const GrCaps& caps, SkVector linearFilterInset) Sampling() argument
185 MakeSubset(GrSurfaceProxyView view, SkAlphaType alphaType, const SkMatrix& matrix, GrSamplerState sampler, const SkRect& subset, const GrCaps& caps, const float border[4], bool alwaysUseShaderTileMode) MakeSubset() argument
206 MakeSubset(GrSurfaceProxyView view, SkAlphaType alphaType, const SkMatrix& matrix, GrSamplerState sampler, const SkRect& subset, const SkRect& domain, const GrCaps& caps, const float border[4]) MakeSubset() argument
221 MakeCustomLinearFilterInset( GrSurfaceProxyView view, SkAlphaType alphaType, const SkMatrix& matrix, Wrap wx, Wrap wy, const SkRect& subset, const SkRect* domain, SkVector inset, const GrCaps& caps, const float border[4]) MakeCustomLinearFilterInset() argument
707 float subset[] = {s.fLeft, s.fTop, s.fRight, s.fBottom}; onSetData() local
711 float subset[] = {c.fLeft, c.fTop, c.fRight, c.fBottom}; onSetData() local
[all...]
/third_party/mesa3d/src/mesa/main/
H A Dtexcompress_bptc_tmp.h241 * within the block. The value of the two bits represents which subset to use
289 /* Anchor index values for the second subset of two-subset partitioning */
297 /* Anchor index values for the second subset of three-subset partitioning */
305 /* Anchor index values for the third subset of three-subset
360 int subset; in extract_unorm_endpoints() local
367 for (subset = 0; subset < mod in extract_unorm_endpoints()
[all...]
/third_party/skia/src/effects/imagefilters/
H A DSkTileImageFilter.cpp125 sk_sp<SkImage> subset; in onFilterImage() local
127 subset = input->asImage(&srcIRect); in onFilterImage()
145 subset = surf->makeImageSnapshot(); in onFilterImage()
147 if (!subset) { in onFilterImage()
150 SkASSERT(subset->width() == srcIRect.width()); in onFilterImage()
151 SkASSERT(subset->height() == srcIRect.height()); in onFilterImage()
163 paint.setShader(subset->makeShader(SkTileMode::kRepeat, SkTileMode::kRepeat, in onFilterImage()

Completed in 19 milliseconds

12345678910