Home
last modified time | relevance | path

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

12345678910>>...14

/third_party/ffmpeg/libavcodec/
Dxsubdec.c99 sub->rects = av_mallocz(sizeof(*sub->rects)); in decode_frame()
100 if (!sub->rects) in decode_frame()
103 sub->rects[0] = av_mallocz(sizeof(*sub->rects[0])); in decode_frame()
104 if (!sub->rects[0]) { in decode_frame()
105 av_freep(&sub->rects); in decode_frame()
108 sub->rects[0]->x = x; sub->rects[0]->y = y; in decode_frame()
109 sub->rects[0]->w = w; sub->rects[0]->h = h; in decode_frame()
110 sub->rects[0]->type = SUBTITLE_BITMAP; in decode_frame()
111 sub->rects[0]->linesize[0] = w; in decode_frame()
112 sub->rects[0]->data[0] = av_malloc(w * h); in decode_frame()
[all …]
Ddvdsubdec.c207 if (sub_header->rects) { in reset_rects()
209 av_freep(&sub_header->rects[i]->data[0]); in reset_rects()
210 av_freep(&sub_header->rects[i]->data[1]); in reset_rects()
211 av_freep(&sub_header->rects[i]); in reset_rects()
213 av_freep(&sub_header->rects); in reset_rects()
374 sub_header->rects = av_mallocz(sizeof(*sub_header->rects)); in decode_dvd_subtitles()
375 if (!sub_header->rects) in decode_dvd_subtitles()
377 sub_header->rects[0] = av_mallocz(sizeof(AVSubtitleRect)); in decode_dvd_subtitles()
378 if (!sub_header->rects[0]) in decode_dvd_subtitles()
381 bitmap = sub_header->rects[0]->data[0] = av_malloc(w * h); in decode_dvd_subtitles()
[all …]
Dxsubenc.c137 if (!h->rects[0]->data[0]) { in xsub_encode()
138 AVSubtitleRect *rect = h->rects[0]; in xsub_encode()
149 if (!h->rects[0]->data[0] || !h->rects[0]->data[1]) { in xsub_encode()
155 if (h->rects[0]->nb_colors > 4) in xsub_encode()
156 … AV_LOG_WARNING, "No more than 4 subtitle colors supported (%d found.)\n", h->rects[0]->nb_colors); in xsub_encode()
159 if (((uint32_t *)h->rects[0]->data[1])[0] & 0xff000000) in xsub_encode()
176 width = FFALIGN(h->rects[0]->w, 2) + PADDING * 2; in xsub_encode()
177 height = FFALIGN(h->rects[0]->h, 2); in xsub_encode()
181 bytestream_put_le16(&hdr, h->rects[0]->x); in xsub_encode()
182 bytestream_put_le16(&hdr, h->rects[0]->y); in xsub_encode()
[all …]
Ddvbsubenc.c283 if (h->num_rects && !h->rects) in dvbsub_encode()
319 bytestream_put_be16(&q, h->rects[region_id]->x); /* left pos */ in dvbsub_encode()
320 bytestream_put_be16(&q, h->rects[region_id]->y); /* top pos */ in dvbsub_encode()
328 if (buf_size < 6 + h->rects[clut_id]->nb_colors * 6) in dvbsub_encode()
333 if (h->rects[clut_id]->nb_colors <= 4) { in dvbsub_encode()
336 } else if (h->rects[clut_id]->nb_colors <= 16) { in dvbsub_encode()
339 } else if (h->rects[clut_id]->nb_colors <= 256) { in dvbsub_encode()
356 for(i = 0; i < h->rects[clut_id]->nb_colors; i++) { in dvbsub_encode()
361 uint32_t x= ((uint32_t*)h->rects[clut_id]->data[1])[i]; in dvbsub_encode()
375 buf_size -= 6 + h->rects[clut_id]->nb_colors * 6; in dvbsub_encode()
[all …]
Ddvdsubenc.c258 int i, rects = h->num_rects, ret; in encode_dvd_subtitles() local
268 if (rects == 0 || !h->rects) in encode_dvd_subtitles()
270 for (i = 0; i < rects; i++) in encode_dvd_subtitles()
271 if (h->rects[i]->type != SUBTITLE_BITMAP) { in encode_dvd_subtitles()
276 for (i = 0; i < rects; i++) in encode_dvd_subtitles()
277 if ((h->rects[i]->flags & AV_SUBTITLE_FLAG_FORCED) != 0) { in encode_dvd_subtitles()
284 for (i = 0; i < rects; i++) in encode_dvd_subtitles()
285 if (!h->rects[i]->data[0]) { in encode_dvd_subtitles()
286 AVSubtitleRect *rect = h->rects[i]; in encode_dvd_subtitles()
296 vrect = *h->rects[0]; in encode_dvd_subtitles()
[all …]
Dass.c123 AVSubtitleRect **rects; in ff_ass_add_rect() local
125 rects = av_realloc_array(sub->rects, sub->num_rects+1, sizeof(*sub->rects)); in ff_ass_add_rect()
126 if (!rects) in ff_ass_add_rect()
128 sub->rects = rects; in ff_ass_add_rect()
129 rects[sub->num_rects] = av_mallocz(sizeof(*rects[0])); in ff_ass_add_rect()
130 if (!rects[sub->num_rects]) in ff_ass_add_rect()
132 rects[sub->num_rects]->type = SUBTITLE_ASS; in ff_ass_add_rect()
136 rects[sub->num_rects]->ass = ass_str; in ff_ass_add_rect()
Dassdec.c49 sub->rects = av_malloc(sizeof(*sub->rects)); in ass_decode_frame()
50 if (!sub->rects) in ass_decode_frame()
52 sub->rects[0] = av_mallocz(sizeof(*sub->rects[0])); in ass_decode_frame()
53 if (!sub->rects[0]) in ass_decode_frame()
56 sub->rects[0]->type = SUBTITLE_ASS; in ass_decode_frame()
57 sub->rects[0]->ass = av_strdup(avpkt->data); in ass_decode_frame()
58 if (!sub->rects[0]->ass) in ass_decode_frame()
Dpgssubdec.c521 sub->rects = av_mallocz_array(ctx->presentation.object_count, sizeof(*sub->rects)); in display_end_segment()
522 if (!sub->rects) { in display_end_segment()
536 sub->rects[i] = av_mallocz(sizeof(*sub->rects[0])); in display_end_segment()
537 if (!sub->rects[i]) { in display_end_segment()
542 sub->rects[i]->type = SUBTITLE_BITMAP; in display_end_segment()
558 sub->rects[i]->flags |= AV_SUBTITLE_FLAG_FORCED; in display_end_segment()
560 sub->rects[i]->x = ctx->presentation.objects[i].x; in display_end_segment()
561 sub->rects[i]->y = ctx->presentation.objects[i].y; in display_end_segment()
564 sub->rects[i]->w = object->w; in display_end_segment()
565 sub->rects[i]->h = object->h; in display_end_segment()
[all …]
/third_party/skia/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[], 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()
/third_party/flutter/skia/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()
/third_party/skia/bench/graphite/
DIntersectionTreeBench.cpp30 SkTArray<SkRect> rects; in onDelayedSetup() local
31 this->gatherRects(&rects); in onDelayedSetup()
32 fRectCount = rects.count(); in onDelayedSetup()
35 fRects[i] = rects[i]; in onDelayedSetup()
41 virtual void gatherRects(SkTArray<SkRect>* rects) = 0;
50 Rect* rects = fRects; in doBench() local
58 if (!intersectionTree.add(rects[i])) { in doBench()
59 collided[collidedCount++] = rects[i]; in doBench()
62 std::swap(rects, collided); in doBench()
87 void gatherRects(SkTArray<SkRect>* rects) override { in gatherRects() argument
[all …]
/third_party/flutter/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()
/third_party/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()
/third_party/flutter/skia/third_party/externals/imgui/
Dimstb_rectpack.h81 STBRP_DEF int stbrp_pack_rects (stbrp_context *context, stbrp_rect *rects, int num_rects);
539 STBRP_DEF int stbrp_pack_rects(stbrp_context *context, stbrp_rect *rects, int num_rects) in stbrp_pack_rects() argument
545 rects[i].was_packed = i; in stbrp_pack_rects()
547 STBRP_ASSERT(rects[i].w <= 0xffff && rects[i].h <= 0xffff); in stbrp_pack_rects()
552 STBRP_SORT(rects, num_rects, sizeof(rects[0]), rect_height_compare); in stbrp_pack_rects()
555 if (rects[i].w == 0 || rects[i].h == 0) { in stbrp_pack_rects()
556 rects[i].x = rects[i].y = 0; // empty rect needs no space in stbrp_pack_rects()
558 stbrp__findresult fr = stbrp__skyline_pack_rectangle(context, rects[i].w, rects[i].h); in stbrp_pack_rects()
560 rects[i].x = (stbrp_coord) fr.x; in stbrp_pack_rects()
561 rects[i].y = (stbrp_coord) fr.y; in stbrp_pack_rects()
[all …]
/third_party/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 …]
/third_party/skia/third_party/externals/imgui/
Dimstb_rectpack.h90 STBRP_DEF int stbrp_pack_rects (stbrp_context *context, stbrp_rect *rects, int num_rects);
558 STBRP_DEF int stbrp_pack_rects(stbrp_context *context, stbrp_rect *rects, int num_rects) in stbrp_pack_rects() argument
564 rects[i].was_packed = i; in stbrp_pack_rects()
568 STBRP_SORT(rects, num_rects, sizeof(rects[0]), rect_height_compare); in stbrp_pack_rects()
571 if (rects[i].w == 0 || rects[i].h == 0) { in stbrp_pack_rects()
572 rects[i].x = rects[i].y = 0; // empty rect needs no space in stbrp_pack_rects()
574 stbrp__findresult fr = stbrp__skyline_pack_rectangle(context, rects[i].w, rects[i].h); in stbrp_pack_rects()
576 rects[i].x = (stbrp_coord) fr.x; in stbrp_pack_rects()
577 rects[i].y = (stbrp_coord) fr.y; in stbrp_pack_rects()
579 rects[i].x = rects[i].y = STBRP__MAXVAL; in stbrp_pack_rects()
[all …]
/third_party/flutter/skia/third_party/externals/sdl/src/video/x11/
DSDL_x11framebuffer.c146 X11_UpdateWindowFramebuffer(_THIS, SDL_Window * window, const SDL_Rect * rects, in X11_UpdateWindowFramebuffer() argument
156 x = rects[i].x; in X11_UpdateWindowFramebuffer()
157 y = rects[i].y; in X11_UpdateWindowFramebuffer()
158 w = rects[i].w; in X11_UpdateWindowFramebuffer()
159 h = rects[i].h; in X11_UpdateWindowFramebuffer()
168 w += rects[i].x; in X11_UpdateWindowFramebuffer()
173 h += rects[i].y; in X11_UpdateWindowFramebuffer()
188 x = rects[i].x; in X11_UpdateWindowFramebuffer()
189 y = rects[i].y; in X11_UpdateWindowFramebuffer()
190 w = rects[i].w; in X11_UpdateWindowFramebuffer()
[all …]
/third_party/flutter/skia/docs/examples/
DPath_isNestedFillRects.cpp13 SkRect rects[2]; in draw() local
15 if (path.isNestedFillRects(rects, directions)) { in draw()
18 rects[i].fLeft, rects[i].fTop, rects[i].fRight, rects[i].fBottom, in draw()
/third_party/flutter/skia/third_party/externals/sdl/src/video/mir/
DSDL_mirframebuffer.c62 const SDL_Rect* rects, int numrects) in MIR_UpdateWindowFramebuffer() argument
87 x = rects[i].x; in MIR_UpdateWindowFramebuffer()
88 y = rects[i].y; in MIR_UpdateWindowFramebuffer()
89 w = rects[i].w; in MIR_UpdateWindowFramebuffer()
90 h = rects[i].h; in MIR_UpdateWindowFramebuffer()
97 w += rects[i].x; in MIR_UpdateWindowFramebuffer()
102 h += rects[i].y; in MIR_UpdateWindowFramebuffer()
/third_party/gstreamer/gstplugins_good/sys/ximage/
Dgstximagesrc.c561 XRectangle *rects; in gst_ximage_src_ximage_get() local
565 rects = in gst_ximage_src_ximage_get()
568 if (rects != NULL) { in gst_ximage_src_ximage_get()
581 rects[i].x, rects[i].y, rects[i].width, rects[i].height); in gst_ximage_src_ximage_get()
588 if (rects[i].x + rects[i].width - 1 < ximagesrc->startx || in gst_ximage_src_ximage_get()
589 rects[i].x > ximagesrc->endx) { in gst_ximage_src_ximage_get()
591 } else if (rects[i].y + rects[i].height - 1 < ximagesrc->starty || in gst_ximage_src_ximage_get()
592 rects[i].y > ximagesrc->endy) { in gst_ximage_src_ximage_get()
598 startx = (rects[i].x < ximagesrc->startx) ? ximagesrc->startx : in gst_ximage_src_ximage_get()
599 rects[i].x; in gst_ximage_src_ximage_get()
[all …]
/third_party/mesa3d/src/broadcom/vulkan/
Dv3dv_meta_clear.c980 const VkClearRect *rects) in emit_subpass_color_clear_rects() argument
1033 .x = rects[i].rect.offset.x, in emit_subpass_color_clear_rects()
1034 .y = rects[i].rect.offset.y, in emit_subpass_color_clear_rects()
1035 .width = rects[i].rect.extent.width, in emit_subpass_color_clear_rects()
1036 .height = rects[i].rect.extent.height, in emit_subpass_color_clear_rects()
1041 v3dv_CmdSetScissor(cmd_buffer_handle, 0, 1, &rects[i].rect); in emit_subpass_color_clear_rects()
1044 for (uint32_t layer_offset = 0; layer_offset < rects[i].layerCount; in emit_subpass_color_clear_rects()
1046 uint32_t layer = rects[i].baseArrayLayer + layer_offset; in emit_subpass_color_clear_rects()
1053 assert(rects[i].baseArrayLayer == 0 && rects[i].layerCount == 1); in emit_subpass_color_clear_rects()
1082 const VkClearRect *rects) in emit_subpass_ds_clear_rects() argument
[all …]
/third_party/mesa3d/src/amd/vulkan/
Dradv_meta_blit2d.c201 struct radv_meta_blit2d_rect *rects, enum blit2d_src_type src_type, in radv_meta_blit2d_normal_dst() argument
227 rects[r].src_x, in radv_meta_blit2d_normal_dst()
228 rects[r].src_y, in radv_meta_blit2d_normal_dst()
229 rects[r].src_x + rects[r].width, in radv_meta_blit2d_normal_dst()
230 rects[r].src_y + rects[r].height, in radv_meta_blit2d_normal_dst()
264 .offset = { rects[r].dst_x, rects[r].dst_y }, in radv_meta_blit2d_normal_dst()
265 .extent = { rects[r].width, rects[r].height }, in radv_meta_blit2d_normal_dst()
296 .offset = { rects[r].dst_x, rects[r].dst_y }, in radv_meta_blit2d_normal_dst()
297 .extent = { rects[r].width, rects[r].height }, in radv_meta_blit2d_normal_dst()
330 .offset = { rects[r].dst_x, rects[r].dst_y }, in radv_meta_blit2d_normal_dst()
[all …]
/third_party/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);

12345678910>>...14