summaryrefslogtreecommitdiff
path: root/libavcodec/options.c
diff options
context:
space:
mode:
authorhakuya <erikmiranda@gmail.com>2012-04-18 02:08:25 -0400
committerMichael Niedermayer <michaelni@gmx.at>2012-04-30 19:47:21 +0200
commit1f46b50a9591f68b697e943f829c79a4f4829dd6 (patch)
tree05c739df450d567dd2b6992fc174846bc4260175 /libavcodec/options.c
parentfd6eba428e609baee53a56fede4b6f777315d6e0 (diff)
Added AVClass for AVSubtitleRect
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/options.c')
-rw-r--r--libavcodec/options.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/libavcodec/options.c b/libavcodec/options.c
index 3731b1f535..f4daf14018 100644
--- a/libavcodec/options.c
+++ b/libavcodec/options.c
@@ -255,3 +255,26 @@ const AVClass *avcodec_get_frame_class(void)
{
return &av_frame_class;
}
+
+#define SROFFSET(x) offsetof(AVSubtitleRect,x)
+
+static const AVOption subtitle_rect_options[]={
+{"x", "", SROFFSET(x), AV_OPT_TYPE_INT, {.dbl = 0 }, 0, INT_MAX, 0},
+{"y", "", SROFFSET(y), AV_OPT_TYPE_INT, {.dbl = 0 }, 0, INT_MAX, 0},
+{"w", "", SROFFSET(w), AV_OPT_TYPE_INT, {.dbl = 0 }, 0, INT_MAX, 0},
+{"h", "", SROFFSET(h), AV_OPT_TYPE_INT, {.dbl = 0 }, 0, INT_MAX, 0},
+{"type", "", SROFFSET(type), AV_OPT_TYPE_INT, {.dbl = 0 }, 0, INT_MAX, 0},
+{NULL},
+};
+
+static const AVClass av_subtitle_rect_class = {
+ .class_name = "AVSubtitleRect",
+ .item_name = NULL,
+ .option = subtitle_rect_options,
+ .version = LIBAVUTIL_VERSION_INT,
+};
+
+const AVClass *avcodec_get_subtitle_rect_class(void)
+{
+ return &av_subtitle_rect_class;
+}