ffmpeg # CUDA/CUVID/NVDEC # 完全硬件轉(zhuǎn)碼 vs 部分硬件轉(zhuǎn)碼

CUVID, which is also called NVDEC by NVIDIA now, can be used for decoding on Windows and Linux.
In combination with NVENC, it offers full hardware transcoding.

CUVID offers decoders for H.264, HEVC, MJPEG, MPEG-1/2/4, VP8/VP9, VC-1.
Codec support varies by hardware.
The full set of codecs being available only on Pascal hardware, which adds VP9 and 10 bit support.

解碼經(jīng)過系統(tǒng)內(nèi)存

Sample decode using CUVID, the cuvid decoder copies the frames to system memory in this case:

ffmpeg -c:v h264_cuvid -i input output.mkv

這種情況,解碼器會將解碼后的數(shù)據(jù)拷貝到系統(tǒng)內(nèi)存。

完全硬件轉(zhuǎn)碼

Full hardware transcode with CUVID and NVENC:

ffmpeg -hwaccel cuvid -c:v h264_cuvid -i input -c:v h264_nvenc -preset slow output.mkv

加了 -hwaccel cuvid之后,這種情況完全通過顯卡GPU完成。

部分硬件轉(zhuǎn)碼

Partial hardware transcode, with frames passed through system memory:

ffmpeg -c:v h264_cuvid -i input -c:v h264_nvenc -preset slow output.mkv

部分硬件解碼。解碼后的數(shù)據(jù)會通過系統(tǒng)內(nèi)存。

References:

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

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

  • rljs by sennchi Timeline of History Part One The Cognitiv...
    sennchi閱讀 7,854評論 0 10
  • 紋身師小王 ...
    駱駝和馬閱讀 998評論 0 1
  • 小時候,大人們告誡我,不要相信你所看到的一切,這個世界,本就丑陋。
    桐姬閱讀 145評論 0 0
  • 又要感謝微信讀書了,在最新一期的免費(fèi)領(lǐng)書中,我獲得了這本《說醫(yī)不二》。 剛開始不以為然,以為又是一些野路子寫手發(fā)表...
    Y伊歆Y閱讀 1,521評論 0 3

友情鏈接更多精彩內(nèi)容