[FFmpeg-cvslog] swr: add swr_get_class()
Michael Niedermayer
git at videolan.org
Wed Apr 11 14:30:12 CEST 2012
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Wed Apr 11 13:25:56 2012 +0200| [22057e8ecb6bc18ad60a7d0ac7f11f9c0635c1e5] | committer: Michael Niedermayer
swr: add swr_get_class()
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=22057e8ecb6bc18ad60a7d0ac7f11f9c0635c1e5
---
libswresample/swresample.c | 5 +++++
libswresample/swresample.h | 8 ++++++++
2 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/libswresample/swresample.c b/libswresample/swresample.c
index 58096b3..e7f61cb 100644
--- a/libswresample/swresample.c
+++ b/libswresample/swresample.c
@@ -97,6 +97,11 @@ int swr_set_channel_mapping(struct SwrContext *s, const int *channel_map){
return 0;
}
+const AVClass *swr_get_class(void)
+{
+ return &av_class;
+}
+
struct SwrContext *swr_alloc(void){
SwrContext *s= av_mallocz(sizeof(SwrContext));
if(s){
diff --git a/libswresample/swresample.h b/libswresample/swresample.h
index 9bd5b67..3a54c8e 100644
--- a/libswresample/swresample.h
+++ b/libswresample/swresample.h
@@ -55,6 +55,14 @@ enum SwrDitherType {
typedef struct SwrContext SwrContext;
/**
+ * Get the AVClass for swrContext. It can be used in combination with
+ * AV_OPT_SEARCH_FAKE_OBJ for examining options.
+ *
+ * @see av_opt_find().
+ */
+const AVClass *swr_get_class(void);
+
+/**
* Allocate SwrContext.
*
* If you use this function you will need to set the parameters (manually or
More information about the ffmpeg-cvslog
mailing list