Home
last modified time | relevance | path

Searched refs:nb_threads (Results 1 - 25 of 45) sorted by relevance

12

/third_party/ffmpeg/libavutil/
H A Dslicethread.c39 int nb_threads; member
51 void (*worker_func)(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads);
97 void (*worker_func)(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads), in avpriv_slicethread_create()
99 int nb_threads) in avpriv_slicethread_create()
104 av_assert0(nb_threads >= 0); in avpriv_slicethread_create()
105 if (!nb_threads) { in avpriv_slicethread_create()
108 nb_threads = nb_cpus + 1; in avpriv_slicethread_create()
110 nb_threads = 1; in avpriv_slicethread_create()
113 nb_workers = nb_threads; in avpriv_slicethread_create()
129 ctx->nb_threads in avpriv_slicethread_create()
96 avpriv_slicethread_create(AVSliceThread **pctx, void *priv, void (*worker_func)(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads), void (*main_func)(void *priv), int nb_threads) avpriv_slicethread_create() argument
238 avpriv_slicethread_create(AVSliceThread **pctx, void *priv, void (*worker_func)(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads), void (*main_func)(void *priv), int nb_threads) avpriv_slicethread_create() argument
[all...]
H A Dslicethread.h30 * @param nb_threads number of threads, 0 for automatic, must be >= 0
34 void (*worker_func)(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads),
36 int nb_threads);
/third_party/ffmpeg/libavfilter/
H A Dpthread.c46 static void worker_func(void *priv, int jobnr, int threadnr, int nb_jobs, int nb_threads) in worker_func() argument
75 static int thread_init_internal(ThreadContext *c, int nb_threads) in thread_init_internal() argument
77 nb_threads = avpriv_slicethread_create(&c->thread, c, worker_func, NULL, nb_threads); in thread_init_internal()
78 if (nb_threads <= 1) in thread_init_internal()
80 return FFMAX(nb_threads, 1); in thread_init_internal()
87 if (graph->nb_threads == 1) { in ff_graph_thread_init()
96 ret = thread_init_internal(graph->internal->thread, graph->nb_threads); in ff_graph_thread_init()
100 graph->nb_threads = 1; in ff_graph_thread_init()
103 graph->nb_threads in ff_graph_thread_init()
[all...]
H A Dvf_colorconstancy.c84 int nb_threads; member
363 * @param nb_threads number of threads to use.
367 int src, int dst, int dim, int nb_threads) { in get_deriv()
373 NULL, FFMIN(dim, nb_threads)); in get_deriv()
388 int nb_threads = s->nb_threads; in get_derivative() local
395 get_deriv(ctx, td, 0, DIR_X, 0 , INDEX_NORM, height, nb_threads); in get_derivative()
397 get_deriv(ctx, td, 0, DIR_X, 0, INDEX_TEMP, height, nb_threads); in get_derivative()
398 get_deriv(ctx, td, 0, DIR_Y, INDEX_TEMP, INDEX_NORM, width , nb_threads); in get_derivative()
405 get_deriv(ctx, td, 1, DIR_X, 0, INDEX_TEMP, height, nb_threads); in get_derivative()
366 get_deriv(AVFilterContext *ctx, ThreadData *td, int ord, int dir, int src, int dst, int dim, int nb_threads) get_deriv() argument
[all...]
H A Dvf_vif.c48 int nb_threads; member
319 const int nb_threads = FFMIN(h, gnb_threads); in compute_vif2() local
334 ff_filter_execute(ctx, vif_filter1d, &td, NULL, nb_threads); in compute_vif2()
339 ff_filter_execute(ctx, vif_filter1d, &td, NULL, nb_threads); in compute_vif2()
364 ff_filter_execute(ctx, vif_filter1d, &td, NULL, nb_threads); in compute_vif2()
369 ff_filter_execute(ctx, vif_filter1d, &td, NULL, nb_threads); in compute_vif2()
378 ff_filter_execute(ctx, vif_filter1d, &td, NULL, nb_threads); in compute_vif2()
383 ff_filter_execute(ctx, vif_filter1d, &td, NULL, nb_threads); in compute_vif2()
387 ff_filter_execute(ctx, vif_filter1d, &td, NULL, nb_threads); in compute_vif2()
454 score, s->data_buf, s->temp, s->nb_threads); in do_vif()
[all...]
H A Dvf_unsharp.c169 FFMIN(plane_h[i], s->nb_threads)); in apply_unsharp_c()
232 fp->sr = av_malloc_array((MAX_MATRIX_SIZE - 1) * s->nb_threads, sizeof(uint32_t)); in init_filter_param()
233 fp->sc = av_calloc(fp->steps_y * s->nb_threads, 2 * sizeof(*fp->sc)); in init_filter_param()
237 for (z = 0; z < 2 * fp->steps_y * s->nb_threads; z++) in init_filter_param()
258 // ensure (height / nb_threads) > 4 * steps_y, in config_input()
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()
[all...]
H A Dvf_median.c144 s->nb_threads = FFMAX(1, FFMIN(s->planeheight[1] / (s->radiusV + 1), ff_filter_get_nb_threads(inlink->dst))); in config_input()
148 s->coarse = av_calloc(s->nb_threads, sizeof(*s->coarse)); in config_input()
149 s->fine = av_calloc(s->nb_threads, sizeof(*s->fine)); in config_input()
152 for (int i = 0; i < s->nb_threads; i++) { in config_input()
228 ff_filter_execute(ctx, filter_slice, &td, NULL, s->nb_threads); in filter_frame()
238 for (int i = 0; i < s->nb_threads && s->coarse && s->fine; i++) { in uninit()
H A Dvf_fftfilt.c51 int nb_threads; member
319 s->nb_threads = FFMIN(32, ff_filter_get_nb_threads(inlink->dst)); in config_props()
335 for (int j = 0; j < s->nb_threads; j++) { in config_props()
356 for (int j = 0; j < s->nb_threads; j++) { in config_props()
511 FFMIN(s->planeheight[1], s->nb_threads)); in filter_frame()
514 FFMIN(s->planeheight[1], s->nb_threads)); in filter_frame()
517 FFMIN(s->planeheight[1], s->nb_threads)); in filter_frame()
525 FFMIN(s->planeheight[1], s->nb_threads)); in filter_frame()
531 FFMIN(s->planeheight[1], s->nb_threads)); in filter_frame()
534 FFMIN(s->planeheight[1], s->nb_threads)); in filter_frame()
[all...]
H A Dvf_w3fdif.c47 int nb_threads; member
278 int ret, i, depth, nb_threads; in config_input() local
292 nb_threads = ff_filter_get_nb_threads(ctx); in config_input()
293 s->work_line = av_calloc(nb_threads, sizeof(*s->work_line)); in config_input()
296 s->nb_threads = nb_threads; in config_input()
298 for (i = 0; i < s->nb_threads; i++) { in config_input()
508 FFMIN(s->planeheight[1], s->nb_threads)); in filter()
588 for (i = 0; i < s->nb_threads; i++) in uninit()
H A Dvf_identity.c50 int nb_threads; member
202 FFMIN(s->planeheight[1], s->nb_threads)); in do_identity()
204 for (int j = 0; j < s->nb_threads; j++) { in do_identity()
267 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input_ref()
286 s->scores = av_calloc(s->nb_threads, sizeof(*s->scores)); in config_input_ref()
290 for (int t = 0; t < s->nb_threads; t++) { in config_input_ref()
372 for (int t = 0; t < s->nb_threads && s->scores; t++) in uninit()
H A Dvf_blackdetect.c50 int nb_threads; member
109 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input()
112 s->counter = av_calloc(s->nb_threads, sizeof(*s->counter)); in config_input()
187 FFMIN(inlink->h, s->nb_threads)); in filter_frame()
189 for (int i = 0; i < s->nb_threads; i++) in filter_frame()
H A Dvf_ssim.c54 int nb_threads; member
363 FFMIN((s->planeheight[1] + 3) >> 2, s->nb_threads)); in do_ssim()
366 for (int j = 0; j < s->nb_threads; j++) in do_ssim()
443 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input_ref()
467 s->temp = av_calloc(s->nb_threads, sizeof(*s->temp)); in config_input_ref()
471 for (int t = 0; t < s->nb_threads; t++) { in config_input_ref()
485 s->score = av_calloc(s->nb_threads, sizeof(*s->score)); in config_input_ref()
489 for (int t = 0; t < s->nb_threads; t++) { in config_input_ref()
556 for (int t = 0; t < s->nb_threads && s->score; t++) in uninit()
560 for (int t = 0; t < s->nb_threads in uninit()
[all...]
H A Dvf_guided.c213 const int nb_threads = ff_filter_get_nb_threads(ctx); \
243 ff_filter_execute(ctx, s->box_slice, &t, NULL, FFMIN(h, nb_threads)); \
246 ff_filter_execute(ctx, s->box_slice, &t, NULL, FFMIN(h, nb_threads)); \
249 ff_filter_execute(ctx, s->box_slice, &t, NULL, FFMIN(h, nb_threads)); \
252 ff_filter_execute(ctx, s->box_slice, &t, NULL, FFMIN(h, nb_threads)); \
266 ff_filter_execute(ctx, s->box_slice, &t, NULL, FFMIN(h, nb_threads)); \
269 ff_filter_execute(ctx, s->box_slice, &t, NULL, FFMIN(h, nb_threads)); \
H A Dvf_psnr.c54 int nb_threads; member
193 FFMIN(s->planeheight[1], s->nb_threads)); in do_psnr()
195 for (int j = 0; j < s->nb_threads; j++) { in do_psnr()
323 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input_ref()
361 s->score = av_calloc(s->nb_threads, sizeof(*s->score)); in config_input_ref()
365 for (int t = 0; t < s->nb_threads; t++) { in config_input_ref()
431 for (int t = 0; t < s->nb_threads && s->score; t++) in uninit()
H A Dvf_nnedi.c76 int nb_threads; member
672 FFMIN(s->planeheight[1] / 2, s->nb_threads)); in get_frame()
1029 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input()
1070 s->input_buf = av_calloc(s->nb_threads, sizeof(*s->input_buf)); in config_input()
1074 for (int i = 0; i < s->nb_threads; i++) { in config_input()
1080 s->output_buf = av_calloc(s->nb_threads, sizeof(*s->output_buf)); in config_input()
1084 for (int i = 0; i < s->nb_threads; i++) { in config_input()
1090 s->prescreen_buf = av_calloc(s->nb_threads, sizeof(*s->prescreen_buf)); in config_input()
1094 for (int i = 0; i < s->nb_threads; i++) { in config_input()
1107 for (int i = 0; i < s->nb_threads in uninit()
[all...]
H A Dvf_xmedian.c41 int nb_threads; member
229 FFMIN(s->height[1], s->nb_threads)); in process_frame()
260 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_output()
275 s->data = av_calloc(s->nb_threads * s->nb_inputs, sizeof(*s->data)); in config_output()
279 s->linesize = av_calloc(s->nb_threads * s->nb_inputs, sizeof(*s->linesize)); in config_output()
433 FFMIN(s->height[1], s->nb_threads)); in tmedian_filter_frame()
H A Dvf_mix.c40 int nb_threads; member
246 FFMIN(s->height[1], s->nb_threads)); in process_frame()
272 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_output()
286 s->data = av_calloc(s->nb_threads * s->nb_inputs, sizeof(*s->data)); in config_output()
290 s->linesize = av_calloc(s->nb_threads * s->nb_inputs, sizeof(*s->linesize)); in config_output()
445 FFMIN(s->height[1], s->nb_threads)); in tmix_filter_frame()
H A Dvif.h30 float *data_buf[13], float **temp, int nb_threads);
H A Dvf_bilateral.c39 int nb_threads; member
125 s->nb_threads = ff_filter_get_nb_threads(ctx); in config_input()
452 ff_filter_execute(ctx, bilateralh_planes, &td, NULL, s->nb_threads); in filter_frame()
453 ff_filter_execute(ctx, bilateralv_planes, &td, NULL, s->nb_threads); in filter_frame()
454 ff_filter_execute(ctx, bilateralo_planes, &td, NULL, s->nb_threads); in filter_frame()
H A Dvf_yaepblur.c222 const int nb_threads = ff_filter_get_nb_threads(ctx); in filter_frame() local
252 FFMIN(td.height, nb_threads)); in filter_frame()
254 FFMIN(td.width, nb_threads)); in filter_frame()
259 FFMIN(td.height, nb_threads)); in filter_frame()
H A Dvf_gblur.c125 const int nb_threads = ff_filter_get_nb_threads(ctx); in gaussianiir2d() local
134 NULL, FFMIN(height, nb_threads)); in gaussianiir2d()
136 NULL, FFMIN(width, nb_threads)); in gaussianiir2d()
138 NULL, FFMIN(width * height, nb_threads)); in gaussianiir2d()
H A 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()
744 ff_filter_execute(ctx, filter_slice, &td, NULL, s->nb_threads); in filter_frame()
797 for (i = 0; i < s->nb_threads; i++) { in uninit()
H A Dconvolution.h48 int nb_threads; member
H A Dmedian.h40 int nb_threads; member
/third_party/ffmpeg/tools/
H A Dvenc_data_dump.c74 const char *filename, *thread_type = NULL, *nb_threads = NULL; in main() local
86 nb_threads = argv[4]; in main()
97 ret = av_dict_set(&dc.decoder_opts, "threads", nb_threads, 0); in main()

Completed in 20 milliseconds

12