[FFmpeg-user] Low quality when using GPU (h264_videotoolbox) to create mp4s

Lou Logan lou at lrcd.com
Fri Feb 21 22:35:27 EET 2020


On Fri, Feb 21, 2020, at 10:57 AM, MediaMouth wrote:
>
> The stdout seems to suggest the issue is -crf vs a constant bitrate..
> Codec AVOption crf (Select the quality for constant quality mode) 
> specified for output file #0 ([DestPath]) has not been used for any 
> stream. The most likely reason is either wrong type (e.g. a video 
> option with no video streams) or that it is a private option of some 
> encoder which was not actually used for any stream.
> but I've definitely used -crf in the past with h264_videotoolbox 
> without an issue.

-crf is not a generic option. It is a "private" option that is only supported by
certain encoders including libx264, libx265, libaom-av1, libvpx, and libxavs.
I see no mention of this option in libavcodec/videotoolboxenc.c.

Generic vs private option description:
https://ffmpeg.org/ffmpeg.html#AVOptions

You can see the private options offered by h264_videotoolbox with:
ffmpeg -h encoder=h264_videotoolbox

I have no experience with videotoolbox, and I don't have the necessary
hardware to try it, so I can't provide any suggestions other than to
investigate the available private options and perhaps try manually
providing an appropriate bitrate, such as -b:v 2000k.


More information about the ffmpeg-user mailing list