MainConcept Dolby Digital Plus Pro Decoder Plug-in for FFmpeg 3.2.0
Loading...
Searching...
No Matches
Dolby Digital Plus Pro Decoder plug-in usage

The following briefly describes how to use the MainConcept Dolby Digital Plus Pro 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 omx_dec_ddpp
-omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_ddpp.audio \
-omx_param "<mc-general-params>" \
[ddp_parser_settings] "<mc-codec-params>" \
<ffmpeg-output-parameters>

The following is a sample command line to dump the RAW audio frames to disk as a signed 16-bit little endian PCM file:

ffmpeg -c omx_dec_ddpp -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_ddpp.audio -i 8_voices_input.ac3 8_voices_output.wav -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 omx_dec_ddpp
-omx_core libomxil_core.so -omx_name OMX.MainConcept.dec_ddpp.audio \
<ffmpeg-output-parameters>

The following is a sample command line to dump the RAW audio frames to disk as a signed 16-bit little endian PCM file:

ffmpeg -c omx_dec_ddpp -omx_core libomxil_core.so -omx_name OMX.MainConcept.dec_ddpp.audio  -i 8_voices_input.ac3 8_voices_output.wav -y

All settings below are optional parameters for omx_param parameters (mc-general-params):

Function Description
[ddp_parser_settings] Specifies parameters from the Dolby Digital Plus Pro decoder configuration on the command line, which can be applied under [ddp_parser_settings]. Use : as a separator and = as a value set for the key.
    -omx_param "[ddp_parser_settings]:error_conceal_flag=1:compression_mode=2: ... : ..."
These arguments match the MainConcept Dolby Digital Plus Pro decoder settings (see [ddp_parser_settings] for more information or a DDPP decoder configuration file as an example).

On Windows, you have two additional acceleration modes dxva1 (deprecated) and dxva2 that use 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_ddpp -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_ddpp.audio -i 8_voices_input.ac3 8_voices_output.wav -y
ffmpeg -c omx_dec_ddpp -omx_core omxil_core.dll -omx_name OMX.MainConcept.dec_ddpp.audio -i 8_voices_input.ac3 -omx_param "[ddp_parser_settings]:error_conceal_flag=1:compression_mode=2" 8_voices_output.wav -y

Parameters

[ddp_parser_settings]

This section contains information on decoder parser settings.

Decoder parser settings

output_word_size

Sets the format of the PCM data output by the decoder.
  • 0: 16-bit short integers, default endian (default)
  • 1: 16-bit short integers, swap endian
  • 2: 32-bit floating point
  • 4: 64-bit double precision floating point
  • 8: 24-bit integer, little endian
  • 10: 32-bit integer, little endian

output_mode

Contains the audio coding mode as present in the bitstream. This indicates the number of input channels (along with the lfeon field in the bitstream).
  • - 1: 1/0 (C)
  • 2: 2/0 (L, R)
  • 3: 3/0 (L, C, R)
  • 4: 2/1 (L, R, I)
  • 5: 3/1 (L, C, R, I)
  • 6: 2/2 (L, R, Ls, Rs)
  • 7: 3/2 (L, C, R, Ls, Rs)
  • 9: 2/2/1 (L, R, Ls, Rs, Ts)
  • 10: 3/2/1 (L, C, R, Ls, Rs, Ts)
  • 11: 3/2/1 (L, C, R, Ls, Rs, Cvh)
  • 12: 3/0/2 (L, C, R, Lc, Rc)
  • 13: 2/2/2 (L, C, R, Ls, Rs, Lw, Rw)
  • 14: 2/2/2 (L, C, R, Ls, Rs, Lvh, Rvh)
  • 15: 2/2/2 (L, C, R, Ls, Rs, Lsd, Rsd)
  • 16: 2/2/2 (L, C, R, Ls, Rs, Lrs, Rrs)
  • 17: 3/2/2 (L, C, R, Ls, Rs, Lc, Rc)
  • 18: 3/2/2 (L, C, R, Ls, Rs, Lw, Rw)
  • 19: 3/2/2 (L, C, R, Ls, Rs, Lvh, Rvh)
  • 20: 3/2/2 (L, C, R, Ls, Rs, Lsd, Rsd)
  • 21: 3/2/2 (L, C, R, Ls, Rs, Lrs, Rrs)
  • 24: 3/2/1 (L. C, R, Ls, Rs, Cs)
Note
See all output_lfe and output_mode options.
Output mode 24 is not supported in the case of downmixing without using a custom downmix table.

output_lfe

Specifies the output LFE flag.
  • -1: Auto LFE mode (default)
  • 0: No LFE channel
  • 1: LFE channel is present
Note
See also output_num_channels and output_mode options.

output_num_channels

Specifies the number of output channels, including LFE channel. If a custom custom_channel_table is not used, this field should reflect the number of channels specified by output_mode and output_lfe. If a custom channel table is used, this value can be different to what is implied by output_mode and output_lfe.
Note
If the number of output channels specified is:
  • Less than the total number of channels specified in the output_mode + output_lfe fields, the number defined in output_num_channels will be used
  • Greater than the total number of channels specified in the output_mode + output_lfe fields, the additional channels will be taken in the order of mode 4 (additional channels will contain silence)

compression_mode

Specifies the output compression mode.
  • -1: Auto compression mode (default)
  • 0: Custom mode, analog dialnorm (no digital dialog normalization)
  • 1: Custom mode, digital dialog normalization
  • 2: Line out mode
  • 3: RF mode

stereo_output_mode

Output mode for stereo (2/0) and dual (1+1) bitstreams.
  • 0: Automatically detect stereo mode (default)
  • 1: 2/0 Dolby Surround compatible (Lt, Rt)
  • 2: 2/0 Stereo (Lo, Ro)

dual_mono_mode

Output reproduction mode for dual (1+1) and mono (1/0) bitstreams.
  • 0: Reproduce as stereo (default)
  • 1: Reproduce channel 1 as mono
  • 2: Reproduce channel 2 as mono
  • 3: Mix channel 1 and channel 2 as mono

dynamic_range_scale_low

Integer number (in %) for low-level signals, which is used to scale the dynamic range control word for low-level signals that would otherwise tend to be amplified. A value of DDP_SCALEFACTOR_MIN disables low-level amplification. This field is ignored if compression_mode is set to RF mode.
-1: Auto select scale factor (default). When using this value, the DDP_SCALEFACTOR_MAX parameter is set as well.
  • 0: Lower border of scale factor.
  • 100: Upper border of scale factor.

dynamic_range_scale_hi

Integer number (in %) for high-level signals which is used to scale the dynamic range control word for high-level signals that would otherwise tend to be reduced. A value of DDP_SCALEFACTOR_MIN disables high-level amplification. This field is ignored if compression_mode is set to RF mode.
  • -1: Auto select scale factor (default). When using this value, the DDP_SCALEFACTOR_MAX parameter is set as well.
  • 0: Lower border of scale factor.
  • 100: Upper border of scale factor.

pcm_scale_factor

Integer number (in %) to scale the final output data prior to write to the PCM output buffers. A value of DDP_SCALEFACTOR_MIN mutes the PCM output.
  • -1: Auto select scale factor (default)
  • 0: Lower border of scale factor
  • 100: Upper border of scale factor

error_conceal_flag

Specifies the error concealment flag. If an error occurs that prevents the frame from being decoded (e.g. CRC frame error or decoding error), then error concealment is performed. The error concealment strategy fills the output PCM buffers with data repeated from the last block decoded without error until the maximum repeat count is reached. After that, the output buffers are filled with mute data.
  • 0: Disable error concealment
  • 1: Enable error concealment

error_conceal_block_repeats

Maximum repeat count of the error concealment blocks.
  • -1: Always repeat error concealment blocks
  • 0: Lower boarder for repeat count of error concealment blocks
  • 32767: Upper boarder for repeat count of error concealment blocks

use_channel_table

Specifies the channel routing mode.
Value Meaning
0 Use default routing (default)
1 Use the custom channel routing table
2 Use channel routing preset 1
3 Use channel routing preset 2
4 Use channel routing preset 3
5 Use channel routing preset 4
6 Use channel routing preset 5
7 Use channel routing preset 6

custom_channel_table

Specifies the custom channel routing mode. There are eight channel routing presets and a custom routing mode. The presets are:
Preset 1 2 3 4 5 6 7 8
mode 1 L R Ls Rs C LFE Ext1 Ext2
mode 2 L C R Ls Rs LFE Ext1 Ext2
mode 3 L Ls C Rs R LFE Ext1 Ext2
mode 4 L R C LFE Ls Rs Ext1 Ext2
mode 5 L C Rs R Ls LFE Ext1 Ext2
mode 6 C L R Ls Rs LFE Ext1 Ext2
The custom routing mode can be used to route arbitrary input channels (1 .. 8) to arbitrary output channels (L, C, R, Ls, Rs, LFE, X1, X2). The channel_table slots are defined as follows:
Value Meaning
channel_table[0] Left
channel_table[1] Center
channel_table[2] Right
channel_table[3] Left surround
channel_table[4] Right surround
channel_table[5] Subwoofer/LFE
channel_table[6] Left rear surround
channel_table[7] Right rear surround

use_downmix_table

Indicates whether the downmix_table field should be used or not.
  • 0: Do not use custom table
  • 1: Use custom table

downmix_table

Pointer to a custom downmix table. Use the table to specify custom downmix values. Each value is a level from -1.0 to 1.0. The table is represented in the following form:
LL LC LR LLs LRs LLfe LExt1 LExt2
CL CC CR CLs CRs CLfe CExt1 CExt2
RL RC RR RLs RRs RLfe RExt1 RExt2
LsL LsC LsR LsLs LsRs LsLfe LsExt1 LsExt2
RsL RsC RsR RsLs RsRs RsLfe RsExt1 RsExt2
LfeL LfeC LfeR LfeLs LfeRs LfeLfe LfeExt1 LfeExt2
The left output channel will be constructed as:
left output = LL left input + LC center input + ... + LExt2 Ext2 input
If this table is not used, the Dolby Digital decoder will automatically select an appropriate downmixing strategy for the specified output channel configuration.

evo_hash_flag

Sets Evolution decoder mode.
  • 0: Parse Evolution data, but no calculation for PCM protection
  • 1: Parse Evolution data, and calculate PCM protection (default)

decorrelator_mode

Specifies if decorrelation should be used.
  • 0: Decorrelation off
  • 1: Guided (feed-forward) decorrelation (unsupported)
  • 2: Non-guided (feed-backward) decorrelation