Wowza Community

How to get transcode audio to be in CBR

I’m streaming to RTP and my receiver requires CBR video and audio. I manage to get a transcoding profile to convert the video to CBR but I can’t find the matching audio setting to convert the audio to CBR.

Here’s what I did to convert to CBR video:

<Name>mainconcept.bit_rate_mode</Name>  
<Value>0</Value>
<Type>Long</Type>

For audio, so far I have:

                <Audio>
                    <Codec>AAC</Codec>
                    <Bitrate>64000</Bitrate>
                </Audio>

I did turn on logAudioEncodingParameters but I don’t see any parameters that indicate how to set mainconcept encoder to use CBR for audio.

Here’s what I get in the access log:

long: channel copy: 0=donothing, 1=copy-left-over-right, 2=copy-right-over-left

mainconcept.channel_copy: 0

long: crc protection: 0=off, 1=on

mainconcept.protect_adts_stream: 0

long: high frequency cut-off

mainconcept.hf_cutoff: 0

long: mpeg version: 6=MPEG2_AAC_AUDIO, 7=MPEG4_AAC_AUDIO, 16=MPEG4_AAC_AUDIO_PSP

mainconcept.mpeg_version: 7

long: variable bitrate mode: 0 = off

mainconcept.vbr: 0

long: temporal noise shaping (tns) algorithm: 0=off, 1=on

mainconcept.tns: 1

long: aac object type

mainconcept.aac_object_type: 2

long: high efficiency: 0=off, 1=HE-v1, 2=HE-v

mainconcept.he: 0

To find which Parameters are available for a given encoding, please add the following Property to the transcoding template using a text editor.

<Property>
    <Name>logVideoEncodingParameters</Name>
    <Value>true</Value>
    <Type>Boolean</Type>
</Property>

Once the encoding that contains the above Property is activated/used, you will see a list of Parameters printed in your log file. Please find an article below for more information and configuration details. Follow the same steps for audio…
https://www.wowza.com/docs/how-to-control-transcoded-video-with-video-encoding-parameters

Note: The Property will be added to the Properties container and the Parameter will be added to the Parameters container when editing your transcoding template.

If you’re using the CPU for transcoding, the Parameter should look like this:

<!-- bit_rate_mode: 0=H264_CBR, 1=H264_CQT, 2=H264_VBR or 3=H264_TQM -->
<Parameter>
 <Name>mainconcept.bit_rate_mode</Name>
 <Value>2</Value>
 <Type>Long</Type>
</Parameter>

I have already done that as can be done from my question. There’s no option for CBR.

Yes, but your setup was just a tad different, still sorry that didn’t fix it. So, upon further internal discussion, we’d need to see a support ticket to run some tests on your receiver and setup.

CBR is mostly for video and it wont be 100% CBR as audio is based on various factors - AAC is really tough - to be 100% CBR then you would need a stream with a fixed bitrate encoder such as MP3 (which we do not encode to ), you could try the HE options to see how well it can keep to the assigned bitrate - but I would be surprised if it moves too much.

We’d be happy to try and look more closely and get you what you need but we require full access to your config and files in a ticket. Thanks.

https://www.wowza.com/support/open-ticket