X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavfilter%2Favf_ahistogram.c;h=587415175b562d7e87389bf4dca151245495db1d;hb=cc16229d914aa0eea827599f9df7716bb2afa36b;hp=a716a96f2de2cbc96bfb22edff3d4f8a0244e7f3;hpb=f32a23c8491297d0ff19656cd7a09b6c8fa3eafb;p=ffmpeg diff --git a/libavfilter/avf_ahistogram.c b/libavfilter/avf_ahistogram.c index a716a96f2de..587415175b5 100644 --- a/libavfilter/avf_ahistogram.c +++ b/libavfilter/avf_ahistogram.c @@ -63,8 +63,8 @@ static const AVOption ahistogram_options[] = { { "dmode", "set method to display channels", OFFSET(dmode), AV_OPT_TYPE_INT, {.i64=SINGLE}, 0, NB_DMODES-1, FLAGS, "dmode" }, { "single", "all channels use single histogram", 0, AV_OPT_TYPE_CONST, {.i64=SINGLE}, 0, 0, FLAGS, "dmode" }, { "separate", "each channel have own histogram", 0, AV_OPT_TYPE_CONST, {.i64=SEPARATE}, 0, 0, FLAGS, "dmode" }, - { "rate", "set video rate", OFFSET(frame_rate), AV_OPT_TYPE_VIDEO_RATE, {.str="25"}, 0, 0, FLAGS }, - { "r", "set video rate", OFFSET(frame_rate), AV_OPT_TYPE_VIDEO_RATE, {.str="25"}, 0, 0, FLAGS }, + { "rate", "set video rate", OFFSET(frame_rate), AV_OPT_TYPE_VIDEO_RATE, {.str="25"}, 0, INT_MAX, FLAGS }, + { "r", "set video rate", OFFSET(frame_rate), AV_OPT_TYPE_VIDEO_RATE, {.str="25"}, 0, INT_MAX, FLAGS }, { "size", "set video size", OFFSET(w), AV_OPT_TYPE_IMAGE_SIZE, {.str="hd720"}, 0, 0, FLAGS }, { "s", "set video size", OFFSET(w), AV_OPT_TYPE_IMAGE_SIZE, {.str="hd720"}, 0, 0, FLAGS }, { "scale", "set display scale", OFFSET(scale), AV_OPT_TYPE_INT, {.i64=LOG}, LINEAR, NB_SCALES-1, FLAGS, "scale" }, @@ -165,7 +165,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in) const int H = s->histogram_h; const int w = s->w; int c, y, n, p, bin; - uint64_t acmax = 0; + uint64_t acmax = 1; if (!s->out || s->out->width != outlink->w || s->out->height != outlink->h) {