[FFmpeg-devel] [PATCH] lavfi: remove avfilter_default_item_name() from public API

Stefano Sabatini stefasab at gmail.com
Tue Jun 5 19:03:24 CEST 2012


The function is not used anymore outside avfilter.c.

This avoids to pollute the public API with an apparently unnecessary
function. The function was introduced two days ago, so it should do no
much harm.
---
 doc/APIchanges         |    3 ---
 libavfilter/avfilter.c |    4 ++--
 libavfilter/avfilter.h |    6 ------
 3 files changed, 2 insertions(+), 11 deletions(-)

diff --git a/doc/APIchanges b/doc/APIchanges
index 2da438f..15cf379 100644
--- a/doc/APIchanges
+++ b/doc/APIchanges
@@ -18,9 +18,6 @@ API changes, most recent first:
 2012-06-05 - xxxxxxx - lavc 54.24.100
   Add pkt_duration field to AVFrame.
 
-2012-06-04 - xxxxxxx - lafi 2.78.100
-  Add avfilter_default_filter_name() function in avfilter.h.
-
 2012-05-24 - xxxxxxx - lavu 51.54.100
   Move AVPALETTE_SIZE and AVPALETTE_COUNT macros from
   libavcodec/avcodec.h to libavutil/pixfmt.h.
diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c
index 4639d01..88b535b 100644
--- a/libavfilter/avfilter.c
+++ b/libavfilter/avfilter.c
@@ -404,7 +404,7 @@ static int pad_count(const AVFilterPad *pads)
     return count;
 }
 
-const char *avfilter_default_filter_name(void *filter_ctx)
+static char *default_filter_name(void *filter_ctx)
 {
     AVFilterContext *ctx = filter_ctx;
     return ctx->name ? ctx->name : ctx->filter->name;
@@ -412,7 +412,7 @@ const char *avfilter_default_filter_name(void *filter_ctx)
 
 static const AVClass avfilter_class = {
     .class_name = "AVFilter",
-    .item_name  = avfilter_default_filter_name,
+    .item_name  = default_filter_name,
     .version    = LIBAVUTIL_VERSION_INT,
     .category = AV_CLASS_CATEGORY_FILTER,
 };
diff --git a/libavfilter/avfilter.h b/libavfilter/avfilter.h
index 10803c5..c9d63d6 100644
--- a/libavfilter/avfilter.h
+++ b/libavfilter/avfilter.h
@@ -634,12 +634,6 @@ struct AVFilterContext {
     struct AVFilterCommand *command_queue;
 };
 
-/**
- * Print the name of the filter given a filter context.
- */
-const char *avfilter_default_filter_name(void *filter_ctx);
-
-
 #if FF_API_PACKING
 enum AVFilterPacking {
     AVFILTER_PACKED = 0,
-- 
1.7.5.4



More information about the ffmpeg-devel mailing list