mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
Added AVClass for AVSubtitleRect
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
fd6eba428e
commit
1f46b50a95
@ -3291,6 +3291,14 @@ const AVClass *avcodec_get_class(void);
|
||||
*/
|
||||
const AVClass *avcodec_get_frame_class(void);
|
||||
|
||||
/**
|
||||
* Get the AVClass for AVSubtitleRect. It can be used in combination with
|
||||
* AV_OPT_SEARCH_FAKE_OBJ for examining options.
|
||||
*
|
||||
* @see av_opt_find().
|
||||
*/
|
||||
const AVClass *avcodec_get_subtitle_rect_class(void);
|
||||
|
||||
/**
|
||||
* Copy the settings of the source AVCodecContext into the destination
|
||||
* AVCodecContext. The resulting destination codec context will be
|
||||
|
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user