[FFmpeg-cvslog] lavfi/subtitles: split options between ass and subtitles.
Clément Bœsch
git at videolan.org
Sun Feb 17 13:04:12 CET 2013
ffmpeg | branch: master | Clément Bœsch <ubitux at gmail.com> | Mon Dec 31 11:07:29 2012 +0100| [3a0a959dcbf80f46241ff4997e5b095e6695b84d] | committer: Clément Bœsch
lavfi/subtitles: split options between ass and subtitles.
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=3a0a959dcbf80f46241ff4997e5b095e6695b84d
---
libavfilter/vf_ass.c | 22 ++++++++++++++--------
1 file changed, 14 insertions(+), 8 deletions(-)
diff --git a/libavfilter/vf_ass.c b/libavfilter/vf_ass.c
index c64d940..84ce55d 100644
--- a/libavfilter/vf_ass.c
+++ b/libavfilter/vf_ass.c
@@ -59,12 +59,10 @@ typedef struct {
#define OFFSET(x) offsetof(AssContext, x)
#define FLAGS AV_OPT_FLAG_FILTERING_PARAM|AV_OPT_FLAG_VIDEO_PARAM
-static const AVOption options[] = {
- {"filename", "set the filename of file to read", OFFSET(filename), AV_OPT_TYPE_STRING, {.str = NULL}, CHAR_MIN, CHAR_MAX, FLAGS },
- {"f", "set the filename of file to read", OFFSET(filename), AV_OPT_TYPE_STRING, {.str = NULL}, CHAR_MIN, CHAR_MAX, FLAGS },
- {"original_size", "set the size of the original video (used to scale fonts)", OFFSET(original_w), AV_OPT_TYPE_IMAGE_SIZE, {.str = NULL}, CHAR_MIN, CHAR_MAX, FLAGS },
- {NULL},
-};
+#define COMMON_OPTIONS \
+ {"filename", "set the filename of file to read", OFFSET(filename), AV_OPT_TYPE_STRING, {.str = NULL}, CHAR_MIN, CHAR_MAX, FLAGS }, \
+ {"f", "set the filename of file to read", OFFSET(filename), AV_OPT_TYPE_STRING, {.str = NULL}, CHAR_MIN, CHAR_MAX, FLAGS }, \
+ {"original_size", "set the size of the original video (used to scale fonts)", OFFSET(original_w), AV_OPT_TYPE_IMAGE_SIZE, {.str = NULL}, CHAR_MIN, CHAR_MAX, FLAGS }, \
/* libass supports a log level ranging from 0 to 7 */
static const int ass_libavfilter_log_level_map[] = {
@@ -213,7 +211,11 @@ static const AVFilterPad ass_outputs[] = {
#if CONFIG_ASS_FILTER
-#define ass_options options
+static const AVOption ass_options[] = {
+ COMMON_OPTIONS
+ {NULL},
+};
+
AVFILTER_DEFINE_CLASS(ass);
static av_cold int init_ass(AVFilterContext *ctx, const char *args)
@@ -249,7 +251,11 @@ AVFilter avfilter_vf_ass = {
#if CONFIG_SUBTITLES_FILTER
-#define subtitles_options options
+static const AVOption subtitles_options[] = {
+ COMMON_OPTIONS
+ {NULL},
+};
+
AVFILTER_DEFINE_CLASS(subtitles);
static av_cold int init_subtitles(AVFilterContext *ctx, const char *args)
More information about the ffmpeg-cvslog
mailing list