[FFmpeg-cvslog] r25673 - in trunk: doc/APIchanges ffmpeg.c ffplay.c libavfilter/avfilter.h libavfilter/avfiltergraph.c libavfilter/avfiltergraph.h

stefano subversion
Thu Nov 4 21:34:19 CET 2010


Author: stefano
Date: Thu Nov  4 21:34:19 2010
New Revision: 25673

Log:
Implement avfilter_graph_alloc().

Modified:
   trunk/doc/APIchanges
   trunk/ffmpeg.c
   trunk/ffplay.c
   trunk/libavfilter/avfilter.h
   trunk/libavfilter/avfiltergraph.c
   trunk/libavfilter/avfiltergraph.h

Modified: trunk/doc/APIchanges
==============================================================================
--- trunk/doc/APIchanges	Thu Nov  4 21:26:45 2010	(r25672)
+++ trunk/doc/APIchanges	Thu Nov  4 21:34:19 2010	(r25673)
@@ -13,6 +13,9 @@ libavutil:   2009-03-08
 
 API changes, most recent first:
 
+2010-11-04 - r25672 - lavfi 1.55.0 - avfilter_graph_alloc()
+  Add avfilter_graph_alloc() to libavfilter/avfiltergraph.h.
+
 2010-11-02 - r25654 - lavcore 0.12.0 - av_get_bits_per_sample_fmt()
   Add av_get_bits_per_sample_fmt() to libavcore/samplefmt.h and
   deprecate av_get_bits_per_sample_format().

Modified: trunk/ffmpeg.c
==============================================================================
--- trunk/ffmpeg.c	Thu Nov  4 21:26:45 2010	(r25672)
+++ trunk/ffmpeg.c	Thu Nov  4 21:34:19 2010	(r25673)
@@ -345,7 +345,7 @@ static int configure_filters(AVInputStre
     char args[255];
     int ret;
 
-    graph = av_mallocz(sizeof(AVFilterGraph));
+    graph = avfilter_graph_alloc();
 
     if ((ret = avfilter_open(&ist->input_video_filter, avfilter_get_by_name("buffer"), "src")) < 0)
         return ret;

Modified: trunk/ffplay.c
==============================================================================
--- trunk/ffplay.c	Thu Nov  4 21:26:45 2010	(r25672)
+++ trunk/ffplay.c	Thu Nov  4 21:34:19 2010	(r25673)
@@ -1795,7 +1795,7 @@ static int video_thread(void *arg)
     char sws_flags_str[128];
     FFSinkContext ffsink_ctx = { .pix_fmt = PIX_FMT_YUV420P };
     AVFilterContext *filt_src = NULL, *filt_out = NULL;
-    AVFilterGraph *graph = av_mallocz(sizeof(AVFilterGraph));
+    AVFilterGraph *graph = avfilter_graph_alloc();
     snprintf(sws_flags_str, sizeof(sws_flags_str), "flags=%d", sws_flags);
     graph->scale_sws_opts = av_strdup(sws_flags_str);
 

Modified: trunk/libavfilter/avfilter.h
==============================================================================
--- trunk/libavfilter/avfilter.h	Thu Nov  4 21:26:45 2010	(r25672)
+++ trunk/libavfilter/avfilter.h	Thu Nov  4 21:34:19 2010	(r25673)
@@ -25,7 +25,7 @@
 #include "libavutil/avutil.h"
 
 #define LIBAVFILTER_VERSION_MAJOR  1
-#define LIBAVFILTER_VERSION_MINOR 54
+#define LIBAVFILTER_VERSION_MINOR 55
 #define LIBAVFILTER_VERSION_MICRO  0
 
 #define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \

Modified: trunk/libavfilter/avfiltergraph.c
==============================================================================
--- trunk/libavfilter/avfiltergraph.c	Thu Nov  4 21:26:45 2010	(r25672)
+++ trunk/libavfilter/avfiltergraph.c	Thu Nov  4 21:34:19 2010	(r25673)
@@ -26,6 +26,11 @@
 #include "avfilter.h"
 #include "avfiltergraph.h"
 
+AVFilterGraph *avfilter_graph_alloc(void)
+{
+    return av_mallocz(sizeof(AVFilterGraph));
+}
+
 void avfilter_graph_destroy(AVFilterGraph *graph)
 {
     for(; graph->filter_count > 0; graph->filter_count --)

Modified: trunk/libavfilter/avfiltergraph.h
==============================================================================
--- trunk/libavfilter/avfiltergraph.h	Thu Nov  4 21:26:45 2010	(r25672)
+++ trunk/libavfilter/avfiltergraph.h	Thu Nov  4 21:34:19 2010	(r25673)
@@ -32,6 +32,11 @@ typedef struct AVFilterGraph {
 } AVFilterGraph;
 
 /**
+ * Allocate a filter graph.
+ */
+AVFilterGraph *avfilter_graph_alloc(void);
+
+/**
  * Get a filter instance with name name from graph.
  *
  * @return the pointer to the found filter instance or NULL if it



More information about the ffmpeg-cvslog mailing list