[FFmpeg-user] h264 videos are darker

Totte Karlsson totte.karlsson at alleninstitute.org
Thu Feb 6 21:24:24 EET 2020


Hello,

I'm recording streaming videos from a camera, using ffmpeg. The video stream is 8bit 658x492 grey and the frame rate is 30-60 fps.

Individual frames are fed to a pipe on which ffmpeg is listening. The pipeline works very reliably.

My command looks like this:

ffmpeg.exe -y -hide_banner -vcodec rawvideo -f rawvideo -r 30 -s 658x492 -pix_fmt gray -i \\.\pipe\DEV_000F315BEBB8<file://./pipe/DEV_000F315BEBB8> -r 30 -c:v libx264 -preset veryfast -crf 5 x:\\Videos\output.avi


The images are also displayed on the screen. When comparing the screen images with the resulting movie, dark areas are darker in the resulting video, especially at a higher frame rate.
As these are scientific videos, we are striving to get as good quality/compression ratio of the output as possible.

Is there any other flags to consider in the above command in order to get as close to 'real' result as possible? Any other compression algorithm working better for this?


Best Regards,
Totte Karlsson - totte.karlsson at alleninstitute.org<mailto:totte.karlsson at alleninstitute.org>
Senior Software Engineer - MPE
210B-35



More information about the ffmpeg-user mailing list