1 /** 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * SPDX-License-Identifier: Apache-2.0. 4 */ 5 6 #pragma once 7 #include <aws/mediaconvert/MediaConvert_EXPORTS.h> 8 #include <aws/mediaconvert/model/AacAudioDescriptionBroadcasterMix.h> 9 #include <aws/mediaconvert/model/AacCodecProfile.h> 10 #include <aws/mediaconvert/model/AacCodingMode.h> 11 #include <aws/mediaconvert/model/AacRateControlMode.h> 12 #include <aws/mediaconvert/model/AacRawFormat.h> 13 #include <aws/mediaconvert/model/AacSpecification.h> 14 #include <aws/mediaconvert/model/AacVbrQuality.h> 15 #include <utility> 16 17 namespace Aws 18 { 19 namespace Utils 20 { 21 namespace Json 22 { 23 class JsonValue; 24 class JsonView; 25 } // namespace Json 26 } // namespace Utils 27 namespace MediaConvert 28 { 29 namespace Model 30 { 31 32 /** 33 * Required when you set (Codec) under (AudioDescriptions)>(CodecSettings) to the 34 * value AAC. The service accepts one of two mutually exclusive groups of AAC 35 * settings--VBR and CBR. To select one of these modes, set the value of Bitrate 36 * control mode (rateControlMode) to "VBR" or "CBR". In VBR mode, you control the 37 * audio quality with the setting VBR quality (vbrQuality). In CBR mode, you use 38 * the setting Bitrate (bitrate). Defaults and valid values depend on the rate 39 * control mode.<p><h3>See Also:</h3> <a 40 * href="http://docs.aws.amazon.com/goto/WebAPI/mediaconvert-2017-08-29/AacSettings">AWS 41 * API Reference</a></p> 42 */ 43 class AWS_MEDIACONVERT_API AacSettings 44 { 45 public: 46 AacSettings(); 47 AacSettings(Aws::Utils::Json::JsonView jsonValue); 48 AacSettings& operator=(Aws::Utils::Json::JsonView jsonValue); 49 Aws::Utils::Json::JsonValue Jsonize() const; 50 51 52 /** 53 * Choose BROADCASTER_MIXED_AD when the input contains pre-mixed main audio + audio 54 * description (AD) as a stereo pair. The value for AudioType will be set to 3, 55 * which signals to downstream systems that this stream contains "broadcaster mixed 56 * AD". Note that the input received by the encoder must contain pre-mixed audio; 57 * the encoder does not perform the mixing. When you choose BROADCASTER_MIXED_AD, 58 * the encoder ignores any values you provide in AudioType and 59 * FollowInputAudioType. Choose NORMAL when the input does not contain pre-mixed 60 * audio + audio description (AD). In this case, the encoder will use any values 61 * you provide for AudioType and FollowInputAudioType. 62 */ GetAudioDescriptionBroadcasterMix()63 inline const AacAudioDescriptionBroadcasterMix& GetAudioDescriptionBroadcasterMix() const{ return m_audioDescriptionBroadcasterMix; } 64 65 /** 66 * Choose BROADCASTER_MIXED_AD when the input contains pre-mixed main audio + audio 67 * description (AD) as a stereo pair. The value for AudioType will be set to 3, 68 * which signals to downstream systems that this stream contains "broadcaster mixed 69 * AD". Note that the input received by the encoder must contain pre-mixed audio; 70 * the encoder does not perform the mixing. When you choose BROADCASTER_MIXED_AD, 71 * the encoder ignores any values you provide in AudioType and 72 * FollowInputAudioType. Choose NORMAL when the input does not contain pre-mixed 73 * audio + audio description (AD). In this case, the encoder will use any values 74 * you provide for AudioType and FollowInputAudioType. 75 */ AudioDescriptionBroadcasterMixHasBeenSet()76 inline bool AudioDescriptionBroadcasterMixHasBeenSet() const { return m_audioDescriptionBroadcasterMixHasBeenSet; } 77 78 /** 79 * Choose BROADCASTER_MIXED_AD when the input contains pre-mixed main audio + audio 80 * description (AD) as a stereo pair. The value for AudioType will be set to 3, 81 * which signals to downstream systems that this stream contains "broadcaster mixed 82 * AD". Note that the input received by the encoder must contain pre-mixed audio; 83 * the encoder does not perform the mixing. When you choose BROADCASTER_MIXED_AD, 84 * the encoder ignores any values you provide in AudioType and 85 * FollowInputAudioType. Choose NORMAL when the input does not contain pre-mixed 86 * audio + audio description (AD). In this case, the encoder will use any values 87 * you provide for AudioType and FollowInputAudioType. 88 */ SetAudioDescriptionBroadcasterMix(const AacAudioDescriptionBroadcasterMix & value)89 inline void SetAudioDescriptionBroadcasterMix(const AacAudioDescriptionBroadcasterMix& value) { m_audioDescriptionBroadcasterMixHasBeenSet = true; m_audioDescriptionBroadcasterMix = value; } 90 91 /** 92 * Choose BROADCASTER_MIXED_AD when the input contains pre-mixed main audio + audio 93 * description (AD) as a stereo pair. The value for AudioType will be set to 3, 94 * which signals to downstream systems that this stream contains "broadcaster mixed 95 * AD". Note that the input received by the encoder must contain pre-mixed audio; 96 * the encoder does not perform the mixing. When you choose BROADCASTER_MIXED_AD, 97 * the encoder ignores any values you provide in AudioType and 98 * FollowInputAudioType. Choose NORMAL when the input does not contain pre-mixed 99 * audio + audio description (AD). In this case, the encoder will use any values 100 * you provide for AudioType and FollowInputAudioType. 101 */ SetAudioDescriptionBroadcasterMix(AacAudioDescriptionBroadcasterMix && value)102 inline void SetAudioDescriptionBroadcasterMix(AacAudioDescriptionBroadcasterMix&& value) { m_audioDescriptionBroadcasterMixHasBeenSet = true; m_audioDescriptionBroadcasterMix = std::move(value); } 103 104 /** 105 * Choose BROADCASTER_MIXED_AD when the input contains pre-mixed main audio + audio 106 * description (AD) as a stereo pair. The value for AudioType will be set to 3, 107 * which signals to downstream systems that this stream contains "broadcaster mixed 108 * AD". Note that the input received by the encoder must contain pre-mixed audio; 109 * the encoder does not perform the mixing. When you choose BROADCASTER_MIXED_AD, 110 * the encoder ignores any values you provide in AudioType and 111 * FollowInputAudioType. Choose NORMAL when the input does not contain pre-mixed 112 * audio + audio description (AD). In this case, the encoder will use any values 113 * you provide for AudioType and FollowInputAudioType. 114 */ WithAudioDescriptionBroadcasterMix(const AacAudioDescriptionBroadcasterMix & value)115 inline AacSettings& WithAudioDescriptionBroadcasterMix(const AacAudioDescriptionBroadcasterMix& value) { SetAudioDescriptionBroadcasterMix(value); return *this;} 116 117 /** 118 * Choose BROADCASTER_MIXED_AD when the input contains pre-mixed main audio + audio 119 * description (AD) as a stereo pair. The value for AudioType will be set to 3, 120 * which signals to downstream systems that this stream contains "broadcaster mixed 121 * AD". Note that the input received by the encoder must contain pre-mixed audio; 122 * the encoder does not perform the mixing. When you choose BROADCASTER_MIXED_AD, 123 * the encoder ignores any values you provide in AudioType and 124 * FollowInputAudioType. Choose NORMAL when the input does not contain pre-mixed 125 * audio + audio description (AD). In this case, the encoder will use any values 126 * you provide for AudioType and FollowInputAudioType. 127 */ WithAudioDescriptionBroadcasterMix(AacAudioDescriptionBroadcasterMix && value)128 inline AacSettings& WithAudioDescriptionBroadcasterMix(AacAudioDescriptionBroadcasterMix&& value) { SetAudioDescriptionBroadcasterMix(std::move(value)); return *this;} 129 130 131 /** 132 * Specify the average bitrate in bits per second. The set of valid values for this 133 * setting is: 6000, 8000, 10000, 12000, 14000, 16000, 20000, 24000, 28000, 32000, 134 * 40000, 48000, 56000, 64000, 80000, 96000, 112000, 128000, 160000, 192000, 135 * 224000, 256000, 288000, 320000, 384000, 448000, 512000, 576000, 640000, 768000, 136 * 896000, 1024000. The value you set is also constrained by the values that you 137 * choose for Profile (codecProfile), Bitrate control mode (codingMode), and Sample 138 * rate (sampleRate). Default values depend on Bitrate control mode and Profile. 139 */ GetBitrate()140 inline int GetBitrate() const{ return m_bitrate; } 141 142 /** 143 * Specify the average bitrate in bits per second. The set of valid values for this 144 * setting is: 6000, 8000, 10000, 12000, 14000, 16000, 20000, 24000, 28000, 32000, 145 * 40000, 48000, 56000, 64000, 80000, 96000, 112000, 128000, 160000, 192000, 146 * 224000, 256000, 288000, 320000, 384000, 448000, 512000, 576000, 640000, 768000, 147 * 896000, 1024000. The value you set is also constrained by the values that you 148 * choose for Profile (codecProfile), Bitrate control mode (codingMode), and Sample 149 * rate (sampleRate). Default values depend on Bitrate control mode and Profile. 150 */ BitrateHasBeenSet()151 inline bool BitrateHasBeenSet() const { return m_bitrateHasBeenSet; } 152 153 /** 154 * Specify the average bitrate in bits per second. The set of valid values for this 155 * setting is: 6000, 8000, 10000, 12000, 14000, 16000, 20000, 24000, 28000, 32000, 156 * 40000, 48000, 56000, 64000, 80000, 96000, 112000, 128000, 160000, 192000, 157 * 224000, 256000, 288000, 320000, 384000, 448000, 512000, 576000, 640000, 768000, 158 * 896000, 1024000. The value you set is also constrained by the values that you 159 * choose for Profile (codecProfile), Bitrate control mode (codingMode), and Sample 160 * rate (sampleRate). Default values depend on Bitrate control mode and Profile. 161 */ SetBitrate(int value)162 inline void SetBitrate(int value) { m_bitrateHasBeenSet = true; m_bitrate = value; } 163 164 /** 165 * Specify the average bitrate in bits per second. The set of valid values for this 166 * setting is: 6000, 8000, 10000, 12000, 14000, 16000, 20000, 24000, 28000, 32000, 167 * 40000, 48000, 56000, 64000, 80000, 96000, 112000, 128000, 160000, 192000, 168 * 224000, 256000, 288000, 320000, 384000, 448000, 512000, 576000, 640000, 768000, 169 * 896000, 1024000. The value you set is also constrained by the values that you 170 * choose for Profile (codecProfile), Bitrate control mode (codingMode), and Sample 171 * rate (sampleRate). Default values depend on Bitrate control mode and Profile. 172 */ WithBitrate(int value)173 inline AacSettings& WithBitrate(int value) { SetBitrate(value); return *this;} 174 175 176 /** 177 * AAC Profile. 178 */ GetCodecProfile()179 inline const AacCodecProfile& GetCodecProfile() const{ return m_codecProfile; } 180 181 /** 182 * AAC Profile. 183 */ CodecProfileHasBeenSet()184 inline bool CodecProfileHasBeenSet() const { return m_codecProfileHasBeenSet; } 185 186 /** 187 * AAC Profile. 188 */ SetCodecProfile(const AacCodecProfile & value)189 inline void SetCodecProfile(const AacCodecProfile& value) { m_codecProfileHasBeenSet = true; m_codecProfile = value; } 190 191 /** 192 * AAC Profile. 193 */ SetCodecProfile(AacCodecProfile && value)194 inline void SetCodecProfile(AacCodecProfile&& value) { m_codecProfileHasBeenSet = true; m_codecProfile = std::move(value); } 195 196 /** 197 * AAC Profile. 198 */ WithCodecProfile(const AacCodecProfile & value)199 inline AacSettings& WithCodecProfile(const AacCodecProfile& value) { SetCodecProfile(value); return *this;} 200 201 /** 202 * AAC Profile. 203 */ WithCodecProfile(AacCodecProfile && value)204 inline AacSettings& WithCodecProfile(AacCodecProfile&& value) { SetCodecProfile(std::move(value)); return *this;} 205 206 207 /** 208 * Mono (Audio Description), Mono, Stereo, or 5.1 channel layout. Valid values 209 * depend on rate control mode and profile. "1.0 - Audio Description (Receiver 210 * Mix)" setting receives a stereo description plus control track and emits a mono 211 * AAC encode of the description track, with control data emitted in the PES header 212 * as per ETSI TS 101 154 Annex E. 213 */ GetCodingMode()214 inline const AacCodingMode& GetCodingMode() const{ return m_codingMode; } 215 216 /** 217 * Mono (Audio Description), Mono, Stereo, or 5.1 channel layout. Valid values 218 * depend on rate control mode and profile. "1.0 - Audio Description (Receiver 219 * Mix)" setting receives a stereo description plus control track and emits a mono 220 * AAC encode of the description track, with control data emitted in the PES header 221 * as per ETSI TS 101 154 Annex E. 222 */ CodingModeHasBeenSet()223 inline bool CodingModeHasBeenSet() const { return m_codingModeHasBeenSet; } 224 225 /** 226 * Mono (Audio Description), Mono, Stereo, or 5.1 channel layout. Valid values 227 * depend on rate control mode and profile. "1.0 - Audio Description (Receiver 228 * Mix)" setting receives a stereo description plus control track and emits a mono 229 * AAC encode of the description track, with control data emitted in the PES header 230 * as per ETSI TS 101 154 Annex E. 231 */ SetCodingMode(const AacCodingMode & value)232 inline void SetCodingMode(const AacCodingMode& value) { m_codingModeHasBeenSet = true; m_codingMode = value; } 233 234 /** 235 * Mono (Audio Description), Mono, Stereo, or 5.1 channel layout. Valid values 236 * depend on rate control mode and profile. "1.0 - Audio Description (Receiver 237 * Mix)" setting receives a stereo description plus control track and emits a mono 238 * AAC encode of the description track, with control data emitted in the PES header 239 * as per ETSI TS 101 154 Annex E. 240 */ SetCodingMode(AacCodingMode && value)241 inline void SetCodingMode(AacCodingMode&& value) { m_codingModeHasBeenSet = true; m_codingMode = std::move(value); } 242 243 /** 244 * Mono (Audio Description), Mono, Stereo, or 5.1 channel layout. Valid values 245 * depend on rate control mode and profile. "1.0 - Audio Description (Receiver 246 * Mix)" setting receives a stereo description plus control track and emits a mono 247 * AAC encode of the description track, with control data emitted in the PES header 248 * as per ETSI TS 101 154 Annex E. 249 */ WithCodingMode(const AacCodingMode & value)250 inline AacSettings& WithCodingMode(const AacCodingMode& value) { SetCodingMode(value); return *this;} 251 252 /** 253 * Mono (Audio Description), Mono, Stereo, or 5.1 channel layout. Valid values 254 * depend on rate control mode and profile. "1.0 - Audio Description (Receiver 255 * Mix)" setting receives a stereo description plus control track and emits a mono 256 * AAC encode of the description track, with control data emitted in the PES header 257 * as per ETSI TS 101 154 Annex E. 258 */ WithCodingMode(AacCodingMode && value)259 inline AacSettings& WithCodingMode(AacCodingMode&& value) { SetCodingMode(std::move(value)); return *this;} 260 261 262 /** 263 * Rate Control Mode. 264 */ GetRateControlMode()265 inline const AacRateControlMode& GetRateControlMode() const{ return m_rateControlMode; } 266 267 /** 268 * Rate Control Mode. 269 */ RateControlModeHasBeenSet()270 inline bool RateControlModeHasBeenSet() const { return m_rateControlModeHasBeenSet; } 271 272 /** 273 * Rate Control Mode. 274 */ SetRateControlMode(const AacRateControlMode & value)275 inline void SetRateControlMode(const AacRateControlMode& value) { m_rateControlModeHasBeenSet = true; m_rateControlMode = value; } 276 277 /** 278 * Rate Control Mode. 279 */ SetRateControlMode(AacRateControlMode && value)280 inline void SetRateControlMode(AacRateControlMode&& value) { m_rateControlModeHasBeenSet = true; m_rateControlMode = std::move(value); } 281 282 /** 283 * Rate Control Mode. 284 */ WithRateControlMode(const AacRateControlMode & value)285 inline AacSettings& WithRateControlMode(const AacRateControlMode& value) { SetRateControlMode(value); return *this;} 286 287 /** 288 * Rate Control Mode. 289 */ WithRateControlMode(AacRateControlMode && value)290 inline AacSettings& WithRateControlMode(AacRateControlMode&& value) { SetRateControlMode(std::move(value)); return *this;} 291 292 293 /** 294 * Enables LATM/LOAS AAC output. Note that if you use LATM/LOAS AAC in an output, 295 * you must choose "No container" for the output container. 296 */ GetRawFormat()297 inline const AacRawFormat& GetRawFormat() const{ return m_rawFormat; } 298 299 /** 300 * Enables LATM/LOAS AAC output. Note that if you use LATM/LOAS AAC in an output, 301 * you must choose "No container" for the output container. 302 */ RawFormatHasBeenSet()303 inline bool RawFormatHasBeenSet() const { return m_rawFormatHasBeenSet; } 304 305 /** 306 * Enables LATM/LOAS AAC output. Note that if you use LATM/LOAS AAC in an output, 307 * you must choose "No container" for the output container. 308 */ SetRawFormat(const AacRawFormat & value)309 inline void SetRawFormat(const AacRawFormat& value) { m_rawFormatHasBeenSet = true; m_rawFormat = value; } 310 311 /** 312 * Enables LATM/LOAS AAC output. Note that if you use LATM/LOAS AAC in an output, 313 * you must choose "No container" for the output container. 314 */ SetRawFormat(AacRawFormat && value)315 inline void SetRawFormat(AacRawFormat&& value) { m_rawFormatHasBeenSet = true; m_rawFormat = std::move(value); } 316 317 /** 318 * Enables LATM/LOAS AAC output. Note that if you use LATM/LOAS AAC in an output, 319 * you must choose "No container" for the output container. 320 */ WithRawFormat(const AacRawFormat & value)321 inline AacSettings& WithRawFormat(const AacRawFormat& value) { SetRawFormat(value); return *this;} 322 323 /** 324 * Enables LATM/LOAS AAC output. Note that if you use LATM/LOAS AAC in an output, 325 * you must choose "No container" for the output container. 326 */ WithRawFormat(AacRawFormat && value)327 inline AacSettings& WithRawFormat(AacRawFormat&& value) { SetRawFormat(std::move(value)); return *this;} 328 329 330 /** 331 * Sample rate in Hz. Valid values depend on rate control mode and profile. 332 */ GetSampleRate()333 inline int GetSampleRate() const{ return m_sampleRate; } 334 335 /** 336 * Sample rate in Hz. Valid values depend on rate control mode and profile. 337 */ SampleRateHasBeenSet()338 inline bool SampleRateHasBeenSet() const { return m_sampleRateHasBeenSet; } 339 340 /** 341 * Sample rate in Hz. Valid values depend on rate control mode and profile. 342 */ SetSampleRate(int value)343 inline void SetSampleRate(int value) { m_sampleRateHasBeenSet = true; m_sampleRate = value; } 344 345 /** 346 * Sample rate in Hz. Valid values depend on rate control mode and profile. 347 */ WithSampleRate(int value)348 inline AacSettings& WithSampleRate(int value) { SetSampleRate(value); return *this;} 349 350 351 /** 352 * Use MPEG-2 AAC instead of MPEG-4 AAC audio for raw or MPEG-2 Transport Stream 353 * containers. 354 */ GetSpecification()355 inline const AacSpecification& GetSpecification() const{ return m_specification; } 356 357 /** 358 * Use MPEG-2 AAC instead of MPEG-4 AAC audio for raw or MPEG-2 Transport Stream 359 * containers. 360 */ SpecificationHasBeenSet()361 inline bool SpecificationHasBeenSet() const { return m_specificationHasBeenSet; } 362 363 /** 364 * Use MPEG-2 AAC instead of MPEG-4 AAC audio for raw or MPEG-2 Transport Stream 365 * containers. 366 */ SetSpecification(const AacSpecification & value)367 inline void SetSpecification(const AacSpecification& value) { m_specificationHasBeenSet = true; m_specification = value; } 368 369 /** 370 * Use MPEG-2 AAC instead of MPEG-4 AAC audio for raw or MPEG-2 Transport Stream 371 * containers. 372 */ SetSpecification(AacSpecification && value)373 inline void SetSpecification(AacSpecification&& value) { m_specificationHasBeenSet = true; m_specification = std::move(value); } 374 375 /** 376 * Use MPEG-2 AAC instead of MPEG-4 AAC audio for raw or MPEG-2 Transport Stream 377 * containers. 378 */ WithSpecification(const AacSpecification & value)379 inline AacSettings& WithSpecification(const AacSpecification& value) { SetSpecification(value); return *this;} 380 381 /** 382 * Use MPEG-2 AAC instead of MPEG-4 AAC audio for raw or MPEG-2 Transport Stream 383 * containers. 384 */ WithSpecification(AacSpecification && value)385 inline AacSettings& WithSpecification(AacSpecification&& value) { SetSpecification(std::move(value)); return *this;} 386 387 388 /** 389 * VBR Quality Level - Only used if rate_control_mode is VBR. 390 */ GetVbrQuality()391 inline const AacVbrQuality& GetVbrQuality() const{ return m_vbrQuality; } 392 393 /** 394 * VBR Quality Level - Only used if rate_control_mode is VBR. 395 */ VbrQualityHasBeenSet()396 inline bool VbrQualityHasBeenSet() const { return m_vbrQualityHasBeenSet; } 397 398 /** 399 * VBR Quality Level - Only used if rate_control_mode is VBR. 400 */ SetVbrQuality(const AacVbrQuality & value)401 inline void SetVbrQuality(const AacVbrQuality& value) { m_vbrQualityHasBeenSet = true; m_vbrQuality = value; } 402 403 /** 404 * VBR Quality Level - Only used if rate_control_mode is VBR. 405 */ SetVbrQuality(AacVbrQuality && value)406 inline void SetVbrQuality(AacVbrQuality&& value) { m_vbrQualityHasBeenSet = true; m_vbrQuality = std::move(value); } 407 408 /** 409 * VBR Quality Level - Only used if rate_control_mode is VBR. 410 */ WithVbrQuality(const AacVbrQuality & value)411 inline AacSettings& WithVbrQuality(const AacVbrQuality& value) { SetVbrQuality(value); return *this;} 412 413 /** 414 * VBR Quality Level - Only used if rate_control_mode is VBR. 415 */ WithVbrQuality(AacVbrQuality && value)416 inline AacSettings& WithVbrQuality(AacVbrQuality&& value) { SetVbrQuality(std::move(value)); return *this;} 417 418 private: 419 420 AacAudioDescriptionBroadcasterMix m_audioDescriptionBroadcasterMix; 421 bool m_audioDescriptionBroadcasterMixHasBeenSet; 422 423 int m_bitrate; 424 bool m_bitrateHasBeenSet; 425 426 AacCodecProfile m_codecProfile; 427 bool m_codecProfileHasBeenSet; 428 429 AacCodingMode m_codingMode; 430 bool m_codingModeHasBeenSet; 431 432 AacRateControlMode m_rateControlMode; 433 bool m_rateControlModeHasBeenSet; 434 435 AacRawFormat m_rawFormat; 436 bool m_rawFormatHasBeenSet; 437 438 int m_sampleRate; 439 bool m_sampleRateHasBeenSet; 440 441 AacSpecification m_specification; 442 bool m_specificationHasBeenSet; 443 444 AacVbrQuality m_vbrQuality; 445 bool m_vbrQualityHasBeenSet; 446 }; 447 448 } // namespace Model 449 } // namespace MediaConvert 450 } // namespace Aws 451