[FFmpeg-devel] [PATCH 08/21] Rename ff_parse() to ff_parse_expr().
Stefano Sabatini
stefano.sabatini-lala
Sun Apr 11 01:01:20 CEST 2010
The new name is more expressive and fits better in the overall naming
scheme for the revisited eval API.
---
libavcodec/eval.c | 4 ++--
libavcodec/eval.h | 2 +-
libavcodec/ratecontrol.c | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/libavcodec/eval.c b/libavcodec/eval.c
index 72997b4..b687209 100644
--- a/libavcodec/eval.c
+++ b/libavcodec/eval.c
@@ -424,7 +424,7 @@ static int verify_expr(AVExpr * e) {
}
}
-int ff_parse(AVExpr **expr, const char *s, const char * const *const_name,
+int ff_parse_expr(AVExpr **expr, const char *s, const char * const *const_name,
double (**func1)(void *, double), const char **func1_name,
double (**func2)(void *, double, double), const char **func2_name,
void *log_ctx){
@@ -473,7 +473,7 @@ double ff_eval2(const char *s, const double *const_value, const char * const *co
void *opaque, const char **error){
AVExpr * e;
double d;
- int ret = ff_parse(&e, s, const_name, func1, func1_name, func2, func2_name, NULL);
+ int ret = ff_parse_expr(&e, s, const_name, func1, func1_name, func2, func2_name, NULL);
if (ret < 0) {
*error = "Error occurred during parsing, check log";
return NAN;
diff --git a/libavcodec/eval.h b/libavcodec/eval.h
index e82b617..d2e7ac7 100644
--- a/libavcodec/eval.h
+++ b/libavcodec/eval.h
@@ -63,7 +63,7 @@ double ff_eval2(const char *s, const double *const_value, const char * const *co
* @return 0 in case of success, a negative error corresponding to an
* AVERROR code in case of failure
*/
-int ff_parse(AVExpr **expr, const char *s, const char * const *const_name,
+int ff_parse_expr(AVExpr **expr, const char *s, const char * const *const_name,
double (**func1)(void *, double), const char **func1_name,
double (**func2)(void *, double, double), const char **func2_name,
void *log_ctx);
diff --git a/libavcodec/ratecontrol.c b/libavcodec/ratecontrol.c
index dd05668..2441728 100644
--- a/libavcodec/ratecontrol.c
+++ b/libavcodec/ratecontrol.c
@@ -106,7 +106,7 @@ int ff_rate_control_init(MpegEncContext *s)
};
emms_c();
- ret = ff_parse(&rcc->rc_eq_eval, s->avctx->rc_eq ? s->avctx->rc_eq : "tex^qComp", const_names, func1, func1_names, NULL, NULL, s->avctx);
+ ret = ff_parse_expr(&rcc->rc_eq_eval, s->avctx->rc_eq ? s->avctx->rc_eq : "tex^qComp", const_names, func1, func1_names, NULL, NULL, s->avctx);
if (ret < 0) {
av_log(s->avctx, AV_LOG_ERROR, "Error parsing rc_eq \"%s\"\n", s->avctx->rc_eq);
return ret;
--
1.7.0
More information about the ffmpeg-devel
mailing list