O que a opção de perda de pacotes esperada em libopus (ffmpeg) realmente faz com o arquivo codificado?

1

Estou codificando alguns arquivos no formato opus no ffmpeg usando a configuração de aplicativo VoIP (isso é para pesquisa).

Um dos parâmetros que você pode definir é Perda esperada de pacotes (%). Eu entendo os princípios por trás da perda de pacotes, no entanto, não consigo descobrir o que essa configuração realmente faz com o arquivo resultante, já que não há transmissão ocorrendo.

Qualquer ideia seria apreciada.

    
por Ling979 14.08.2017 / 13:17

1 resposta

1

Quanto mais perda de pacotes você especificar, mais dados de redunidade serão codificados no arquivo para poder lidar com isso.

link

As mentioned FEC, is added in-band by an Opus encoder, but only after being configured to do so. A previous post already discusses all the available options you can set on the encoder, so be sure to check that out if you haven’t already. Here though we’ll discuss some of those options and how they work in combination to make it so the encoder includes FEC data. As stated in the Opus FAQ several conditions must be met before the encoder will add error correction to frames:

  • The feature must be enabled. The “fec” option must be set for a defined format (note, options for codec Opus for Asterisk can be set in in codecs.conf ). This option defaults to “no”, so if you don’t specifically enable it Asterisk will not include FEC data when encoding.
  • The encoder must be told to expect loss. This means an estimated packet loss percentage must also be specified. Setting this shifts the threshold at which the encoder will start to include FEC data. The higher the number the lower the threshold.
  • The codec must be operating in a mode conducive to lower bandwidths. Make sure the maximum bandwidth is set to narrow or medium. This can be achieved by adjusting the “max_bandwidth” option. You can do this either directly by setting the option itself, or indirectly by setting the “max_playback_rate” option to 16khz or less.

Don’t forget to make sure both sides have negotiated for FEC. If everything is properly set up, but one side does not offer FEC (“useinbandfec=yes“) then it will not be enabled.

    
por 14.08.2017 / 14:45

Tags