Home
last modified time | relevance | path

Searched refs:rects (Results 1 – 25 of 210) sorted by relevance

123456789

/external/libchrome/mojo/public/cpp/bindings/tests/
Dtype_conversion_unittest.cc23 std::vector<RedmondRect> rects; member
68 input.name, ConvertTo<std::vector<test::RectPtr>>(input.rects)); in Convert()
78 if (input->rects) { in Convert()
79 region.rects.reserve(input->rects->size()); in Convert()
80 for (const auto& element : *input->rects) in Convert()
81 region.rects.push_back(element.To<RedmondRect>()); in Convert()
107 std::vector<RectPtr> rects; in TEST() local
109 auto redmond_rects = ConvertTo<std::vector<RedmondRect>>(rects); in TEST()
117 std::vector<RectPtr> rects(10); in TEST() local
118 for (size_t i = 0; i < rects.size(); ++i) { in TEST()
[all …]
Dequals_unittest.cc56 std::vector<RectPtr> rects; in TEST_F() local
57 rects.push_back(CreateRect()); in TEST_F()
58 NamedRegionPtr n1(NamedRegion::New(std::string("n1"), std::move(rects))); in TEST_F()
62 n2->rects = base::nullopt; in TEST_F()
64 n2->rects.emplace(); in TEST_F()
67 n2->rects->push_back(CreateRect()); in TEST_F()
68 n2->rects->push_back(CreateRect()); in TEST_F()
71 n2->rects->resize(1); in TEST_F()
72 (*n2->rects)[0]->width = 0; in TEST_F()
75 (*n2->rects)[0] = CreateRect(); in TEST_F()
Dstruct_unittest.cc130 EXPECT_FALSE(clone_region->rects); in TEST_F()
136 region->rects.emplace(2); in TEST_F()
137 (*region->rects)[1] = MakeRect(); in TEST_F()
139 EXPECT_EQ(2u, clone_region->rects->size()); in TEST_F()
140 EXPECT_TRUE((*clone_region->rects)[0].is_null()); in TEST_F()
141 CheckRect(*(*clone_region->rects)[1]); in TEST_F()
197 std::vector<RectPtr> rects; in TEST_F() local
199 rects.push_back(MakeRect(static_cast<int32_t>(i) + 1)); in TEST_F()
202 NamedRegion::New(std::string("region"), std::move(rects))); in TEST_F()
223 EXPECT_EQ(4U, region2->rects->size()); in TEST_F()
[all …]
/external/skqp/tests/
DGpuRectanizerTest.cpp33 const SkTDArray<SkISize>& rects) { in test_rectanizer_inserts() argument
35 for (i = 0; i < rects.count(); ++i) { in test_rectanizer_inserts()
37 if (!rectanizer->addRect(rects[i].fWidth, rects[i].fHeight, &loc)) { in test_rectanizer_inserts()
45 static void test_skyline(skiatest::Reporter* reporter, const SkTDArray<SkISize>& rects) { in test_skyline() argument
49 test_rectanizer_inserts(reporter, &skylineRectanizer, rects); in test_skyline()
52 static void test_pow2(skiatest::Reporter* reporter, const SkTDArray<SkISize>& rects) { in test_pow2() argument
56 test_rectanizer_inserts(reporter, &pow2Rectanizer, rects); in test_pow2()
60 SkTDArray<SkISize> rects; in DEF_GPUTEST() local
64 rects.push_back(SkISize::Make(rand.nextRangeU(1, kWidth / 2), in DEF_GPUTEST()
68 test_skyline(reporter, rects); in DEF_GPUTEST()
[all …]
DRTreeTest.cpp28 static bool verify_query(SkRect query, SkRect rects[], SkTDArray<int>& found) { in verify_query() argument
32 if (SkRect::Intersects(query, rects[i])) { in verify_query()
46 static void run_queries(skiatest::Reporter* reporter, SkRandom& rand, SkRect rects[], in run_queries() argument
52 REPORTER_ASSERT(reporter, verify_query(query, rects, hits)); in run_queries()
74 SkAutoTMalloc<SkRect> rects(NUM_RECTS); in DEF_TEST() local
80 rects[j] = random_rect(rand); in DEF_TEST()
83 rtree.insert(rects.get(), NUM_RECTS); in DEF_TEST()
84 SkASSERT(rects); // SkRTree doesn't take ownership of rects. in DEF_TEST()
86 run_queries(reporter, rand, rects, rtree); in DEF_TEST()
DFlattenableFactoryToName.cpp28 SkIRect rects[2]; in DEF_TEST() local
29 rects[0] = SkIRect::MakeXYWH(0, 150, 500, 200); in DEF_TEST()
30 rects[1] = SkIRect::MakeXYWH(150, 0, 200, 500); in DEF_TEST()
32 region.setRects(rects, 2); in DEF_TEST()
/external/skia/tests/
DGpuRectanizerTest.cpp30 const SkTDArray<SkISize>& rects) { in test_rectanizer_inserts() argument
32 for (i = 0; i < rects.count(); ++i) { in test_rectanizer_inserts()
34 if (!rectanizer->addRect(rects[i].fWidth, rects[i].fHeight, &loc)) { in test_rectanizer_inserts()
42 static void test_skyline(skiatest::Reporter* reporter, const SkTDArray<SkISize>& rects) { in test_skyline() argument
46 test_rectanizer_inserts(reporter, &skylineRectanizer, rects); in test_skyline()
50 SkTDArray<SkISize> rects; in DEF_GPUTEST() local
54 rects.push_back(SkISize::Make(rand.nextRangeU(1, kWidth / 2), in DEF_GPUTEST()
58 test_skyline(reporter, rects); in DEF_GPUTEST()
DRTreeTest.cpp28 static bool verify_query(SkRect query, SkRect rects[], const std::vector<int>& found) { in verify_query() argument
32 if (SkRect::Intersects(query, rects[i])) { in verify_query()
46 static void run_queries(skiatest::Reporter* reporter, SkRandom& rand, SkRect rects[], in run_queries() argument
52 REPORTER_ASSERT(reporter, verify_query(query, rects, hits)); in run_queries()
74 SkAutoTMalloc<SkRect> rects(NUM_RECTS); in DEF_TEST() local
80 rects[j] = random_rect(rand); in DEF_TEST()
83 rtree.insert(rects.get(), NUM_RECTS); in DEF_TEST()
84 SkASSERT(rects); // SkRTree doesn't take ownership of rects. in DEF_TEST()
86 run_queries(reporter, rand, rects, rtree); in DEF_TEST()
DFlattenableFactoryToName.cpp28 SkIRect rects[2]; in DEF_TEST() local
29 rects[0] = SkIRect::MakeXYWH(0, 150, 500, 200); in DEF_TEST()
30 rects[1] = SkIRect::MakeXYWH(150, 0, 200, 500); in DEF_TEST()
32 region.setRects(rects, 2); in DEF_TEST()
/external/skqp/src/core/
DSkMaskCache.cpp102 RectsBlurKey(SkScalar sigma, SkBlurStyle style, const SkRect rects[], int count) in RectsBlurKey()
108 rects[0].roundOut(&ir); in RectsBlurKey()
109 fSizes[0] = SkSize{rects[0].width(), rects[0].height()}; in RectsBlurKey()
111 fSizes[1] = SkSize{rects[1].width(), rects[1].height()}; in RectsBlurKey()
112 fSizes[2] = SkSize{rects[0].x() - rects[1].x(), rects[0].y() - rects[1].y()}; in RectsBlurKey()
117 fSizes[3] = SkSize{rects[0].x() - ir.x(), rects[0].y() - ir.y()}; in RectsBlurKey()
167 const SkRect rects[], int count, SkMask* mask, in FindAndRef() argument
170 RectsBlurKey key(sigma, style, rects, count); in FindAndRef()
181 const SkRect rects[], int count, const SkMask& mask, SkCachedData* data, in Add() argument
183 RectsBlurKey key(sigma, style, rects, count); in Add()
DSkBlurMF.cpp345 static bool draw_rects_into_mask(const SkRect rects[], int count, SkMask* mask) { in draw_rects_into_mask() argument
346 if (!prepare_to_draw_into_mask(rects[0], mask)) { in draw_rects_into_mask()
365 canvas.drawRect(rects[0], paint); in draw_rects_into_mask()
369 path.addRect(rects[0]); in draw_rects_into_mask()
370 path.addRect(rects[1]); in draw_rects_into_mask()
410 const SkRect rects[], int count) { in find_cached_rects() argument
411 return SkMaskCache::FindAndRef(sigma, style, rects, count, mask); in find_cached_rects()
415 const SkRect rects[], int count) { in add_cached_rects() argument
418 SkMaskCache::Add(sigma, style, rects, count, *mask, cache); in add_cached_rects()
562 SkBlurMaskFilterImpl::filterRectsToNine(const SkRect rects[], int count, in filterRectsToNine() argument
[all …]
/external/skia/src/core/
DSkMaskCache.cpp102 RectsBlurKey(SkScalar sigma, SkBlurStyle style, const SkRect rects[], int count) in RectsBlurKey()
108 rects[0].roundOut(&ir); in RectsBlurKey()
109 fSizes[0] = SkSize{rects[0].width(), rects[0].height()}; in RectsBlurKey()
111 fSizes[1] = SkSize{rects[1].width(), rects[1].height()}; in RectsBlurKey()
112 fSizes[2] = SkSize{rects[0].x() - rects[1].x(), rects[0].y() - rects[1].y()}; in RectsBlurKey()
117 fSizes[3] = SkSize{rects[0].x() - ir.x(), rects[0].y() - ir.y()}; in RectsBlurKey()
167 const SkRect rects[], int count, SkMask* mask, in FindAndRef() argument
170 RectsBlurKey key(sigma, style, rects, count); in FindAndRef()
181 const SkRect rects[], int count, const SkMask& mask, SkCachedData* data, in Add() argument
183 RectsBlurKey key(sigma, style, rects, count); in Add()
/external/mesa3d/src/imgui/
Dimstb_rectpack.h88 STBRP_DEF int stbrp_pack_rects (stbrp_context *context, stbrp_rect *rects, int num_rects);
549 STBRP_DEF int stbrp_pack_rects(stbrp_context *context, stbrp_rect *rects, int num_rects) in stbrp_pack_rects() argument
555 rects[i].was_packed = i; in stbrp_pack_rects()
559 STBRP_SORT(rects, num_rects, sizeof(rects[0]), rect_height_compare); in stbrp_pack_rects()
562 if (rects[i].w == 0 || rects[i].h == 0) { in stbrp_pack_rects()
563 rects[i].x = rects[i].y = 0; // empty rect needs no space in stbrp_pack_rects()
565 stbrp__findresult fr = stbrp__skyline_pack_rectangle(context, rects[i].w, rects[i].h); in stbrp_pack_rects()
567 rects[i].x = (stbrp_coord) fr.x; in stbrp_pack_rects()
568 rects[i].y = (stbrp_coord) fr.y; in stbrp_pack_rects()
570 rects[i].x = rects[i].y = STBRP__MAXVAL; in stbrp_pack_rects()
[all …]
/external/skia/docs/examples/
DRegion_setRects.cpp7 SkIRect rects[] = { {10, 10, 40, 40}, {20, 20, 50, 50}, {30, 30, 60, 60} }; in draw() local
9 region.setRects(rects, SK_ARRAY_COUNT(rects)); in draw()
12 for (auto add : rects) { in draw()
DRegion_translate.cpp8 SkIRect rects[] = {{40, 20, 50, 30}, {70, 40, 80, 50}, { 60, 10, 70, 20}}; in draw() local
9 test.setRects(rects, SK_ARRAY_COUNT(rects)); in draw()
DRegion_Iterator_next.cpp8 SkIRect rects[] = {{1, 2, 3, 4}, {5, 6, 7, 8}}; in draw() local
9 region.setRects(rects, SK_ARRAY_COUNT(rects)); in draw()
DRegion_Cliperator_next.cpp8 SkIRect rects[] = {{1, 2, 3, 4}, {5, 6, 7, 8}}; in draw() local
9 region.setRects(rects, SK_ARRAY_COUNT(rects)); in draw()
DRegion_quickReject_2.cpp9 SkIRect rects[] = {{4, 2, 5, 3}, {7, 2, 8, 3}}; in draw() local
10 test.setRects(rects, SK_ARRAY_COUNT(rects)); in draw()
DRegion_translate_2.cpp8 SkIRect rects[] = {{40, 20, 50, 30}, {70, 40, 80, 50}, { 60, 10, 70, 20}}; in draw() local
9 test.setRects(rects, SK_ARRAY_COUNT(rects)); in draw()
DRegion_Iterator_rgn.cpp8 SkIRect rects[] = {{1, 2, 3, 4}, {3, 4, 5, 6}}; in draw() local
9 region.setRects(rects, SK_ARRAY_COUNT(rects)); in draw()
/external/skia/gm/
Dimagealphathreshold.cpp46 SkIRect rects[2]; in create_filter_paint() local
47 rects[0] = SkIRect::MakeXYWH(0, 150, WIDTH, HEIGHT - 300); in create_filter_paint()
48 rects[1] = SkIRect::MakeXYWH(150, 0, WIDTH - 300, HEIGHT); in create_filter_paint()
50 region.setRects(rects, 2); in create_filter_paint()
195 SkIRect rects[2]; variable
196 rects[0] = SkIRect::MakeXYWH(0, 150, WIDTH, HEIGHT - 300);
197 rects[1] = SkIRect::MakeXYWH(150, 0, WIDTH - 300, HEIGHT);
199 region.setRects(rects, 2);
/external/skqp/gm/
Dimagealphathreshold.cpp33 SkIRect rects[2]; in create_filter_paint() local
34 rects[0] = SkIRect::MakeXYWH(0, 150, WIDTH, HEIGHT - 300); in create_filter_paint()
35 rects[1] = SkIRect::MakeXYWH(150, 0, WIDTH - 300, HEIGHT); in create_filter_paint()
37 region.setRects(rects, 2); in create_filter_paint()
180 SkIRect rects[2]; variable
181 rects[0] = SkIRect::MakeXYWH(0, 150, WIDTH, HEIGHT - 300);
182 rects[1] = SkIRect::MakeXYWH(150, 0, WIDTH - 300, HEIGHT);
184 region.setRects(rects, 2);
/external/skia/bench/
DRTreeBench.cpp39 SkAutoTMalloc<SkRect> rects(NUM_BUILD_RECTS); in onDraw() local
41 rects[i] = fProc(rand, i, NUM_BUILD_RECTS); in onDraw()
46 tree.insert(rects.get(), NUM_BUILD_RECTS); in onDraw()
47 … SkASSERT(rects != nullptr); // It'd break this bench if the tree took ownership of rects. in onDraw()
72 SkAutoTMalloc<SkRect> rects(NUM_QUERY_RECTS); in onDelayedSetup() local
74 rects[i] = fProc(rand, i, NUM_QUERY_RECTS); in onDelayedSetup()
76 fTree.insert(rects.get(), NUM_QUERY_RECTS); in onDelayedSetup()
/external/skqp/bench/
DRTreeBench.cpp39 SkAutoTMalloc<SkRect> rects(NUM_BUILD_RECTS); in onDraw() local
41 rects[i] = fProc(rand, i, NUM_BUILD_RECTS); in onDraw()
46 tree.insert(rects.get(), NUM_BUILD_RECTS); in onDraw()
47 … SkASSERT(rects != nullptr); // It'd break this bench if the tree took ownership of rects. in onDraw()
72 SkAutoTMalloc<SkRect> rects(NUM_QUERY_RECTS); in onDelayedSetup() local
74 rects[i] = fProc(rand, i, NUM_QUERY_RECTS); in onDelayedSetup()
76 fTree.insert(rects.get(), NUM_QUERY_RECTS); in onDelayedSetup()
/external/mesa3d/src/amd/vulkan/
Dradv_meta_blit2d.c250 struct radv_meta_blit2d_rect *rects, enum blit2d_src_type src_type, in radv_meta_blit2d_normal_dst() argument
272 blit2d_bind_dst(cmd_buffer, dst, rects[r].dst_x + rects[r].width, in radv_meta_blit2d_normal_dst()
273 rects[r].dst_y + rects[r].height, depth_format, &dst_temps, aspect_mask); in radv_meta_blit2d_normal_dst()
276 rects[r].src_x, in radv_meta_blit2d_normal_dst()
277 rects[r].src_y, in radv_meta_blit2d_normal_dst()
278 rects[r].src_x + rects[r].width, in radv_meta_blit2d_normal_dst()
279 rects[r].src_y + rects[r].height, in radv_meta_blit2d_normal_dst()
308 .offset = { rects[r].dst_x, rects[r].dst_y, }, in radv_meta_blit2d_normal_dst()
309 .extent = { rects[r].width, rects[r].height }, in radv_meta_blit2d_normal_dst()
336 .offset = { rects[r].dst_x, rects[r].dst_y, }, in radv_meta_blit2d_normal_dst()
[all …]

123456789