Home
last modified time | relevance | path

Searched refs:nb_channels (Results 1 – 25 of 59) sorted by relevance

123

/third_party/ffmpeg/libavutil/
Dsamplefmt.c119 int av_samples_get_buffer_size(int *linesize, int nb_channels, int nb_samples, in av_samples_get_buffer_size() argument
127 if (!sample_size || nb_samples <= 0 || nb_channels <= 0) in av_samples_get_buffer_size()
139 if (nb_channels > INT_MAX / align || in av_samples_get_buffer_size()
140 (int64_t)nb_channels * nb_samples > (INT_MAX - (align * nb_channels)) / sample_size) in av_samples_get_buffer_size()
144 FFALIGN(nb_samples * sample_size * nb_channels, align); in av_samples_get_buffer_size()
148 return planar ? line_size * nb_channels : line_size; in av_samples_get_buffer_size()
152 const uint8_t *buf, int nb_channels, int nb_samples, in av_samples_fill_arrays() argument
158 buf_size = av_samples_get_buffer_size(&line_size, nb_channels, nb_samples, in av_samples_fill_arrays()
164 for (ch = 1; planar && ch < nb_channels; ch++) in av_samples_fill_arrays()
173 int av_samples_alloc(uint8_t **audio_data, int *linesize, int nb_channels, in av_samples_alloc() argument
[all …]
Dchannel_layout.c76 int nb_channels; member
155 int av_get_extended_channel_layout(const char *name, uint64_t* channel_layout, int* nb_channels) in av_get_extended_channel_layout() argument
163 *nb_channels = av_get_channel_layout_nb_channels(layout); in av_get_extended_channel_layout()
170 *nb_channels = nb; in av_get_extended_channel_layout()
178 int nb_channels, uint64_t channel_layout) in av_bprint_channel_layout() argument
182 if (nb_channels <= 0) in av_bprint_channel_layout()
183 nb_channels = av_get_channel_layout_nb_channels(channel_layout); in av_bprint_channel_layout()
186 if (nb_channels == channel_layout_map[i].nb_channels && in av_bprint_channel_layout()
192 av_bprintf(bp, "%d channels", nb_channels); in av_bprint_channel_layout()
212 int nb_channels, uint64_t channel_layout) in av_get_channel_layout_string() argument
[all …]
Dsamplefmt.h160 int av_samples_get_buffer_size(int *linesize, int nb_channels, int nb_samples,
204 int nb_channels, int nb_samples,
226 int av_samples_alloc(uint8_t **audio_data, int *linesize, int nb_channels,
238 int av_samples_alloc_array_and_samples(uint8_t ***audio_data, int *linesize, int nb_channels,
253 int src_offset, int nb_samples, int nb_channels,
266 int nb_channels, enum AVSampleFormat sample_fmt);
Dchannel_layout.h156 int av_get_extended_channel_layout(const char *name, uint64_t* channel_layout, int* nb_channels);
165 void av_get_channel_layout_string(char *buf, int buf_size, int nb_channels, uint64_t channel_layout…
171 void av_bprint_channel_layout(struct AVBPrint *bp, int nb_channels, uint64_t channel_layout);
181 int64_t av_get_default_channel_layout(int nb_channels);
/third_party/ffmpeg/tests/
Daudiogen.c144 int nb_channels = 2; in main() local
164 nb_channels = atoi(argv[3]); in main()
165 if (nb_channels < 1 || nb_channels > MAX_CHANNELS) { in main()
166 fprintf(stderr, "invalid number of channels: %d\n", nb_channels); in main()
181 put_wav_header(sample_rate, nb_channels, 6 * sample_rate); in main()
187 for (j = 0; j < nb_channels; j++) in main()
196 for (j = 0; j < nb_channels; j++) in main()
205 for (j = 0; j < nb_channels; j++) in main()
212 for (j = 0; j < nb_channels; j++) in main()
217 for (j = 0; j < nb_channels; j++) { in main()
[all …]
/third_party/gstreamer/gst_libav/ext/libav/
Dgstavutils.c98 uint8_t nb_channels; /* number of channels (including alpha) */ member
115 pix_fmt_info[AV_PIX_FMT_YUV420P].nb_channels = 3; in gst_ffmpeg_init_pix_fmt_info()
123 pix_fmt_info[AV_PIX_FMT_YUV422P].nb_channels = 3; in gst_ffmpeg_init_pix_fmt_info()
131 pix_fmt_info[AV_PIX_FMT_YUV444P].nb_channels = 3; in gst_ffmpeg_init_pix_fmt_info()
139 pix_fmt_info[AV_PIX_FMT_YUYV422].nb_channels = 1; in gst_ffmpeg_init_pix_fmt_info()
147 pix_fmt_info[AV_PIX_FMT_YUV410P].nb_channels = 3; in gst_ffmpeg_init_pix_fmt_info()
155 pix_fmt_info[AV_PIX_FMT_YUV411P].nb_channels = 3; in gst_ffmpeg_init_pix_fmt_info()
164 pix_fmt_info[AV_PIX_FMT_YUVJ420P].nb_channels = 3; in gst_ffmpeg_init_pix_fmt_info()
172 pix_fmt_info[AV_PIX_FMT_YUVJ422P].nb_channels = 3; in gst_ffmpeg_init_pix_fmt_info()
180 pix_fmt_info[AV_PIX_FMT_YUVJ444P].nb_channels = 3; in gst_ffmpeg_init_pix_fmt_info()
[all …]
/third_party/ffmpeg/libavfilter/
Daeval.c62 int nb_channels; ///< number of output channels member
127 if (!av_dynarray2_add((void **)&eval->expr, &eval->nb_channels, \ in parse_channel_expressions()
132 eval->expr[eval->nb_channels-1] = NULL; \ in parse_channel_expressions()
133 ret = av_expr_parse(&eval->expr[eval->nb_channels - 1], expr_, \ in parse_channel_expressions()
141 for (i = 0; i < eval->nb_channels; i++) { in parse_channel_expressions()
146 eval->nb_channels = 0; in parse_channel_expressions()
154 if (expected_nb_channels > eval->nb_channels) in parse_channel_expressions()
155 for (i = eval->nb_channels; i < expected_nb_channels; i++) in parse_channel_expressions()
158 if (expected_nb_channels > 0 && eval->nb_channels != expected_nb_channels) { in parse_channel_expressions()
162 eval->nb_channels, expected_nb_channels); in parse_channel_expressions()
[all …]
Daf_drmeter.c41 int nb_channels; member
93 s->nb_channels = outlink->channels; in config_output()
131 const int channels = s->nb_channels; in filter_frame()
165 for (ch = 0; ch < s->nb_channels; ch++) { in print_stats()
194 av_log(ctx, AV_LOG_INFO, "Overall DR: %.1f\n", dr / s->nb_channels); in print_stats()
201 if (s->nb_channels) in uninit()
Daf_join.c54 int nb_channels; member
173 s->nb_channels = av_get_channel_layout_nb_channels(s->channel_layout); in join_init()
174 s->channels = av_mallocz_array(s->nb_channels, sizeof(*s->channels)); in join_init()
175 s->buffers = av_mallocz_array(s->nb_channels, sizeof(*s->buffers)); in join_init()
180 for (i = 0; i < s->nb_channels; i++) { in join_init()
293 for (i = 0; i < s->nb_channels; i++) { in join_config_output()
319 for (i = 0; i < s->nb_channels; i++) { in join_config_output()
327 for (i = 0; i < s->nb_channels; i++) { in join_config_output()
346 for (i = 0; i < s->nb_channels; i++) { in join_config_output()
387 if (s->nb_channels > FF_ARRAY_ELEMS(frame->data)) { in try_push_frame()
[all …]
Daf_astats.c94 int nb_channels; member
186 for (c = 0; c < s->nb_channels; c++) { in reset_stats()
230 s->nb_channels = outlink->channels; in config_output()
232 for (int i = 0; i < s->nb_channels; i++) { in config_output()
427 for (c = 0; c < s->nb_channels; c++) { in set_metadata()
512 … set_meta(metadata, 0, "Overall.DC_offset", "%f", max_sigma_x / (nb_samples / s->nb_channels)); in set_metadata()
522 … set_meta(metadata, 0, "Overall.Mean_difference", "%f", diff1_sum / (nb_samples - s->nb_channels)); in set_metadata()
524 …a(metadata, 0, "Overall.RMS_difference", "%f", sqrt(diff1_sum_x2 / (nb_samples - s->nb_channels))); in set_metadata()
536 …(metadata, 0, "Overall.Peak_count", "%f", (float)(min_count + max_count) / (double)s->nb_channels); in set_metadata()
540 …t_meta(metadata, 0, "Overall.Noise_floor_count", "%f", noise_floor_count / (double)s->nb_channels); in set_metadata()
[all …]
Df_ebur128.c122 int nb_channels; ///< number of channels in the input member
409 const int nb_channels = av_get_channel_layout_nb_channels(outlink->channel_layout); in config_audio_output() local
416 ebur128->nb_channels = nb_channels; in config_audio_output()
417 ebur128->ch_weighting = av_calloc(nb_channels, sizeof(*ebur128->ch_weighting)); in config_audio_output()
421 for (i = 0; i < nb_channels; i++) { in config_audio_output()
446 ebur128->swr_buf = av_malloc_array(nb_channels, 19200 * sizeof(double)); in config_audio_output()
447 ebur128->true_peaks = av_calloc(nb_channels, sizeof(*ebur128->true_peaks)); in config_audio_output()
448 … ebur128->true_peaks_per_frame = av_calloc(nb_channels, sizeof(*ebur128->true_peaks_per_frame)); in config_audio_output()
469 ebur128->sample_peaks = av_calloc(nb_channels, sizeof(*ebur128->sample_peaks)); in config_audio_output()
593 const int nb_channels = ebur128->nb_channels; in filter_frame() local
[all …]
Davf_showfreqs.c61 int nb_channels; member
186 for (i = 0; i < s->nb_channels; i++) { in config_output()
192 s->nb_channels = inlink->channels; in config_output()
194 s->fft_data = av_calloc(s->nb_channels, sizeof(*s->fft_data)); in config_output()
197 s->avg_data = av_calloc(s->nb_channels, sizeof(*s->avg_data)); in config_output()
200 for (i = 0; i < s->nb_channels; i++) { in config_output()
309 end = (outlink->h / s->nb_channels) * (ch + 1); in plot_freq()
310 y = (outlink->h / s->nb_channels) * ch + a * (outlink->h / s->nb_channels) - 1; in plot_freq()
378 for (ch = 0; ch < s->nb_channels; ch++) { in plot_freqs()
392 for (ch = 0; ch < s->nb_channels; ch++) { in plot_freqs()
[all …]
Dfifo.c107 int nb_channels = link->channels; in buffer_offset() local
109 int planes = planar ? nb_channels : 1; in buffer_offset()
110 int block_align = av_get_bytes_per_sample(link->format) * (planar ? 1 : nb_channels); in buffer_offset()
173 int nb_channels = link->channels; in return_audio_frame() local
199 nb_channels, link->format); in return_audio_frame()
213 s->out->nb_samples, 0, len, nb_channels, in return_audio_frame()
Daf_channelsplit.c61 int nb_channels; in init() local
73 nb_channels = av_get_channel_layout_nb_channels(s->channel_layout); in init()
77 … if ((ret = av_get_extended_channel_layout(s->channels_str, &channel_layout, &nb_channels)) < 0) in init()
81 for (i = 0; i < nb_channels; i++) { in init()
Davf_showwaves.c411 int nb_channels = inlink->channels; in config_output() local
423 if (!(showwaves->buf_idy = av_mallocz_array(nb_channels, sizeof(*showwaves->buf_idy)))) { in config_output()
505 showwaves->fg = av_malloc_array(nb_channels, 4 * sizeof(*showwaves->fg)); in config_output()
515 x = 255 / ((showwaves->split_channels ? 1 : nb_channels) * showwaves->n); in config_output()
522 for (ch = 0; ch < nb_channels; ch++) { in config_output()
534 for (ch = 0; ch < nb_channels; ch++) in config_output()
547 int nb_channels = inlink->channels; in push_frame() local
553 for (i = 0; i < nb_channels; i++) in push_frame()
568 const int nb_channels = inlink->channels; in push_single_pic() local
569 const int ch_height = showwaves->split_channels ? outlink->h / nb_channels : outlink->h; in push_single_pic()
[all …]
/third_party/ffmpeg/libavcodec/
Dqdmc.c54 int nb_channels; member
295 avctx->channels = s->nb_channels = bytestream2_get_be32u(&b); in qdmc_decode_init()
296 if (s->nb_channels <= 0 || s->nb_channels > 2) { in qdmc_decode_init()
410 for (ch = 0; ch < s->nb_channels; ch++) { in read_noise_data()
499 if (s->nb_channels > 1) in read_wave_data()
598 if (s->nb_channels == 1) in add_wave()
630 if (s->nb_channels == 1) in add_wave0()
675 s->buffer_ptr = &s->buffer[s->nb_channels * s->buffer_offset]; in decode_frame()
688 for (ch = 0; ch < s->nb_channels; ch++) in decode_frame()
693 for (ch = 0; ch < s->nb_channels; ch++) { in decode_frame()
[all …]
Dmpegaudioenc_template.c49 int nb_channels; member
90 s->nb_channels = channels; in MPA_encode_init()
136 table = ff_mpa_l2_select_table(bitrate, s->nb_channels, freq, s->lsf); in MPA_encode_init()
145 for(i=0;i<s->nb_channels;i++) in MPA_encode_init()
520 memcpy(smr, smr1, s->nb_channels * sizeof(short) * SBLIMIT); in compute_bit_allocation()
521 memset(subband_status, SB_NOTALLOCATED, s->nb_channels * SBLIMIT); in compute_bit_allocation()
522 memset(bit_alloc, 0, s->nb_channels * SBLIMIT); in compute_bit_allocation()
540 current_frame_size += incr * s->nb_channels; in compute_bit_allocation()
548 for(ch=0;ch<s->nb_channels;ch++) { in compute_bit_allocation()
624 put_bits(p, 2, s->nb_channels == 2 ? MPA_STEREO : MPA_MONO); in encode_frame()
[all …]
Dmpegaudiodecheader.c75 s->nb_channels = 1; in avpriv_mpegaudio_decode_header()
77 s->nb_channels = 2; in avpriv_mpegaudio_decode_header()
106 if (s->nb_channels == 2) { in avpriv_mpegaudio_decode_header()
151 *channels = s->nb_channels; in ff_mpa_decode_header()
Dwmaprodec.c226 int8_t nb_channels; ///< number of channels in stream (XMA1/2) member
266 PRINT("num channels", s->nb_channels); in dump_context()
348 s->nb_channels = 1; in decode_init()
350 s->nb_channels = 2; in decode_init()
355 …s->nb_channels = edata_ptr[32 + ((edata_ptr[0]==3)?0:8) + 4*num_stream + 0]; /* nth stream config … in decode_init()
360 s->nb_channels = edata_ptr[8 + 20*num_stream + 17]; /* nth stream config */ in decode_init()
365 s->nb_channels = avctx->channels; in decode_init()
432 if (s->nb_channels <= 0) { in decode_init()
434 s->nb_channels); in decode_init()
436 } else if (avctx->codec_id != AV_CODEC_ID_WMAPRO && s->nb_channels > XMA_MAX_CHANNELS_STREAM) { in decode_init()
[all …]
Dqdm2.c130 int nb_channels; ///< number of channels member
320 for (ch = 0; ch < q->nb_channels; ch++) in average_quantized_coeffs()
349 if (!q->nb_channels) in build_sb_samples_from_noise()
352 for (ch = 0; ch < q->nb_channels; ch++) { in build_sb_samples_from_noise()
446 for (ch = 0; ch < q->nb_channels; ch++) in fill_tone_level_array()
463 for (ch = 0; ch < q->nb_channels; ch++) in fill_tone_level_array()
475 for (ch = 0; ch < q->nb_channels; ch++) in fill_tone_level_array()
489 for (ch = 0; ch < q->nb_channels; ch++) in fill_tone_level_array()
501 for (ch = 0; ch < q->nb_channels; ch++) in fill_tone_level_array()
533 int nb_channels, in fill_coding_method_array() argument
[all …]
Dmpegaudio.c31 int ff_mpa_l2_select_table(int bitrate, int nb_channels, int freq, int lsf) in ff_mpa_l2_select_table() argument
35 ch_bitrate = bitrate / nb_channels; in ff_mpa_l2_select_table()
Dmpegaudiodec_template.c517 for (ch = 0; ch < s->nb_channels; ch++) { in mp_decode_layer1()
526 for (ch = 0; ch < s->nb_channels; ch++) { in mp_decode_layer1()
541 for (ch = 0; ch < s->nb_channels; ch++) { in mp_decode_layer1()
580 table = ff_mpa_l2_select_table(s->bit_rate / 1000, s->nb_channels, in mp_decode_layer2()
600 for (ch = 0; ch < s->nb_channels; ch++) in mp_decode_layer2()
614 for (ch = 0; ch < s->nb_channels; ch++) { in mp_decode_layer2()
622 for (ch = 0; ch < s->nb_channels; ch++) { in mp_decode_layer2()
658 for (ch = 0; ch < s->nb_channels; ch++) { in mp_decode_layer2()
745 for (ch = 0; ch < s->nb_channels; ch++) { in mp_decode_layer2()
1317 skip_bits(&s->gb, s->nb_channels); in mp_decode_layer3()
[all …]
/third_party/gstreamer/gstplugins_good/gst/rtp/
Dgstrtpceltdepay.c121 gint clock_rate, nb_channels = 0, frame_size = 0; in gst_rtp_celt_depay_setcaps() local
138 nb_channels = atoi (params); in gst_rtp_celt_depay_setcaps()
139 if (!nb_channels) in gst_rtp_celt_depay_setcaps()
140 nb_channels = DEFAULT_CHANNELS; in gst_rtp_celt_depay_setcaps()
149 clock_rate, nb_channels, frame_size); in gst_rtp_celt_depay_setcaps()
165 GST_WRITE_UINT32_LE (ptr, nb_channels); /* channels */ in gst_rtp_celt_depay_setcaps()
Dgstrtpspeexdepay.c120 gint clock_rate, nb_channels; in gst_rtp_speex_depay_setcaps() local
137 nb_channels = 1; in gst_rtp_speex_depay_setcaps()
139 nb_channels = atoi (params); in gst_rtp_speex_depay_setcaps()
160 GST_WRITE_UINT32_LE (data, nb_channels); /* nb_channels */ in gst_rtp_speex_depay_setcaps()
/third_party/ffmpeg/libavformat/
Doggparsecelt.c46 uint32_t version, sample_rate, nb_channels; in celt_header() local
60 nb_channels = AV_RL32(p + 40); in celt_header()
67 st->codecpar->channels = nb_channels; in celt_header()

123