ilia3101 / MLV-App

All in one MLV processing app.
https://mlv.app/
GNU General Public License v3.0
274 stars 30 forks source link

Request: 10 bit HEVC hardware encode using FFmpeg + VideoToolbox on macOS #274

Closed AndrewKeYanzhe closed 6 months ago

AndrewKeYanzhe commented 11 months ago

Is it possible to enable 10 bit HEVC hardware encode for macOS via FFmpeg with VideoToolbox?

It seems to require just a change in the flag: -c:v hevc_videotoolbox

https://trac.ffmpeg.org/wiki/HWAccelIntro

This will help to reduce CPU and memory usage.

masc4ii commented 11 months ago

No, it is not possible. It is possible to enable HEVC Videotoolbox export, but it is 8bit only. I don't find a hint for 10bit in the docs. Even if I try to request 10bit (tested via -pix_fmt p010le), what seems to be excepted by ffmpeg (written in log output), I get out a 8bit file, MediaInfo told.

So for this you can also use AVFoundation export, which uses the hardware.

Export speed for one and the same export to H265, tested on my M1: ffmpeg default: 2:59min ffmpeg videotoolbox: 1:10min AVFoundation: 0:56min