AacSettingsProps

class aws_cdk.aws_medialive_alpha.AacSettingsProps(*, bitrate=None, coding_mode=None, input_type=None, profile=None, rate_control_mode=None, raw_format=None, sample_rate=None, spec=None, vbr_quality=None)

Bases: object

(experimental) Properties for AAC codec settings.

Parameters:
  • bitrate (Optional[Bitrate]) – (experimental) The average bitrate. Default: Bitrate.kbps(192)

  • coding_mode (Optional[AacCodingMode]) – (experimental) The coding mode (mono, stereo, 5.1). Default: AacCodingMode.CODING_MODE_2_0

  • input_type (Optional[AacInputType]) – (experimental) Set to broadcasterMixedAd when the input contains pre-mixed main audio + AD (narration) as a stereo pair. Default: AacInputType.NORMAL

  • profile (Optional[AacProfile]) – (experimental) The AAC profile. Default: AacProfile.LC

  • rate_control_mode (Optional[AacRateControlMode]) – (experimental) The rate control mode. Default: AacRateControlMode.CBR

  • raw_format (Optional[AacRawFormat]) – (experimental) Sets the LATM/LOAS AAC output for raw containers. Default: AacRawFormat.NONE

  • sample_rate (Optional[AudioSampleRate]) – (experimental) The sample rate. Default: AudioSampleRate.HZ_48000

  • spec (Optional[AacSpec]) – (experimental) The AAC specification (MPEG-4 or MPEG-2) used to encode the audio. Set to AacSpec.MPEG2 to emit MPEG-2 AAC instead of MPEG-4 AAC for raw or MPEG-2 Transport Stream containers. Default: AacSpec.MPEG4

  • vbr_quality (Optional[AacVbrQuality]) – (experimental) The VBR quality level. Used only if rateControlMode is VBR. Default: - service default

Stability:

experimental

ExampleMetadata:

infused

Example:

# stack: Stack
# input: medialive.IInput
# bucket: s3.IBucket


video = medialive.EncodeConfiguration.video(
    name="video_720p",
    codec=medialive.VideoCodecSettings.h264(
        rate_control=medialive.H264RateControl.cbr(bitrate=Bitrate.mbps(3)),
        framerate=medialive.Framerate.FPS_30
    ),
    width=1280,
    height=720
)

audio = medialive.EncodeConfiguration.audio(
    name="audio_aac",
    codec=medialive.AudioCodecSettings.aac(bitrate=Bitrate.kbps(192))
)

medialive.Channel(stack, "Channel",
    inputs=[medialive.InputAttachment(input=input)],
    output_groups=[
        medialive.OutputGroupConfiguration.hls(
            name="hls",
            destinations=[medialive.OutputDestination.to_bucket(bucket, "live/stream")],
            outputs=[medialive.HlsOutputDefinition(encodes=[video, audio], output_name="hls_out")]
        )
    ]
)

Attributes

bitrate

(experimental) The average bitrate.

Default:

Bitrate.kbps(192)

Stability:

experimental

coding_mode

(experimental) The coding mode (mono, stereo, 5.1).

Default:

AacCodingMode.CODING_MODE_2_0

Stability:

experimental

input_type

(experimental) Set to broadcasterMixedAd when the input contains pre-mixed main audio + AD (narration) as a stereo pair.

Default:

AacInputType.NORMAL

Stability:

experimental

profile

(experimental) The AAC profile.

Default:

AacProfile.LC

Stability:

experimental

rate_control_mode

(experimental) The rate control mode.

Default:

AacRateControlMode.CBR

Stability:

experimental

raw_format

(experimental) Sets the LATM/LOAS AAC output for raw containers.

Default:

AacRawFormat.NONE

Stability:

experimental

sample_rate

(experimental) The sample rate.

Default:

AudioSampleRate.HZ_48000

Stability:

experimental

spec

(experimental) The AAC specification (MPEG-4 or MPEG-2) used to encode the audio.

Set to AacSpec.MPEG2 to emit MPEG-2 AAC instead of MPEG-4 AAC for raw or MPEG-2 Transport Stream containers.

Default:

AacSpec.MPEG4

Stability:

experimental

vbr_quality

(experimental) The VBR quality level.

Used only if rateControlMode is VBR.

Default:
  • service default

Stability:

experimental