/third_party/ffmpeg/libavutil/ |
D | audio_fifo.c | 37 int nb_samples; /**< number of samples currently in the FIFO */ member 60 int nb_samples) in av_audio_fifo_alloc() argument 66 if (av_samples_get_buffer_size(&buf_size, channels, nb_samples, sample_fmt, 1) < 0) in av_audio_fifo_alloc() 75 af->sample_size = buf_size / nb_samples; in av_audio_fifo_alloc() 87 af->allocated_samples = nb_samples; in av_audio_fifo_alloc() 96 int av_audio_fifo_realloc(AVAudioFifo *af, int nb_samples) in av_audio_fifo_realloc() argument 100 if ((ret = av_samples_get_buffer_size(&buf_size, af->channels, nb_samples, in av_audio_fifo_realloc() 108 af->allocated_samples = nb_samples; in av_audio_fifo_realloc() 112 int av_audio_fifo_write(AVAudioFifo *af, void **data, int nb_samples) in av_audio_fifo_write() argument 117 if (av_audio_fifo_space(af) < nb_samples) { in av_audio_fifo_write() [all …]
|
D | samplefmt.c | 119 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() 132 if (nb_samples > INT_MAX - 31) in av_samples_get_buffer_size() 135 nb_samples = FFALIGN(nb_samples, 32); 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() 143 line_size = planar ? FFALIGN(nb_samples * sample_size, align) : in av_samples_get_buffer_size() 144 FFALIGN(nb_samples * sample_size * nb_channels, align); 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() 174 int nb_samples, enum AVSampleFormat sample_fmt, int align) in av_samples_alloc() argument [all …]
|
D | audio_fifo.h | 67 int nb_samples); 77 int av_audio_fifo_realloc(AVAudioFifo *af, int nb_samples); 95 int av_audio_fifo_write(AVAudioFifo *af, void **data, int nb_samples); 111 int av_audio_fifo_peek(AVAudioFifo *af, void **data, int nb_samples); 128 int av_audio_fifo_peek_at(AVAudioFifo *af, void **data, int nb_samples, int offset); 144 int av_audio_fifo_read(AVAudioFifo *af, void **data, int nb_samples); 155 int av_audio_fifo_drain(AVAudioFifo *af, int nb_samples);
|
/third_party/ffmpeg/libavresample/ |
D | audio_data.c | 74 int channels, int nb_samples, in ff_audio_data_init() argument 104 a->allocated_samples = nb_samples * !read_only; in ff_audio_data_init() 105 a->nb_samples = nb_samples; in ff_audio_data_init() 119 AudioData *ff_audio_data_alloc(int channels, int nb_samples, in ff_audio_data_alloc() argument 149 if (nb_samples > 0) { in ff_audio_data_alloc() 150 ret = ff_audio_data_realloc(a, nb_samples); in ff_audio_data_alloc() 162 int ff_audio_data_realloc(AudioData *a, int nb_samples) in ff_audio_data_realloc() argument 167 if (a->allocated_samples >= nb_samples) in ff_audio_data_realloc() 175 a->allocated_channels, nb_samples, in ff_audio_data_realloc() 183 if (a->nb_samples > 0 && a->is_planar) { in ff_audio_data_realloc() [all …]
|
D | audio_data.h | 43 int nb_samples; /**< current number of samples */ member 80 int channels, int nb_samples, 95 AudioData *ff_audio_data_alloc(int channels, int nb_samples, 108 int ff_audio_data_realloc(AudioData *a, int nb_samples); 142 int src_offset, int nb_samples); 152 void ff_audio_data_drain(AudioData *a, int nb_samples); 165 int nb_samples); 176 int ff_audio_data_read_from_fifo(AVAudioFifo *af, AudioData *a, int nb_samples);
|
/third_party/ffmpeg/libavfilter/ |
D | af_afade.c | 36 int64_t nb_samples; member 46 int nb_samples, int channels, int direction, 50 int nb_samples, int channels, 173 int nb_samples, int channels, int dir, \ 178 for (i = 0; i < nb_samples; i++) { \ 191 int nb_samples, int channels, int dir, \ 198 for (i = 0; i < nb_samples; i++) { \ 232 s->nb_samples = av_rescale(s->duration, outlink->sample_rate, AV_TIME_BASE); in FADE_PLANAR() 250 …{ "nb_samples", "set number of samples for fade duration", OFFSET(nb_samples), AV_OPT_TYPE… 251 …{ "ns", "set number of samples for fade duration", OFFSET(nb_samples), AV_OPT_TYPE… [all …]
|
D | af_asoftclip.c | 58 int nb_samples, int channels, int start, int end); 117 int nb_samples, int channels, in filter_flt() argument 131 for (int n = 0; n < nb_samples; n++) { in filter_flt() 137 for (int n = 0; n < nb_samples; n++) { in filter_flt() 143 for (int n = 0; n < nb_samples; n++) { in filter_flt() 149 for (int n = 0; n < nb_samples; n++) { in filter_flt() 160 for (int n = 0; n < nb_samples; n++) { in filter_flt() 166 for (int n = 0; n < nb_samples; n++) { in filter_flt() 174 for (int n = 0; n < nb_samples; n++) { in filter_flt() 185 for (int n = 0; n < nb_samples; n++) { in filter_flt() [all …]
|
D | f_loop.c | 44 int64_t nb_samples; member 92 static int push_samples(AVFilterContext *ctx, int nb_samples) in push_samples() argument 99 while (s->loop != 0 && i < nb_samples) { in push_samples() 100 out = ff_get_audio_buffer(outlink, FFMIN(nb_samples, s->nb_samples - s->current_sample)); in push_samples() 103 …ret = av_audio_fifo_peek_at(s->fifo, (void **)out->extended_data, out->nb_samples, s->current_samp… in push_samples() 109 out->nb_samples = ret; in push_samples() 110 …s->pts += av_rescale_q(out->nb_samples, (AVRational){1, outlink->sample_rate}, outlink->time_base); in push_samples() 111 i += out->nb_samples; in push_samples() 112 s->current_sample += out->nb_samples; in push_samples() 118 if (s->current_sample >= s->nb_samples) { in push_samples() [all …]
|
D | audio.c | 33 AVFrame *ff_null_get_audio_buffer(AVFilterLink *link, int nb_samples) in ff_null_get_audio_buffer() argument 35 return ff_get_audio_buffer(link->dst->outputs[0], nb_samples); in ff_null_get_audio_buffer() 38 AVFrame *ff_default_get_audio_buffer(AVFilterLink *link, int nb_samples) in ff_default_get_audio_buffer() argument 47 nb_samples, link->format, BUFFER_ALIGN); in ff_default_get_audio_buffer() 62 if (pool_channels != channels || pool_nb_samples < nb_samples || in ff_default_get_audio_buffer() 67 nb_samples, link->format, BUFFER_ALIGN); in ff_default_get_audio_buffer() 77 frame->nb_samples = nb_samples; in ff_default_get_audio_buffer() 81 av_samples_set_silence(frame->extended_data, 0, nb_samples, channels, link->format); in ff_default_get_audio_buffer() 86 AVFrame *ff_get_audio_buffer(AVFilterLink *link, int nb_samples) in ff_get_audio_buffer() argument 91 ret = link->dstpad->get_audio_buffer(link, nb_samples); in ff_get_audio_buffer() [all …]
|
D | af_amix.c | 58 int nb_samples; member 73 int nb_samples; member 87 frame_list->nb_samples = 0; in frame_list_clear() 96 return frame_list->list->nb_samples; in frame_list_next_frame_size() 106 static void frame_list_remove_samples(FrameList *frame_list, int nb_samples) in frame_list_remove_samples() argument 108 if (nb_samples >= frame_list->nb_samples) { in frame_list_remove_samples() 111 int samples = nb_samples; in frame_list_remove_samples() 115 if (info->nb_samples <= samples) { in frame_list_remove_samples() 116 samples -= info->nb_samples; in frame_list_remove_samples() 121 frame_list->nb_samples -= info->nb_samples; in frame_list_remove_samples() [all …]
|
D | af_adenorm.c | 43 const void *src, int nb_samples); 76 const void *srcp, int nb_samples) in dc_denorm_fltp() argument 83 for (int n = 0; n < nb_samples; n++) { in dc_denorm_fltp() 89 const void *srcp, int nb_samples) in dc_denorm_dblp() argument 96 for (int n = 0; n < nb_samples; n++) { in dc_denorm_dblp() 102 const void *srcp, int nb_samples) in ac_denorm_fltp() argument 110 for (int n = 0; n < nb_samples; n++) { in ac_denorm_fltp() 116 const void *srcp, int nb_samples) in ac_denorm_dblp() argument 124 for (int n = 0; n < nb_samples; n++) { in ac_denorm_dblp() 130 const void *srcp, int nb_samples) in sq_denorm_fltp() argument [all …]
|
D | af_rubberband.c | 41 int nb_samples; member 128 int ret = 0, nb_samples; in filter_frame() local 133 …rubberband_process(s->rbs, (const float *const *)in->data, in->nb_samples, ff_outlink_get_status(i… in filter_frame() 134 s->nb_samples_in += in->nb_samples; in filter_frame() 136 nb_samples = rubberband_available(s->rbs); in filter_frame() 137 if (nb_samples > 0) { in filter_frame() 138 out = ff_get_audio_buffer(outlink, nb_samples); in filter_frame() 146 nb_samples = rubberband_retrieve(s->rbs, (float *const *)out->data, nb_samples); in filter_frame() 147 out->nb_samples = nb_samples; in filter_frame() 149 s->nb_samples_out += nb_samples; in filter_frame() [all …]
|
D | af_crystalizer.c | 80 int nb_samples; member 92 const int nb_samples = td->nb_samples; in filter_flt() local 105 for (n = 0; n < nb_samples; n++) { in filter_flt() 127 const int nb_samples = td->nb_samples; in filter_dbl() local 140 for (n = 0; n < nb_samples; n++) { in filter_dbl() 163 const int nb_samples = td->nb_samples; in filter_fltp() local 176 for (n = 0; n < nb_samples; n++) { in filter_fltp() 196 const int nb_samples = td->nb_samples; in filter_dblp() local 209 for (n = 0; n < nb_samples; n++) { in filter_dblp() 229 const int nb_samples = td->nb_samples; in ifilter_flt() local [all …]
|
D | trim.c | 58 int64_t nb_samples; member 241 s->next_pts = pts + frame->nb_samples; in atrim_filter_frame() 248 start_sample = frame->nb_samples; in atrim_filter_frame() 251 s->nb_samples + frame->nb_samples > s->start_sample) { in atrim_filter_frame() 253 start_sample = FFMIN(start_sample, s->start_sample - s->nb_samples); in atrim_filter_frame() 257 pts + frame->nb_samples > s->start_pts) { in atrim_filter_frame() 271 end_sample = frame->nb_samples; in atrim_filter_frame() 277 s->nb_samples < s->end_sample) { in atrim_filter_frame() 279 end_sample = FFMAX(end_sample, s->end_sample - s->nb_samples); in atrim_filter_frame() 300 s->nb_samples += frame->nb_samples; in atrim_filter_frame() [all …]
|
D | af_volumedetect.c | 64 int nb_samples = samples->nb_samples; in filter_frame() local 71 nb_samples *= nb_channels; in filter_frame() 76 for (i = 0; i < nb_samples; i++) in filter_frame() 97 uint64_t nb_samples = 0, power = 0, nb_samples_shift = 0, sum = 0; in print_stats() local 101 nb_samples += vd->histogram[i]; in print_stats() 102 av_log(ctx, AV_LOG_INFO, "n_samples: %"PRId64"\n", nb_samples); in print_stats() 103 if (!nb_samples) in print_stats() 110 shift = av_log2(nb_samples >> 33); in print_stats() 130 for (; i <= MAX_DB && sum < nb_samples / 1000; i++) { in print_stats()
|
D | af_amerge.c | 227 static int try_push_frame(AVFilterContext *ctx, int nb_samples) in try_push_frame() argument 236 ret = ff_inlink_consume_samples(ctx->inputs[i], nb_samples, nb_samples, &inbuf[i]); in try_push_frame() 244 outbuf = ff_get_audio_buffer(ctx->outputs[0], nb_samples); in try_push_frame() 253 outbuf->nb_samples = nb_samples; in try_push_frame() 257 while (nb_samples) { in try_push_frame() 262 copy_samples(s->nb_inputs, s->in, s->route, ins, &outs, nb_samples, 1); in try_push_frame() 265 copy_samples(s->nb_inputs, s->in, s->route, ins, &outs, nb_samples, 2); in try_push_frame() 268 copy_samples(s->nb_inputs, s->in, s->route, ins, &outs, nb_samples, 4); in try_push_frame() 271 copy_samples(s->nb_inputs, s->in, s->route, ins, &outs, nb_samples, s->bps); in try_push_frame() 275 nb_samples = 0; in try_push_frame() [all …]
|
/third_party/ffmpeg/tests/ref/fate/ |
D | gaplessenc-pcm-to-mov-aac | 27 frame|pkt_pts=0|pkt_dts=0|best_effort_timestamp=0|pkt_duration=1024|nb_samples=1024 28 frame|pkt_pts=1024|pkt_dts=1024|best_effort_timestamp=1024|pkt_duration=1024|nb_samples=1024 29 frame|pkt_pts=2048|pkt_dts=2048|best_effort_timestamp=2048|pkt_duration=1024|nb_samples=1024 30 frame|pkt_pts=3072|pkt_dts=3072|best_effort_timestamp=3072|pkt_duration=1024|nb_samples=1024 31 frame|pkt_pts=4096|pkt_dts=4096|best_effort_timestamp=4096|pkt_duration=1024|nb_samples=1024 32 frame|pkt_pts=5120|pkt_dts=5120|best_effort_timestamp=5120|pkt_duration=1024|nb_samples=1024 33 frame|pkt_pts=6144|pkt_dts=6144|best_effort_timestamp=6144|pkt_duration=1024|nb_samples=1024 34 frame|pkt_pts=7168|pkt_dts=7168|best_effort_timestamp=7168|pkt_duration=1024|nb_samples=1024 35 frame|pkt_pts=521216|pkt_dts=521216|best_effort_timestamp=521216|pkt_duration=1024|nb_samples=1024 36 frame|pkt_pts=522240|pkt_dts=522240|best_effort_timestamp=522240|pkt_duration=1024|nb_samples=1024 [all …]
|
D | gaplessinfo-itunes1 | 27 frame|pkt_pts=2112|pkt_dts=2112|best_effort_timestamp=2112|pkt_duration=960|nb_samples=960 28 frame|pkt_pts=3072|pkt_dts=3072|best_effort_timestamp=3072|pkt_duration=1024|nb_samples=1024 29 frame|pkt_pts=4096|pkt_dts=4096|best_effort_timestamp=4096|pkt_duration=1024|nb_samples=1024 30 frame|pkt_pts=5120|pkt_dts=5120|best_effort_timestamp=5120|pkt_duration=1024|nb_samples=1024 31 frame|pkt_pts=6144|pkt_dts=6144|best_effort_timestamp=6144|pkt_duration=1024|nb_samples=1024 32 frame|pkt_pts=7168|pkt_dts=7168|best_effort_timestamp=7168|pkt_duration=1024|nb_samples=1024 33 frame|pkt_pts=8192|pkt_dts=8192|best_effort_timestamp=8192|pkt_duration=1024|nb_samples=1024 34 frame|pkt_pts=9216|pkt_dts=9216|best_effort_timestamp=9216|pkt_duration=1024|nb_samples=1024 35 frame|pkt_pts=1286144|pkt_dts=1286144|best_effort_timestamp=1286144|pkt_duration=1024|nb_samples=10… 36 frame|pkt_pts=1287168|pkt_dts=1287168|best_effort_timestamp=1287168|pkt_duration=1024|nb_samples=10… [all …]
|
D | gaplessinfo-itunes2 | 27 frame|pkt_pts=2112|pkt_dts=2112|best_effort_timestamp=2112|pkt_duration=960|nb_samples=960 28 frame|pkt_pts=3072|pkt_dts=3072|best_effort_timestamp=3072|pkt_duration=1024|nb_samples=1024 29 frame|pkt_pts=4096|pkt_dts=4096|best_effort_timestamp=4096|pkt_duration=1024|nb_samples=1024 30 frame|pkt_pts=5120|pkt_dts=5120|best_effort_timestamp=5120|pkt_duration=1024|nb_samples=1024 31 frame|pkt_pts=6144|pkt_dts=6144|best_effort_timestamp=6144|pkt_duration=1024|nb_samples=1024 32 frame|pkt_pts=7168|pkt_dts=7168|best_effort_timestamp=7168|pkt_duration=1024|nb_samples=1024 33 frame|pkt_pts=8192|pkt_dts=8192|best_effort_timestamp=8192|pkt_duration=1024|nb_samples=1024 34 frame|pkt_pts=9216|pkt_dts=9216|best_effort_timestamp=9216|pkt_duration=1024|nb_samples=1024 35 frame|pkt_pts=97280|pkt_dts=97280|best_effort_timestamp=97280|pkt_duration=1024|nb_samples=1024 36 frame|pkt_pts=98304|pkt_dts=98304|best_effort_timestamp=98304|pkt_duration=1024|nb_samples=1024 [all …]
|
D | gaplessenc-itunes-to-ipod-aac | 27 frame|pkt_pts=0|pkt_dts=0|best_effort_timestamp=0|pkt_duration=1024|nb_samples=1024 28 frame|pkt_pts=1024|pkt_dts=1024|best_effort_timestamp=1024|pkt_duration=1024|nb_samples=1024 29 frame|pkt_pts=2048|pkt_dts=2048|best_effort_timestamp=2048|pkt_duration=1024|nb_samples=1024 30 frame|pkt_pts=3072|pkt_dts=3072|best_effort_timestamp=3072|pkt_duration=1024|nb_samples=1024 31 frame|pkt_pts=4096|pkt_dts=4096|best_effort_timestamp=4096|pkt_duration=1024|nb_samples=1024 32 frame|pkt_pts=5120|pkt_dts=5120|best_effort_timestamp=5120|pkt_duration=1024|nb_samples=1024 33 frame|pkt_pts=6144|pkt_dts=6144|best_effort_timestamp=6144|pkt_duration=1024|nb_samples=1024 34 frame|pkt_pts=7168|pkt_dts=7168|best_effort_timestamp=7168|pkt_duration=1024|nb_samples=1024 35 frame|pkt_pts=95232|pkt_dts=95232|best_effort_timestamp=95232|pkt_duration=1024|nb_samples=1024 36 frame|pkt_pts=96256|pkt_dts=96256|best_effort_timestamp=96256|pkt_duration=1024|nb_samples=1024 [all …]
|
D | flcl1905 | 2 …28|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=4092|sample_fmt=fltp|nb_samples=2048|channels=2|… 3 …28|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=3720|sample_fmt=fltp|nb_samples=2048|channels=2|… 4 …28|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=3348|sample_fmt=fltp|nb_samples=2048|channels=2|… 5 …28|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=2976|sample_fmt=fltp|nb_samples=2048|channels=2|… 6 …28|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=2604|sample_fmt=fltp|nb_samples=2048|channels=2|… 7 …28|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=2232|sample_fmt=fltp|nb_samples=2048|channels=2|… 8 …28|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=1860|sample_fmt=fltp|nb_samples=2048|channels=2|… 9 …28|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=1488|sample_fmt=fltp|nb_samples=2048|channels=2|… 10 …28|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=1116|sample_fmt=fltp|nb_samples=2048|channels=2|… 11 …528|pkt_duration_time=0.510839|pkt_pos=56|pkt_size=744|sample_fmt=fltp|nb_samples=2048|channels=2|… [all …]
|
D | exif-image-embedded | 48 nb_samples=47 67 nb_samples=1152 86 nb_samples=1152 105 nb_samples=1152 124 nb_samples=1152 143 nb_samples=1152 162 nb_samples=1152 181 nb_samples=1152 200 nb_samples=1152 219 nb_samples=1152 [all …]
|
/third_party/ffmpeg/libavutil/tests/ |
D | audio_fifo.c | 63 static void print_audio_bytes(const TestStruct *test_sample, void **data_planes, int nb_samples) in print_audio_bytes() argument 69 int line_size = (buffers > 1) ? nb_samples * byte_offset in print_audio_bytes() 70 : nb_samples * byte_offset * test_sample->nb_ch; in print_audio_bytes() 83 static int read_samples_from_audio_fifo(AVAudioFifo* afifo, void ***output, int nb_samples) in read_samples_from_audio_fifo() argument 86 int samples = FFMIN(nb_samples, afifo->nb_samples); in read_samples_from_audio_fifo() 102 return av_audio_fifo_read(afifo, *output, nb_samples); in read_samples_from_audio_fifo() 106 int nb_samples, int offset) in write_samples_to_audio_fifo() argument 111 if(nb_samples > test_sample->nb_samples_pch - offset){ in write_samples_to_audio_fifo() 123 return av_audio_fifo_write(afifo, data_planes, nb_samples); in write_samples_to_audio_fifo() 157 ret = av_audio_fifo_peek(afifo, output_data, afifo->nb_samples); in test_function() [all …]
|
/third_party/ffmpeg/libavcodec/ |
D | alac.c | 82 int nb_samples; /**< number of samples in the current frame */ member 113 int nb_samples, int bps, int rice_history_mult) in rice_decompress() argument 119 for (i = 0; i < nb_samples; i++) { in rice_decompress() 142 if ((history < 128) && (i + 1 < nb_samples)) { in rice_decompress() 151 if (block_size >= nb_samples - i) { in rice_decompress() 154 nb_samples, i); in rice_decompress() 155 block_size = nb_samples - i - 1; in rice_decompress() 175 int nb_samples, int bps, int16_t *lpc_coefs, in lpc_prediction() argument 184 if (nb_samples <= 1) in lpc_prediction() 189 (nb_samples - 1) * sizeof(*buffer_out)); in lpc_prediction() [all …]
|
D | audio_frame_queue.c | 53 new->duration = f->nb_samples; in ff_af_queue_add() 68 afq->remaining_samples += f->nb_samples; in ff_af_queue_add() 75 void ff_af_queue_remove(AudioFrameQueue *afq, int nb_samples, int64_t *pts, in ff_af_queue_remove() argument 87 …g(afq->avctx, AV_LOG_WARNING, "Trying to remove %d samples, but the queue is empty\n", nb_samples); in ff_af_queue_remove() 91 for(i=0; nb_samples && i<afq->frame_count; i++){ in ff_af_queue_remove() 92 int n= FFMIN(afq->frames[i].duration, nb_samples); in ff_af_queue_remove() 94 nb_samples -= n; in ff_af_queue_remove() 104 if(nb_samples){ in ff_af_queue_remove() 108 afq->frames[0].pts += nb_samples; in ff_af_queue_remove() 109 …avctx, AV_LOG_DEBUG, "Trying to remove %d more samples than there are in the queue\n", nb_samples); in ff_af_queue_remove()
|