1
mirror of https://git.videolan.org/git/ffmpeg.git synced 2024-10-02 01:05:03 +02:00

avfilter/vf_bitplanenoise: silence clang warning, do not truncate value

This commit is contained in:
Paul B Mahol 2016-09-04 14:58:54 +02:00
parent ee605aa730
commit 9833cf2ae1

View File

@ -187,7 +187,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)
stats[plane] /= s->planewidth[plane] * s->planeheight[plane]; stats[plane] /= s->planewidth[plane] * s->planeheight[plane];
snprintf(key, sizeof(key), "lavfi.bitplanenoise.%d.%d", plane, s->bitplane); snprintf(key, sizeof(key), "lavfi.bitplanenoise.%d.%d", plane, s->bitplane);
snprintf(metabuf, sizeof(metabuf), "%f", 1. - 2.* fabsf((stats[plane] - 0.5))); snprintf(metabuf, sizeof(metabuf), "%f", 1. - 2.* fabs((stats[plane] - 0.5)));
av_dict_set(&out->metadata, key, metabuf, 0); av_dict_set(&out->metadata, key, metabuf, 0);
} }