• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/minidlna/ffmpeg-2.3.4/libavfilter/

Lines Matching defs:sine

39     uint32_t phi;  ///< current phase of the sine (2pi = 1<<32)
65 OPT_DBL("frequency", frequency, 440, 0, DBL_MAX, "set the sine frequency"),
66 OPT_DBL("f", frequency, 440, 0, DBL_MAX, "set the sine frequency"),
77 AVFILTER_DEFINE_CLASS(sine);
125 SineContext *sine = ctx->priv;
127 if (!(sine->sin = av_malloc(sizeof(*sine->sin) << LOG_PERIOD)))
129 sine->dphi = ldexp(sine->frequency, 32) / sine->sample_rate + 0.5;
130 make_sin_table(sine->sin);
132 if (sine->beep_factor) {
133 sine->beep_period = sine->sample_rate;
134 sine->beep_length = sine->beep_period / 25;
135 sine->dphi_beep = ldexp(sine->beep_factor * sine->frequency, 32) /
136 sine->sample_rate + 0.5;
144 SineContext *sine = ctx->priv;
146 av_freep(&sine->sin);
151 SineContext *sine = ctx->priv;
153 int sample_rates[] = { sine->sample_rate, -1 };
165 SineContext *sine = outlink->src->priv;
166 sine->duration = av_rescale(sine->duration, sine->sample_rate, AV_TIME_BASE);
172 SineContext *sine = outlink->src->priv;
174 int i, nb_samples = sine->samples_per_frame;
177 if (sine->duration) {
178 nb_samples = FFMIN(nb_samples, sine->duration - sine->pts);
188 samples[i] = sine->sin[sine->phi >> (32 - LOG_PERIOD)];
189 sine->phi += sine->dphi;
190 if (sine->beep_index < sine->beep_length) {
191 samples[i] += sine->sin[sine->phi_beep >> (32 - LOG_PERIOD)] << 1;
192 sine->phi_beep += sine->dphi_beep;
194 if (++sine->beep_index == sine->beep_period)
195 sine->beep_index = 0;
198 frame->pts = sine->pts;
199 sine->pts += nb_samples;
214 .name = "sine",
215 .description = NULL_IF_CONFIG_SMALL("Generate sine wave audio signal."),