[FFmpeg-devel] [PATCH] lsws: define version in SWScaler class

Stefano Sabatini stefasab at gmail.com
Thu Nov 29 00:29:30 CET 2012


The version number is useful to check the libavutil version against which
the library was compiled at run-time, which in turn may be useful to deal
with binary compatibility issues.
---
 libswscale/options.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/libswscale/options.c b/libswscale/options.c
index 9cd4fc0..f7d261c 100644
--- a/libswscale/options.c
+++ b/libswscale/options.c
@@ -71,6 +71,7 @@ const AVClass sws_context_class = {
     .item_name  = sws_context_to_name,
     .option     = options,
     .category   = AV_CLASS_CATEGORY_SWSCALER,
+    .version    = LIBAVUTIL_VERSION_INT,
 };
 
 const AVClass *sws_get_class(void)
-- 
1.7.9.5



More information about the ffmpeg-devel mailing list