There are several options for H.264 encoding in MFormats SDK and MPlatform SDK - both CPU-based and GPU-powered.
In MFormats SDK, all CPU-based H.264 encoding options are available in the Professional edition. All hardware-accelerated H.264 encoders are available with the Expert edition. In MPlatform SDK, all encoders are part of the EncoderLib component.
Intel Quick Sync
Available in software and in hardware modes.
Codec ID for software mode: 'q264sw'
Codec ID for hardware mode: 'q264hw'
Codec ID for FFMpeg mode: 'h264_qsv'
Your Intel processor supports Quick Sync decoding if it is equipped with Intel HD Graphics 4200 or higher. Note, that for all XEON processors a mainboard with C226 chipset is required.
Quick Sync encoding has no hardware limitations for a number of encoding processes running at the same time. It depends on the processor's performance.
Please note that Intel Arc GPUs do not support the encoding of interlaced video.
Codec attributes - https://support.medialooks.com/hc/en-us/articles/20251506839698-Audio-and-video-codecs#Intel%20QuickSync%20H.264%20Encoder
Nvidia NVENC
Codec ID: 'n264'
Available, if you use NVIDIA graphics card as a default graphics device for your system.
There is a hardware limitation for a number of encoding processes running at the same time. This is made by NVIDIA.
To get information about card supported formats, please refer to this table:
https://developer.nvidia.com/video-encode-decode-gpu-support-matrix#Encoder
Here is a reference for NVIDIA NVENC SDK where you can find what features are available for your graphics card:
https://developer.nvidia.com/nvidia-video-codec-sdk
Codec attributes - https://support.medialooks.com/hc/en-us/articles/20251506839698-Audio-and-video-codecs#NVIDIA%20NVEnc%20H.264%20Encoder
Some NVIDIA graphics units might not support the encoding of interlaced video. You can check your video card with this ffmpeg command:
ffmpeg -i "your_input_file" -flags +ilme+ildct -vcodec nvenc_h264 out_ffmpeg.h264 -loglevel verbose
Here is an example of the log message:
To overcome the incorrect order issues, consider using "video::interlace=progressive" in your encoding configurations.
AMD AMF
Codec ID: 'h264_amf'
Here is a list of attributes specific to 'h264_amf' codec - https://support.medialooks.com/hc/en-us/articles/20251506839698-Audio-and-video-codecs#AMD%20AMF%20H.264%20Encoder
x264 encoder (GPL)
One of the best CPU-based encoders in the world. However, the GPL license prohibits to use this encoder in commercial applications without a special license.
We don't ship x264 with any of our products, but you can still try it with MPlatform or MFormats SDK by requesting a GPL (shared) build of FFmpeg and extracting the archive to "\EncoderLib" folder of your MPlatform SDK directory or in "\bin\[target_build]" folder for MFormats SDK, replacing existing DLLs.
Then libx264 component should be available as an encoding option for MWriter and MFWriter object.
Here is a list of attributes specific to 'libx264' codec - https://support.medialooks.com/hc/en-us/articles/20251506839698-Audio-and-video-codecs#libx264%20H.264%20/%20AVC%20/%20MPEG-4%20AVC%20/%20MPEG-4%20part%2010
Cisco OpenH264
Codec ID: 'libopenh264'
CPU-only based encoder by Cisco Systems. Able to provide only progressive scan, more details about the encoder are here - http://www.openh264.org/
Here is a list of attributes specific for 'libopenh264' codec - https://support.medialooks.com/hc/en-us/articles/20251506839698-Audio-and-video-codecs#Cisco%20libopenh264%20H.264/MPEG-4%20AVC%20Encoder