Home
last modified time | relevance | path

Searched refs:nb_threads (Results 1 – 25 of 37) sorted by relevance

12

/third_party/ffmpeg/libavfilter/
Dpthread.c47 static void worker_func(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads) in worker_func() argument
76 static int thread_init_internal(ThreadContext *c, int nb_threads) in thread_init_internal() argument
78 nb_threads = avpriv_slicethread_create(&c->thread, c, worker_func, NULL, nb_threads); in thread_init_internal()
79 if (nb_threads <= 1) in thread_init_internal()
81 return FFMAX(nb_threads, 1); in thread_init_internal()
88 if (graph->nb_threads == 1) { in ff_graph_thread_init()
97 ret = thread_init_internal(graph->internal->thread, graph->nb_threads); in ff_graph_thread_init()
101 graph->nb_threads = 1; in ff_graph_thread_init()
104 graph->nb_threads = ret; in ff_graph_thread_init()
Dvf_colorconstancy.c82 int nb_threads; member
364 int src, int dst, int dim, int nb_threads) { in get_deriv() argument
369 ctx->internal->execute(ctx, slice_get_derivative, td, NULL, FFMIN(dim, nb_threads)); in get_deriv()
384 int nb_threads = s->nb_threads; in get_derivative() local
391 get_deriv(ctx, td, 0, DIR_X, 0 , INDEX_NORM, height, nb_threads); in get_derivative()
393 get_deriv(ctx, td, 0, DIR_X, 0, INDEX_TEMP, height, nb_threads); in get_derivative()
394 get_deriv(ctx, td, 0, DIR_Y, INDEX_TEMP, INDEX_NORM, width , nb_threads); in get_derivative()
401 get_deriv(ctx, td, 1, DIR_X, 0, INDEX_TEMP, height, nb_threads); in get_derivative()
402 get_deriv(ctx, td, 0, DIR_Y, INDEX_TEMP, INDEX_DX, width , nb_threads); in get_derivative()
404 get_deriv(ctx, td, 0, DIR_X, 0, INDEX_TEMP, height, nb_threads); in get_derivative()
[all …]
Dvf_vif.c47 int nb_threads; member
318 const int nb_threads = FFMIN(h, gnb_threads); in ff_compute_vif2() local
333 ctx->internal->execute(ctx, vif_filter1d, &td, NULL, nb_threads); in ff_compute_vif2()
338 ctx->internal->execute(ctx, vif_filter1d, &td, NULL, nb_threads); in ff_compute_vif2()
363 ctx->internal->execute(ctx, vif_filter1d, &td, NULL, nb_threads); in ff_compute_vif2()
368 ctx->internal->execute(ctx, vif_filter1d, &td, NULL, nb_threads); in ff_compute_vif2()
377 ctx->internal->execute(ctx, vif_filter1d, &td, NULL, nb_threads); in ff_compute_vif2()
382 ctx->internal->execute(ctx, vif_filter1d, &td, NULL, nb_threads); in ff_compute_vif2()
386 ctx->internal->execute(ctx, vif_filter1d, &td, NULL, nb_threads); in ff_compute_vif2()
455 s->nb_threads); in do_vif()
[all …]
Dvf_unsharp.c167 ctx->internal->execute(ctx, s->unsharp_slice, &td, NULL, FFMIN(plane_h[i], s->nb_threads)); in apply_unsharp_c()
233 fp->sr = av_malloc_array((MAX_MATRIX_SIZE - 1) * s->nb_threads, sizeof(uint32_t)); in init_filter_param()
234 fp->sc = av_mallocz_array(2 * fp->steps_y * s->nb_threads, sizeof(uint32_t *)); in init_filter_param()
238 for (z = 0; z < 2 * fp->steps_y * s->nb_threads; z++) in init_filter_param()
260 s->nb_threads = FFMIN(ff_filter_get_nb_threads(inlink->dst), in config_input()
273 static void free_filter_param(UnsharpFilterParam *fp, int nb_threads) in free_filter_param() argument
278 for (z = 0; z < 2 * fp->steps_y * nb_threads; z++) in free_filter_param()
289 free_filter_param(&s->luma, s->nb_threads); in uninit()
290 free_filter_param(&s->chroma, s->nb_threads); in uninit()
Dvf_median.c150 …s->nb_threads = FFMAX(1, FFMIN(s->planeheight[1] / (s->radiusV + 1), ff_filter_get_nb_threads(inli… in config_input()
154 s->coarse = av_calloc(s->nb_threads, sizeof(*s->coarse)); in config_input()
155 s->fine = av_calloc(s->nb_threads, sizeof(*s->fine)); in config_input()
158 for (int i = 0; i < s->nb_threads; i++) { in config_input()
234 ctx->internal->execute(ctx, filter_slice, &td, NULL, s->nb_threads); in filter_frame()
244 for (int i = 0; i < s->nb_threads && s->coarse && s->fine; i++) { in uninit()
Dvf_blackdetect.c50 int nb_threads; member
117 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input()
120 s->counter = av_calloc(s->nb_threads, sizeof(*s->counter)); in config_input()
195 FFMIN(inlink->h, s->nb_threads)); in filter_frame()
197 for (int i = 0; i < s->nb_threads; i++) in filter_frame()
Dvf_ssim.c54 int nb_threads; member
362 …ternal->execute(ctx, s->ssim_plane, &td, NULL, FFMIN((s->planeheight[1] + 3) >> 2, s->nb_threads)); in do_ssim()
365 for (int j = 0; j < s->nb_threads; j++) in do_ssim()
450 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input_ref()
478 s->temp = av_calloc(s->nb_threads, sizeof(*s->temp)); in config_input_ref()
482 for (int t = 0; t < s->nb_threads; t++) { in config_input_ref()
495 s->score = av_calloc(s->nb_threads, sizeof(*s->score)); in config_input_ref()
499 for (int t = 0; t < s->nb_threads && s->score; t++) { in config_input_ref()
566 for (int t = 0; t < s->nb_threads && s->score; t++) in uninit()
570 for (int t = 0; t < s->nb_threads && s->temp; t++) in uninit()
Dvf_identity.c48 int nb_threads; member
199 … ctx->internal->execute(ctx, s->filter_slice, &td, NULL, FFMIN(s->planeheight[1], s->nb_threads)); in do_identity()
201 for (int j = 0; j < s->nb_threads; j++) { in do_identity()
272 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input_ref()
295 s->scores = av_calloc(s->nb_threads, sizeof(*s->scores)); in config_input_ref()
299 for (int t = 0; t < s->nb_threads && s->scores; t++) { in config_input_ref()
381 for (int t = 0; t < s->nb_threads && s->scores; t++) in uninit()
Dvf_psnr.c54 int nb_threads; member
192 …tx->internal->execute(ctx, compute_images_mse, &td, NULL, FFMIN(s->planeheight[1], s->nb_threads)); in do_psnr()
194 for (int j = 0; j < s->nb_threads; j++) { in do_psnr()
330 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input_ref()
371 s->score = av_calloc(s->nb_threads, sizeof(*s->score)); in config_input_ref()
375 for (int t = 0; t < s->nb_threads && s->score; t++) { in config_input_ref()
441 for (int t = 0; t < s->nb_threads && s->score; t++) in uninit()
Dvf_nnedi.c77 int nb_threads; member
679 … ctx->internal->execute(ctx, filter_slice, dst, NULL, FFMIN(s->planeheight[1] / 2, s->nb_threads)); in get_frame()
1036 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input()
1077 s->input_buf = av_calloc(s->nb_threads, sizeof(*s->input_buf)); in config_input()
1081 for (int i = 0; i < s->nb_threads; i++) { in config_input()
1087 s->output_buf = av_calloc(s->nb_threads, sizeof(*s->output_buf)); in config_input()
1091 for (int i = 0; i < s->nb_threads; i++) { in config_input()
1097 s->prescreen_buf = av_calloc(s->nb_threads, sizeof(*s->prescreen_buf)); in config_input()
1101 for (int i = 0; i < s->nb_threads; i++) { in config_input()
1114 for (int i = 0; i < s->nb_threads && s->prescreen_buf; i++) in uninit()
[all …]
Dvf_w3fdif.c47 int nb_threads; member
300 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input()
301 s->work_line = av_calloc(s->nb_threads, sizeof(*s->work_line)); in config_input()
305 for (i = 0; i < s->nb_threads; i++) { in config_input()
512 …ctx->internal->execute(ctx, deinterlace_slice, &td, NULL, FFMIN(s->planeheight[1], s->nb_threads)); in filter()
592 for (i = 0; i < s->nb_threads; i++) in uninit()
Dvf_yaepblur.c227 const int nb_threads = ff_filter_get_nb_threads(ctx); in FILTER_SLICE() local
256 ctx->internal->execute(ctx, s->pre_calculate_row, &td, NULL, FFMIN(td.height, nb_threads)); in FILTER_SLICE()
257 ctx->internal->execute(ctx, pre_calculate_col, &td, NULL, FFMIN(td.width, nb_threads)); in FILTER_SLICE()
261 ctx->internal->execute(ctx, s->filter_slice, &td, NULL, FFMIN(td.height, nb_threads)); in FILTER_SLICE()
Dvf_gblur.c191 const int nb_threads = ff_filter_get_nb_threads(ctx); in gaussianiir2d() local
199 ctx->internal->execute(ctx, filter_horizontally, &td, NULL, FFMIN(height, nb_threads)); in gaussianiir2d()
200 ctx->internal->execute(ctx, filter_vertically, &td, NULL, FFMIN(width, nb_threads)); in gaussianiir2d()
201 ctx->internal->execute(ctx, filter_postscale, &td, NULL, FFMIN(width * height, nb_threads)); in gaussianiir2d()
Dvif.h30 float *data_buf[13], float **temp, int nb_threads);
Dvf_dctdnoiz.c50 int nb_threads; member
570 s->nb_threads = FFMIN3(MAX_THREADS, ff_filter_get_nb_threads(ctx), max_slice_h); in config_input()
572 MAX_THREADS, max_slice_h, ff_filter_get_nb_threads(ctx), s->nb_threads); in config_input()
586 for (i = 0; i < s->nb_threads; i++) { in config_input()
597 slice_h = (int)ceilf(s->pr_height / (float)s->nb_threads) + (s->bsize - 1) * 2; in config_input()
598 for (i = 0; i < s->nb_threads; i++) { in config_input()
751 ctx->internal->execute(ctx, filter_slice, &td, NULL, s->nb_threads); in filter_frame()
804 for (i = 0; i < s->nb_threads; i++) { in uninit()
Dvf_avgblur.c212 const int nb_threads = ff_filter_get_nb_threads(ctx); in averageiir2d() local
219 ctx->internal->execute(ctx, s->filter_horizontally, &td, NULL, FFMIN(height, nb_threads)); in averageiir2d()
222 ctx->internal->execute(ctx, s->filter_vertically, &td, NULL, FFMIN(width, nb_threads)); in averageiir2d()
Davfilter.h404 int nb_threads; member
879 int nb_threads; member
Dunsharp.h53 int nb_threads; member
Dmedian.h40 int nb_threads; member
Dconvolution.h48 int nb_threads; member
Dv360.h173 int nb_threads; member
Dvf_estdif.c47 int nb_threads; member
450 FFMIN(s->planeheight[1] / 2, s->nb_threads)); in filter()
479 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input()
/third_party/ffmpeg/libavutil/
Dslicethread.c37 int nb_threads; member
49 … void (*worker_func)(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads);
95 … void (*worker_func)(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads), in avpriv_slicethread_create() argument
97 int nb_threads) in avpriv_slicethread_create()
102 av_assert0(nb_threads >= 0); in avpriv_slicethread_create()
103 if (!nb_threads) { in avpriv_slicethread_create()
106 nb_threads = nb_cpus + 1; in avpriv_slicethread_create()
108 nb_threads = 1; in avpriv_slicethread_create()
111 nb_workers = nb_threads; in avpriv_slicethread_create()
127 ctx->nb_threads = nb_threads; in avpriv_slicethread_create()
[all …]
Dslicethread.h34 … void (*worker_func)(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads),
36 int nb_threads);
/third_party/ffmpeg/tools/
Dvenc_data_dump.c113 const char *filename, *thread_type = NULL, *nb_threads = NULL; in main() local
125 nb_threads = argv[4]; in main()
129 ret = av_dict_set(&opts, "threads", nb_threads, 0); in main()

12