| MainConcept AVC Decoder Plug-in for FFmpeg 3.3.0

Loading...
Searching...
No Matches
AVC/H.264 Decoder plug-in usage

The following briefly describes how to use the MainConcept AVC/H.264 Decoder plug-in for FFmpeg.

The command-line format should follow the structure below, depending on which operating system you are using.

# On Windows

ffmpeg <ffmpeg-params>\
-c:v omx_dec_avc\
-omx_core omxil_core.dll -omx_name OMX.MainConcept
dec_avc.video\
-omx_param_dec "<mc-codec-params>"\
<ffmpeg-output-parameters>

The following is a sample command line:

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "skip=0:loop_filter=1:smp_mode=0:osd=0:low_latency=0:mv_precision=0:deinterlacing_flag=0" -i source.h264 output.yuv -y

# On Linux

Note
  The command line examples below are Windows specific. To run examples on Linux, you must slightly modify them. Instead of `-omx_core omxil_core.dll`, you need to specify `-omx_core libomxil_core.so` on Linux.

ffmpeg <ffmpeg-params>\
-c:v omx_dec_avc\
-omx_core libomxil_core.so -omx_name OMX.
MainConcept.dec_avc.video\
-omx_param_dec "<mc-codec-params>\
<ffmpeg-output-parameters>

The following is a sample command line:

    ffmpeg -c omx_dec_avc -omx_core libomxil_core.so -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "skip=0:loop_filter=1:smp_mode=0:osd=0:low_latency=0:mv_precision=0:deinterlacing_flag=0" -i source.h264 output.yuv -y

# omx_param_dec parameters (mc-codec-params)

All settings below are optional parameters for omx_param_dec parameters (mc-codec-params)

Function | Description
--- | ---
`omx_param_dec` | Specifies parameters from the AVC/H.264 decoder on the command line. Use : as a separator and = as a value set for the key, e.g. `-omx_param_dec "skip=0:loop_filter=1:smp_mode=0:osd=0:low_latency=0:mv_precision=0:deinterlacing_flag=0"` These arguments match the MainConcept AVC/H.264 Decoder settings. See Parameters for more information.
`acc_mode` | Specifies whether to use software ("sw"), Intel Quick Sync Video ("iqsv"), NVIDIA NVDEC ("nvdec") or AMD AMF ("amf") decoding. IQSV, NVDEC and AMF are GPU decoding modes.

On Windows, you have two additional acceleration modes "dxva1" (deprecated) and "dxva2" that are using DirectX Video Acceleration.

# Command line examples

Note
  The command line examples below are Windows specific. To run examples on Linux, you must slightly modify them. Instead of `-omx_core omxil_core.dll`, you need to specify `-omx_core libomxil_core.so` on Linux.

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -i source.mp4 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "acc_mode=2" -i source.mp4 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "acc_mode=0" -i source.mp4 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "skip=0:loop_filter=1:smp_mode=0:osd=0:low_latency=0:mv_precision=0:deinterlacing_flag=0" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "skip=2" -i
    source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "skip=1" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "loop_filter=0" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "loop_filter=2" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "smp=1" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "smp=2" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "osd=1" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "mv_precision=1" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "mv_precision=2" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "deinterlacing_flag=2" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "low_latency=1" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "deinterlacing_flag=1" -i source.h264 output.yuv -y

    ffmpeg -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "deinterlacing_flag=3" -i source.h264 output.yuv -y

    ffmpeg -vsync 0 -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "acc_mode=nvdec" -i inputfile.h264 out.yuv -y

    ffmpeg -vsync 0 -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "acc_mode=iqsvc" -i inputfile.h264 out.yuv -y

    ffmpeg -vsync 0 -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "acc_mode=amf" -i inputfile.h264 out.yuv -y

    ffmpeg -vsync 0 -c omx_dec_avc -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_avc.video -omx_param_dec "acc_mode=sw" -i inputfile.h264 out.yuv -y

# Parameters

The MainConcept AVC/H.264 Decoder plug-in for FFmpeg allows you to change the following decoder settings and parameters on the command-line.

`acc_toolset_map`

  Specifies the hardware acceleration mode (Windows only):

  - `cpu:` hardware-accelerated decoding off (enables software decoding only)
  - `d3d9:` decodes on GPU using the DirectX 9Ex API
  - `d3d11:` decodes on GPU using the DirectX 11 API

`skip`

  Specifies the skip mode (I, IP, IBP) or enables the obey quality messages:

  - `0`: obey quality messages, respond to quality messages from a downstream filter by skipping frames (default)
  - `1`: skip P and B frames, decode I-frames only (frame type is determined by the type of first slice of the first coded picture of a frame or complimentary field pair)
  - `2`: skip non-reference B-frames, decode I and P frames only, skips B-frames, even if they are used for reference _ `3`: skip none, decode all frames and disregard quality messages from a downstream filter

`loop_filter`

  Specifies the deblocking filter modes:

  - `0`: disable loop filter, so filtering will be skipped (note that this can result in artifacts in pictures (default)
  - `1`: filtering will be applied according to the stream parameters
  - `2`: filtering will be applied only to frames marked as 'reference' (note that this can result in artifacts in pictures)

`smp`

  Sets the Symmetric Multi-Processing (SMP) mode to control multi-threaded decoding. At the time of creation, the decoder checks for the available number of processors and, if greater than 1, the decoder automatically switches to parallel decoding by pictures:

  - `0`: SMP is disabled, only single-thread decoding is used
  - `1`: SMP is automatically selected by the decoder, i.e. it checks for multi-threading and uses "by picture" mode, if available
  - `2`: SMP is enabled, pictures are decoded on logical CPUs in parallel
  - `3`: SMP is enabled, slices of the same picture are decoded on logical CPUs in parallel (this is relevant for multi-slice pictures)

`osd`

  The decoder offers an OSD (On-Screen Display) feature, which displays statistical information during playback. If enabled, the following statistics are visible on the screen:

  - Timecode of current displayed frame in hours, minutes, seconds and pictures (timecode is calculated from GOP header timecode for every picture)
  - Drop-frame flag obtained from GOP header
  - Marker bit obtained from GOP header
  - Currently displayed frame type (I,P or B)

  Use the following parameters to enable or disable the OSD:

  - `0`: OSD disabled (default)
  - `1`: OSD enabled, i.e. information is displayed on the screen

`mv_precision`

  Specifies the limits precision of motion vectors:

  - `0`: quarter-pixel limit precision of motion vectors (default)
  - `1`: half-pixel limit precision of motion vectors
  - `2`: full-pixel limit precision of motion vectors

`deinterlacing_flag`

  Specifies the deinterlacing mode:

  - `0`: weave, do not deinterlace, i.e. output interleaved fields (default)
  - `1`: vertical filter deinterlace, applies vertical deinterlace functionality
  - `2`: field interpolation, deinterlace by interpolation
  - `3`: VMR deinterlacing, put correct interlacing flags on output samples and let VMR (Video Mixing Renderer) decide on deinterlacing
  - `4`: auto, automatic deinterlace if picture type is field or MBAFF

`low_latency`

  Enables or disables the minimal output delay. For low latency decoding, SMP mode "By slices" (3) or "Off" (0) should be set:

  - `0`: feature is disabled (default)
  - `1`: feature is enabled