History

Prefix with "ff_" the functions: ff_avfilter_graph_check_validity() ff_avfilter_graph_config_links() ff_avfilter_graph_config_formats()

and move their declaration to internal.h. These functions are never used in application code, so it is better to consider them internal functions, this can be changed later if necessary. Simplify API. Originally committed as revision 25737 to svn://svn.ffmpeg.org/ffmpeg/trunk

Stefano Sabatini committed 16 years ago

Commit 4fcbb2a1 parent bbf07bf5 files · +42 −31Browse files

Unified · Split

5 files
  1. doc/APIchanges +8 −0
  2. libavfilter/avfilter.h +1 −1
  3. libavfilter/avfiltergraph.c +7 −6
  4. libavfilter/avfiltergraph.h +3 −24
  5. libavfilter/internal.h +23 −0
doc/APIchanges+8−0
@@ -13,6 +13,14 @@ libavutil: 2009-03-08 · 12 unmodified lines
1313
1414 API changes, most recent first:
1515
16+2010-11-13 - r25737 - lavfi 1.61.0 - avfiltergraph.h
17+ Remove declarations from avfiltergraph.h for the functions:
18+ avfilter_graph_check_validity()
19+ avfilter_graph_config_links()
20+ avfilter_graph_config_formats()
21+ which are now internal.
22+ Use avfilter_graph_config() instead.
23+
1624 2010-11-08 - r25708 - lavu 50.33.0 - eval.h
1725 Deprecate functions:
1826 av_parse_and_eval_expr(),
libavfilter/avfilter.h+1−1
@@ -25,7 +25,7 @@ · 24 unmodified lines
2525 #include "libavutil/avutil.h"
2626
2727 #define LIBAVFILTER_VERSION_MAJOR 1
28−#define LIBAVFILTER_VERSION_MINOR 60
28+#define LIBAVFILTER_VERSION_MINOR 61
2929 #define LIBAVFILTER_VERSION_MICRO 0
3030
3131 #define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \
libavfilter/avfiltergraph.c+7−6
@@ -25,6 +25,7 @@ · 24 unmodified lines
2525
2626 #include "avfilter.h"
2727 #include "avfiltergraph.h"
28+#include "internal.h"
2829
2930 AVFilterGraph *avfilter_graph_alloc(void)
3031 {
@@ -52,7 +53,7 @@ int avfilter_graph_add_filter(AVFilterGraph *graph, AVFilterContext *filter) · 21 unmodified lines
5253 return 0;
5354 }
5455
55−int avfilter_graph_check_validity(AVFilterGraph *graph, AVClass *log_ctx)
56+int ff_avfilter_graph_check_validity(AVFilterGraph *graph, AVClass *log_ctx)
5657 {
5758 AVFilterContext *filt;
5859 int i, j;
@@ -82,7 +83,7 @@ int avfilter_graph_check_validity(AVFilterGraph *graph, AVClass *log_ctx) · 23 unmodified lines
8283 return 0;
8384 }
8485
85−int avfilter_graph_config_links(AVFilterGraph *graph, AVClass *log_ctx)
86+int ff_avfilter_graph_config_links(AVFilterGraph *graph, AVClass *log_ctx)
8687 {
8788 AVFilterContext *filt;
8889 int i, ret;
@@ -194,7 +195,7 @@ static void pick_formats(AVFilterGraph *graph) · 105 unmodified lines
194195 }
195196 }
196197
197−int avfilter_graph_config_formats(AVFilterGraph *graph, AVClass *log_ctx)
198+int ff_avfilter_graph_config_formats(AVFilterGraph *graph, AVClass *log_ctx)
198199 {
199200 /* find supported formats from sub-filters, and merge along links */
200201 if(query_formats(graph, log_ctx))
@@ -211,11 +212,11 @@ int avfilter_graph_config(AVFilterGraph *graphctx, AVClass *log_ctx) · 10 unmodified lines
211212 {
212213 int ret;
213214
214− if ((ret = avfilter_graph_check_validity(graphctx, log_ctx)))
215+ if ((ret = ff_avfilter_graph_check_validity(graphctx, log_ctx)))
215216 return ret;
216− if ((ret = avfilter_graph_config_formats(graphctx, log_ctx)))
217+ if ((ret = ff_avfilter_graph_config_formats(graphctx, log_ctx)))
217218 return ret;
218− if ((ret = avfilter_graph_config_links(graphctx, log_ctx)))
219+ if ((ret = ff_avfilter_graph_config_links(graphctx, log_ctx)))
219220 return ret;
220221
221222 return 0;
libavfilter/avfiltergraph.h+3−24
@@ -52,33 +52,12 @@ AVFilterContext *avfilter_graph_get_filter(AVFilterGraph *graph, char *name); · 51 unmodified lines
5252 */
5353 int avfilter_graph_add_filter(AVFilterGraph *graphctx, AVFilterContext *filter);
5454
55−/**
56− * Check for the validity of graph.
57− *
58− * A graph is considered valid if all its input and output pads are
59− * connected.
60− *
61− * @return 0 in case of success, a negative value otherwise
62− */
63−int avfilter_graph_check_validity(AVFilterGraph *graphctx, AVClass *log_ctx);
64−
65−/**
66− * Configure all the links of graphctx.
67− *
68− * @return 0 in case of success, a negative value otherwise
69− */
70−int avfilter_graph_config_links(AVFilterGraph *graphctx, AVClass *log_ctx);
71−
72−/**
73− * Configure the formats of all the links in the graph.
74− */
75−int avfilter_graph_config_formats(AVFilterGraph *graphctx, AVClass *log_ctx);
76−
7755 /**
7856 * Check validity and configure all the links and formats in the graph.
7957 *
80− * @see avfilter_graph_check_validity(), avfilter_graph_config_links(),
81− * avfilter_graph_config_formats()
58+ * @param graphctx the filter graph
59+ * @param log_ctx context used for logging
60+ * @return 0 in case of success, a negative AVERROR code otherwise
8261 */
8362 int avfilter_graph_config(AVFilterGraph *graphctx, AVClass *log_ctx);
8463
libavfilter/internal.h+23−0
@@ -25,6 +25,7 @@ · 24 unmodified lines
2525 */
2626
2727 #include "avfilter.h"
28+#include "avfiltergraph.h"
2829
2930 void ff_dprintf_ref(void *ctx, AVFilterBufferRef *ref, int end);
3031
@@ -34,4 +35,26 @@ void ff_dprintf_link(void *ctx, AVFilterLink *link, int end); · 3 unmodified lines
3435
3536 #define FF_DPRINTF_START(ctx, func) dprintf(NULL, "%-16s: ", #func)
3637
38+/**
39+ * Check for the validity of graph.
40+ *
41+ * A graph is considered valid if all its input and output pads are
42+ * connected.
43+ *
44+ * @return 0 in case of success, a negative value otherwise
45+ */
46+int ff_avfilter_graph_check_validity(AVFilterGraph *graphctx, AVClass *log_ctx);
47+
48+/**
49+ * Configure all the links of graphctx.
50+ *
51+ * @return 0 in case of success, a negative value otherwise
52+ */
53+int ff_avfilter_graph_config_links(AVFilterGraph *graphctx, AVClass *log_ctx);
54+
55+/**
56+ * Configure the formats of all the links in the graph.
57+ */
58+int ff_avfilter_graph_config_formats(AVFilterGraph *graphctx, AVClass *log_ctx);
59+
3760 #endif /* AVFILTER_INTERNAL_H */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t