How to encode hardware-accelerated h264 video in Shotcut with Intel GPU Quicksync

Shotcut is a great open source non-linear video editor. Its default configuration however does not allow to render video on Intel GPU (such as Intel HD 4000 and newer) using Quick sync technology (hardware acceleration allowing realtime encoding of fullHD video to h264 or on newer cards even hevc a.k.a. h265. I found a way how to hack Shotcut by replacing its ffmpeg with a build that is compiled with sqv support (codecs h264_sqv, hevc_sqv etc.) and then finding the right additional parameters to encode the video. This quick guide will show you how I did it on an older laptop with Windows 10 64bit and Ivy Bridge Intel i5-Mobile CPU with Intel HD 4000 graphics (h264_qsv only), and confirmed it working on a newer Skylake i5 desktop CPU with Intel HD 530 (both h264_qsv and hevc_qsv).

Step 0: Make sure you have the Intel GPU drivers installed and working.

Step 1: Download and install Shotcut 64bit version build.

Step 2: Download a Zeranoe ffmpeg build (I used stable version 3.4, Windows-64 build, Linking Shared, but newer stable build such as 4.0 should work as well).

Step 3: Unpack the ffmpeg build and from Windows Commander copy all the files from the bin directory (avcodec-57.dll and other dlls, and ffmpeg.exe and other exes) to the C:\Program Files\Shotcut directory, replacing all the files originally supplied with Shotcut installation.

Step 4: Open Shotcut and check in Export tab in Codecs that now you see additional entries such as mpeg2_qsv, h264_qsv and hevc_qsv. These are codecs that utilize the Intel GPU for encoding!

Step 5: Create a custom export profile. Start with clicking on the stock profile e.g. H.264 Main profile that populates the values somehow. In Video tab enter the resolution 1920×1080, 30fps etc., uncheck Parallel processing, in Codec change Codec to h264_qsv, but change Quality to a much lower value becase Intel Quicksync interpretes these values completely differently than x264. I suggest you to start with Quality 25 and get lower later. Or pick a constant bitrate of 8-16 Mbit.

Important: In Other, enter these additional values:


Step 6: Save preset

Step 7: Export using this preset! Enjoy!



Pracuji jako ajťák a grafik na volné noze, zejména ale pro brněnskou firmu vyrábějící ekodrogerii. Dále působím v brněnském systému místní směny Rozleťse, Českém zahrádkářském svazu, České psychedelické společnosti, spolku Archetypal a Mezinárodní komunitě dzogčhenu. Chcete mě podpořit? BTC: 37mf2FJR26Ce3DxMkocukJDgB1eVjasnZB, příp. PGP podepsané adresy dalších kryptoměn.

2 komentáře u „How to encode hardware-accelerated h264 video in Shotcut with Intel GPU Quicksync“

  1. This works with the latest Zeranoe 4.0.2 build also.

    Don’t try the nightlies though, Shotcut will start and then crash.

  2. Hey
    Any idea how to do the same thing with NVIDIA GPUs?

Napsat komentář

Vaše e-mailová adresa nebude zveřejněna. Vyžadované informace jsou označeny *