43 "NB_CONSUMED_SAMPLES",
140 #define D2TS(d) (isnan(d) ? AV_NOPTS_VALUE : (int64_t)(d))
141 #define TS2D(ts) ((ts) == AV_NOPTS_VALUE ? NAN : (double)(ts))
142 #define TS2T(ts, tb) ((ts) == AV_NOPTS_VALUE ? NAN : (double)(ts)*av_q2d(tb))
153 #define d2istr(v) double2int64str((char[BUF_SIZE]){0}, v)
158 int64_t in_pts = frame->
pts;
181 "N:%"PRId64
" PTS:%s T:%f POS:%s",
186 switch (inlink->
type) {
222 #define OFFSET(x) offsetof(SetPTSContext, x)
223 #define FLAGS AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_AUDIO_PARAM | AV_OPT_FLAG_FILTERING_PARAM
229 #if CONFIG_SETPTS_FILTER
230 #define setpts_options options
233 static const AVFilterPad avfilter_vf_setpts_inputs[] = {
243 static const AVFilterPad avfilter_vf_setpts_outputs[] = {
258 .priv_class = &setpts_class,
260 .
inputs = avfilter_vf_setpts_inputs,
261 .
outputs = avfilter_vf_setpts_outputs,
265 #if CONFIG_ASETPTS_FILTER
267 #define asetpts_options options
294 .priv_class = &asetpts_class,
static const char *const var_names[]
This structure describes decoded (raw) audio or video data.
static const AVFilterPad outputs[]
Main libavfilter public API header.
static int config_input(AVFilterLink *inlink)
double var_values[VAR_VARS_NB]
int av_expr_parse(AVExpr **expr, const char *s, const char *const *const_names, const char *const *func1_names, double(*const *funcs1)(void *, double), const char *const *func2_names, double(*const *funcs2)(void *, double, double), int log_offset, void *log_ctx)
Parse an expression.
const char * name
Pad name.
int ff_filter_frame(AVFilterLink *link, AVFrame *frame)
Send a frame of data to the next filter.
static av_always_inline av_const int isnan(float x)
#define AV_LOG_TRACE
Extremely verbose debugging, useful for libav* development.
int64_t pts
Presentation timestamp in time_base units (time when frame should be shown to user).
static double av_q2d(AVRational a)
Convert rational to double.
#define AV_LOG_VERBOSE
Detailed information.
int interlaced_frame
The content of the picture is interlaced.
A filter pad used for either input or output.
A link between two filters.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
AVRational frame_rate
Frame rate of the stream on the link, or 1/0 if unknown; if left to 0/0, will be automatically be cop...
int sample_rate
samples per second
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
void * priv
private data for use by the filter
AVRational time_base
Define the time base used by the PTS of the frames/samples which will pass through this link...
common internal API header
static const AVOption options[]
static char * double2int64str(char *buf, double v)
AVFilterContext * src
source filter
static av_cold void uninit(AVFilterContext *ctx)
int64_t av_gettime(void)
Get the current time in microseconds.
void av_expr_free(AVExpr *e)
Free a parsed expression previously created with av_expr_parse().
Describe the class of an AVClass context structure.
static const AVFilterPad inputs[]
const char * name
Filter name.
AVFilterLink ** outputs
array of pointers to output links
enum AVMediaType type
filter media type
static int filter_frame(AVFilterLink *inlink, AVFrame *frame)
double av_expr_eval(AVExpr *e, const double *const_values, void *opaque)
Evaluate a previously parsed expression.
AVFilterContext * dst
dest filter
int64_t av_frame_get_pkt_pos(const AVFrame *frame)
#define AVFILTER_DEFINE_CLASS(fname)
int nb_samples
number of audio samples (per channel) described by this frame
static av_cold int init(AVFilterContext *ctx)
simple arithmetic expression evaluator