H264Settings
public struct H264Settings : AWSShape
Undocumented
-
Declaration
Swift
public static var _members: [AWSShapeMember]
-
Adaptive quantization. Allows intra-frame quantizers to vary to improve visual quality.
Declaration
Swift
public let adaptiveQuantization: H264AdaptiveQuantization?
-
Indicates that AFD values will be written into the output stream. If afdSignaling is “auto”, the system will try to preserve the input AFD value (in cases where multiple AFD values are valid). If set to “fixed”, the AFD value will be the value configured in the fixedAfd parameter.
Declaration
Swift
public let afdSignaling: AfdSignaling?
-
Average bitrate in bits/second. Required when the rate control mode is VBR or CBR. Not used for QVBR. In an MS Smooth output group, each output must have a unique value when its bitrate is rounded down to the nearest multiple of 1000.
Declaration
Swift
public let bitrate: Int?
-
Percentage of the buffer that should initially be filled (HRD buffer model).
Declaration
Swift
public let bufFillPct: Int?
-
Size of buffer (HRD buffer model) in bits.
Declaration
Swift
public let bufSize: Int?
-
Includes colorspace metadata in the output.
Declaration
Swift
public let colorMetadata: H264ColorMetadata?
-
Color Space settings
Declaration
Swift
public let colorSpaceSettings: H264ColorSpaceSettings?
-
Entropy encoding mode. Use cabac (must be in Main or High profile) or cavlc.
Declaration
Swift
public let entropyEncoding: H264EntropyEncoding?
-
Optional filters that you can apply to an encode.
Declaration
Swift
public let filterSettings: H264FilterSettings?
-
Four bit AFD value to write on all frames of video in the output stream. Only valid when afdSignaling is set to ‘Fixed’.
Declaration
Swift
public let fixedAfd: FixedAfd?
-
If set to enabled, adjust quantization within each frame to reduce flicker or ‘pop’ on I-frames.
Declaration
Swift
public let flickerAq: H264FlickerAq?
-
This setting applies only when scan type is “interlaced.” It controls whether coding is performed on a field basis or on a frame basis. (When the video is progressive, the coding is always performed on a frame basis.) enabled: Force MediaLive to code on a field basis, so that odd and even sets of fields are coded separately. disabled: Code the two sets of fields separately (on a field basis) or together (on a frame basis using PAFF), depending on what is most appropriate for the content.
Declaration
Swift
public let forceFieldPictures: H264ForceFieldPictures?
-
This field indicates how the output video frame rate is specified. If “specified” is selected then the output video frame rate is determined by framerateNumerator and framerateDenominator, else if “initializeFromSource” is selected then the output video frame rate will be set equal to the input video frame rate of the first input.
Declaration
Swift
public let framerateControl: H264FramerateControl?
-
Framerate denominator.
Declaration
Swift
public let framerateDenominator: Int?
-
Framerate numerator - framerate is a fraction, e.g. 24000 / 1001 = 23.976 fps.
Declaration
Swift
public let framerateNumerator: Int?
-
If enabled, use reference B frames for GOP structures that have B frames > 1.
Declaration
Swift
public let gopBReference: H264GopBReference?
-
Frequency of closed GOPs. In streaming applications, it is recommended that this be set to 1 so a decoder joining mid-stream will receive an IDR frame as quickly as possible. Setting this value to 0 will break output segmenting.
Declaration
Swift
public let gopClosedCadence: Int?
-
Number of B-frames between reference frames.
Declaration
Swift
public let gopNumBFrames: Int?
-
GOP size (keyframe interval) in units of either frames or seconds per gopSizeUnits. If gopSizeUnits is frames, gopSize must be an integer and must be greater than or equal to 1. If gopSizeUnits is seconds, gopSize must be greater than 0, but need not be an integer.
Declaration
Swift
public let gopSize: Double?
-
Indicates if the gopSize is specified in frames or seconds. If seconds the system will convert the gopSize into a frame count at run time.
Declaration
Swift
public let gopSizeUnits: H264GopSizeUnits?
-
H.264 Level.
Declaration
Swift
public let level: H264Level?
-
Amount of lookahead. A value of low can decrease latency and memory usage, while high can produce better quality for certain content.
Declaration
Swift
public let lookAheadRateControl: H264LookAheadRateControl?
-
For QVBR: See the tooltip for Quality level For VBR: Set the maximum bitrate in order to accommodate expected spikes in the complexity of the video.
Declaration
Swift
public let maxBitrate: Int?
-
Only meaningful if sceneChangeDetect is set to enabled. Defaults to 5 if multiplex rate control is used. Enforces separation between repeated (cadence) I-frames and I-frames inserted by Scene Change Detection. If a scene change I-frame is within I-interval frames of a cadence I-frame, the GOP is shrunk and/or stretched to the scene change I-frame. GOP stretch requires enabling lookahead as well as setting I-interval. The normal cadence resumes for the next GOP. Note: Maximum GOP stretch = GOP size + Min-I-interval - 1
Declaration
Swift
public let minIInterval: Int?
-
Number of reference frames to use. The encoder may use more than requested if using B-frames and/or interlaced encoding.
Declaration
Swift
public let numRefFrames: Int?
-
This field indicates how the output pixel aspect ratio is specified. If “specified” is selected then the output video pixel aspect ratio is determined by parNumerator and parDenominator, else if “initializeFromSource” is selected then the output pixsel aspect ratio will be set equal to the input video pixel aspect ratio of the first input.
Declaration
Swift
public let parControl: H264ParControl?
-
Pixel Aspect Ratio denominator.
Declaration
Swift
public let parDenominator: Int?
-
Pixel Aspect Ratio numerator.
Declaration
Swift
public let parNumerator: Int?
-
H.264 Profile.
Declaration
Swift
public let profile: H264Profile?
-
Leave as STANDARD_QUALITY or choose a different value (which might result in additional costs to run the channel).
- ENHANCED_QUALITY: Produces a slightly better video quality without an increase in the bitrate. Has an effect only when the Rate control mode is QVBR or CBR. If this channel is in a MediaLive multiplex, the value must be ENHANCED_QUALITY.
- STANDARD_QUALITY: Valid for any Rate control mode.
Declaration
Swift
public let qualityLevel: H264QualityLevel?
-
Controls the target quality for the video encode. Applies only when the rate control mode is QVBR. Set values for the QVBR quality level field and Max bitrate field that suit your most important viewing devices. Recommended values are:
- Primary screen: Quality level: 8 to 10. Max bitrate: 4M
- PC or tablet: Quality level: 7. Max bitrate: 1.5M to 3M
- Smartphone: Quality level: 6. Max bitrate: 1M to 1.5M
Declaration
Swift
public let qvbrQualityLevel: Int?
-
Rate control mode. QVBR: Quality will match the specified quality level except when it is constrained by the maximum bitrate. Recommended if you or your viewers pay for bandwidth. VBR: Quality and bitrate vary, depending on the video complexity. Recommended instead of QVBR if you want to maintain a specific average bitrate over the duration of the channel. CBR: Quality varies, depending on the video complexity. Recommended only if you distribute your assets to devices that cannot handle variable bitrates. Multiplex: This rate control mode is only supported (and is required) when the video is being delivered to a MediaLive Multiplex in which case the rate control configuration is controlled by the properties within the Multiplex Program.
Declaration
Swift
public let rateControlMode: H264RateControlMode?
-
Sets the scan type of the output to progressive or top-field-first interlaced.
Declaration
Swift
public let scanType: H264ScanType?
-
Scene change detection.
- On: inserts I-frames when scene change is detected.
- Off: does not force an I-frame when scene change is detected.
Declaration
Swift
public let sceneChangeDetect: H264SceneChangeDetect?
-
Number of slices per picture. Must be less than or equal to the number of macroblock rows for progressive pictures, and less than or equal to half the number of macroblock rows for interlaced pictures. This field is optional; when no value is specified the encoder will choose the number of slices based on encode resolution.
Declaration
Swift
public let slices: Int?
-
Softness. Selects quantizer matrix, larger values reduce high-frequency content in the encoded image.
Declaration
Swift
public let softness: Int?
-
If set to enabled, adjust quantization within each frame based on spatial variation of content complexity.
Declaration
Swift
public let spatialAq: H264SpatialAq?
-
If set to fixed, use gopNumBFrames B-frames per sub-GOP. If set to dynamic, optimize the number of B-frames used for each sub-GOP to improve visual quality.
Declaration
Swift
public let subgopLength: H264SubGopLength?
-
Produces a bitstream compliant with SMPTE RP-2027.
Declaration
Swift
public let syntax: H264Syntax?
-
If set to enabled, adjust quantization within each frame based on temporal variation of content complexity.
Declaration
Swift
public let temporalAq: H264TemporalAq?
-
Determines how timecodes should be inserted into the video elementary stream.
- ‘disabled’: Do not include timecodes
- ‘picTimingSei’: Pass through picture timing SEI messages from the source specified in Timecode Config
Declaration
Swift
public let timecodeInsertion: H264TimecodeInsertionBehavior?
-
init(adaptiveQuantization:afdSignaling:bitrate:bufFillPct:bufSize:colorMetadata:colorSpaceSettings:entropyEncoding:filterSettings:fixedAfd:flickerAq:forceFieldPictures:framerateControl:framerateDenominator:framerateNumerator:gopBReference:gopClosedCadence:gopNumBFrames:gopSize:gopSizeUnits:level:lookAheadRateControl:maxBitrate:minIInterval:numRefFrames:parControl:parDenominator:parNumerator:profile:qualityLevel:qvbrQualityLevel:rateControlMode:scanType:sceneChangeDetect:slices:softness:spatialAq:subgopLength:syntax:temporalAq:timecodeInsertion:)
Undocumented
Declaration
Swift
public init(adaptiveQuantization: H264AdaptiveQuantization? = nil, afdSignaling: AfdSignaling? = nil, bitrate: Int? = nil, bufFillPct: Int? = nil, bufSize: Int? = nil, colorMetadata: H264ColorMetadata? = nil, colorSpaceSettings: H264ColorSpaceSettings? = nil, entropyEncoding: H264EntropyEncoding? = nil, filterSettings: H264FilterSettings? = nil, fixedAfd: FixedAfd? = nil, flickerAq: H264FlickerAq? = nil, forceFieldPictures: H264ForceFieldPictures? = nil, framerateControl: H264FramerateControl? = nil, framerateDenominator: Int? = nil, framerateNumerator: Int? = nil, gopBReference: H264GopBReference? = nil, gopClosedCadence: Int? = nil, gopNumBFrames: Int? = nil, gopSize: Double? = nil, gopSizeUnits: H264GopSizeUnits? = nil, level: H264Level? = nil, lookAheadRateControl: H264LookAheadRateControl? = nil, maxBitrate: Int? = nil, minIInterval: Int? = nil, numRefFrames: Int? = nil, parControl: H264ParControl? = nil, parDenominator: Int? = nil, parNumerator: Int? = nil, profile: H264Profile? = nil, qualityLevel: H264QualityLevel? = nil, qvbrQualityLevel: Int? = nil, rateControlMode: H264RateControlMode? = nil, scanType: H264ScanType? = nil, sceneChangeDetect: H264SceneChangeDetect? = nil, slices: Int? = nil, softness: Int? = nil, spatialAq: H264SpatialAq? = nil, subgopLength: H264SubGopLength? = nil, syntax: H264Syntax? = nil, temporalAq: H264TemporalAq? = nil, timecodeInsertion: H264TimecodeInsertionBehavior? = nil)
-
Declaration
Swift
public func validate(name: String) throws