[FFmpeg-cvslog] libpostproc: add pp=help support to print the help text via av_log()

Michael Niedermayer git at videolan.org
Mon Feb 27 23:10:21 CET 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Mon Feb 27 21:48:18 2012 +0100| [f1808e304834304122ebce9325eb997a673a9dc2] | committer: Michael Niedermayer

libpostproc: add pp=help support to print the help text via av_log()

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f1808e304834304122ebce9325eb997a673a9dc2
---

 libpostproc/postprocess.c |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/libpostproc/postprocess.c b/libpostproc/postprocess.c
index ed5c240..ef9cd44 100644
--- a/libpostproc/postprocess.c
+++ b/libpostproc/postprocess.c
@@ -723,6 +723,15 @@ pp_mode *pp_get_mode_by_name_and_quality(const char *name, int quality)
     struct PPMode *ppMode;
     char *filterToken;
 
+    if (!strcmp(name, "help")) {
+        const char *p;
+        for (p = pp_help; strchr(p, '\n'); p = strchr(p, '\n') + 1) {
+            av_strlcpy(temp, p, FFMIN(sizeof(temp), strchr(p, '\n') - p + 2));
+            av_log(NULL, AV_LOG_INFO, "%s", temp);
+        }
+        return NULL;
+    }
+
     ppMode= av_malloc(sizeof(PPMode));
 
     ppMode->lumMode= 0;



More information about the ffmpeg-cvslog mailing list