FFmpeg
Data Structures | Macros | Functions
trim.c File Reference
#include <stdint.h>
#include "config.h"
#include "config_components.h"
#include "libavutil/channel_layout.h"
#include "libavutil/common.h"
#include "libavutil/log.h"
#include "libavutil/mathematics.h"
#include "libavutil/opt.h"
#include "libavutil/samplefmt.h"
#include "audio.h"
#include "avfilter.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  TrimContext
 

Macros

#define OFFSET(x)   offsetof(TrimContext, x)
 
#define COMMON_OPTS
 

Functions

static av_cold int init (AVFilterContext *ctx)
 
static int config_input (AVFilterLink *inlink)
 

Macro Definition Documentation

◆ OFFSET

#define OFFSET (   x)    offsetof(TrimContext, x)

Definition at line 105 of file trim.c.

◆ COMMON_OPTS

#define COMMON_OPTS
Value:
{ "start", "Timestamp of the first frame that " \
"should be passed", OFFSET(start_time), AV_OPT_TYPE_DURATION, { .i64 = INT64_MAX }, INT64_MIN, INT64_MAX, FLAGS }, \
{ "starti", "Timestamp of the first frame that " \
"should be passed", OFFSET(start_time), AV_OPT_TYPE_DURATION, { .i64 = INT64_MAX }, INT64_MIN, INT64_MAX, FLAGS }, \
{ "end", "Timestamp of the first frame that " \
"should be dropped again", OFFSET(end_time), AV_OPT_TYPE_DURATION, { .i64 = INT64_MAX }, INT64_MIN, INT64_MAX, FLAGS }, \
{ "endi", "Timestamp of the first frame that " \
"should be dropped again", OFFSET(end_time), AV_OPT_TYPE_DURATION, { .i64 = INT64_MAX }, INT64_MIN, INT64_MAX, FLAGS }, \
{ "start_pts", "Timestamp of the first frame that should be " \
" passed", OFFSET(start_pts), AV_OPT_TYPE_INT64, { .i64 = AV_NOPTS_VALUE }, INT64_MIN, INT64_MAX, FLAGS }, \
{ "end_pts", "Timestamp of the first frame that should be " \
"dropped again", OFFSET(end_pts), AV_OPT_TYPE_INT64, { .i64 = AV_NOPTS_VALUE }, INT64_MIN, INT64_MAX, FLAGS }, \
{ "duration", "Maximum duration of the output", OFFSET(duration), AV_OPT_TYPE_DURATION, { .i64 = 0 }, 0, INT64_MAX, FLAGS }, \
{ "durationi", "Maximum duration of the output", OFFSET(duration), AV_OPT_TYPE_DURATION, { .i64 = 0 }, 0, INT64_MAX, FLAGS },

Definition at line 106 of file trim.c.

Function Documentation

◆ init()

static av_cold int init ( AVFilterContext ctx)
static

Definition at line 73 of file trim.c.

◆ config_input()

static int config_input ( AVFilterLink inlink)
static

Definition at line 82 of file trim.c.

AV_OPT_TYPE_DURATION
@ AV_OPT_TYPE_DURATION
Definition: opt.h:239
FLAGS
#define FLAGS
Definition: cmdutils.c:515
duration
int64_t duration
Definition: movenc.c:64
AV_OPT_TYPE_INT64
@ AV_OPT_TYPE_INT64
Definition: opt.h:226
OFFSET
#define OFFSET(x)
Definition: trim.c:105
start_time
static int64_t start_time
Definition: ffplay.c:331
AV_NOPTS_VALUE
#define AV_NOPTS_VALUE
Undefined timestamp value.
Definition: avutil.h:248