AWS SDK for .NET Documentation
VideoParameters Class
AmazonAmazon.ElasticTranscoder.ModelVideoParameters Did this page help you?   Yes   No    Tell us about it...
The
CopyC#
VideoParameters
structure.
Declaration Syntax
C#
public class VideoParameters
Members
All MembersConstructorsMethodsProperties



IconMemberDescription
VideoParameters()()()()
Initializes a new instance of the VideoParameters class

AspectRatio
Gets and sets the property AspectRatio.

To better control resolution and aspect ratio of output videos, we recommend that you use the values

CopyC#
MaxWidth
,
CopyC#
MaxHeight
,
CopyC#
SizingPolicy
,
CopyC#
PaddingPolicy
, and
CopyC#
DisplayAspectRatio
instead of
CopyC#
Resolution
and
CopyC#
AspectRatio
. The two groups of settings are mutually exclusive. Do not use them together.

The display aspect ratio of the video in the output file. Valid values include:

CopyC#
auto
,
CopyC#
1:1
,
CopyC#
4:3
,
CopyC#
3:2
,
CopyC#
16:9

If you specify

CopyC#
auto
, Elastic Transcoder tries to preserve the aspect ratio of the input file.

If you specify an aspect ratio for the output file that differs from aspect ratio of the input file, Elastic Transcoder adds pillarboxing (black bars on the sides) or letterboxing (black bars on the top and bottom) to maintain the aspect ratio of the active region of the video.


BitRate
Gets and sets the property BitRate.

The bit rate of the video stream in the output file, in kilobits/second. Valid values depend on the values of

CopyC#
Level
and
CopyC#
Profile
. If you specify
CopyC#
auto
, Elastic Transcoder uses the detected bit rate of the input source. If you specify a value other than
CopyC#
auto
, we recommend that you specify a value less than or equal to the maximum H.264-compliant value listed for your level and profile:

Level - Maximum video bit rate in kilobits/second (baseline and main Profile) : maximum video bit rate in kilobits/second (high Profile)

  • 1 - 64 : 80
  • 1b - 128 : 160
  • 1.1 - 192 : 240
  • 1.2 - 384 : 480
  • 1.3 - 768 : 960
  • 2 - 2000 : 2500
  • 3 - 10000 : 12500
  • 3.1 - 14000 : 17500
  • 3.2 - 20000 : 25000
  • 4 - 20000 : 25000
  • 4.1 - 50000 : 62500

Codec
Gets and sets the property Codec.

The video codec for the output file. Valid values include

CopyC#
H.264
and
CopyC#
vp8
. You can only specify
CopyC#
vp8
when the container type is
CopyC#
webm
.


CodecOptions
Gets and sets the property CodecOptions.

Profile

The H.264 profile that you want to use for the output file. Elastic Transcoder supports the following profiles:

  • CopyC#
    baseline
    : The profile most commonly used for videoconferencing and for mobile applications.
  • CopyC#
    main
    : The profile used for standard-definition digital TV broadcasts.
  • CopyC#
    high
    : The profile used for high-definition digital TV broadcasts and for Blu-ray discs.

Level (H.264 Only)

The H.264 level that you want to use for the output file. Elastic Transcoder supports the following levels:

CopyC#
1
,
CopyC#
1b
,
CopyC#
1.1
,
CopyC#
1.2
,
CopyC#
1.3
,
CopyC#
2
,
CopyC#
2.1
,
CopyC#
2.2
,
CopyC#
3
,
CopyC#
3.1
,
CopyC#
3.2
,
CopyC#
4
,
CopyC#
4.1

MaxReferenceFrames (H.264 Only)

Applicable only when the value of Video:Codec is H.264. The maximum number of previously decoded frames to use as a reference for decoding future frames. Valid values are integers 0 through 16, but we recommend that you not use a value greater than the following:

CopyC#
Min(Floor(Maximum decoded picture buffer in macroblocks * 256 /
            (Width in pixels *                Height in pixels)), 16)

where Width in pixels and Height in pixels represent either MaxWidth and MaxHeight, or Resolution. Maximum decoded picture buffer in macroblocks depends on the value of the

CopyC#
Level
object. See the list below. (A macroblock is a block of pixels measuring 16x16.)

  • 1 - 396
  • 1b - 396
  • 1.1 - 900
  • 1.2 - 2376
  • 1.3 - 2376
  • 2 - 2376
  • 2.1 - 4752
  • 2.2 - 8100
  • 3 - 8100
  • 3.1 - 18000
  • 3.2 - 20480
  • 4 - 32768
  • 4.1 - 32768

MaxBitRate

The maximum number of bits per second in a video buffer; the size of the buffer is specified by

CopyC#
BufferSize
. Specify a value between 16 and 62,500. You can reduce the bandwidth required to stream a video by reducing the maximum bit rate, but this also reduces the quality of the video.

BufferSize

The maximum number of bits in any x seconds of the output video. This window is commonly 10 seconds, the standard segment duration when you're using MPEG-TS for the container type of the output video. Specify an integer greater than 0. If you specify

CopyC#
MaxBitRate
and omit
CopyC#
BufferSize
, Elastic Transcoder sets
CopyC#
BufferSize
to 10 times the value of
CopyC#
MaxBitRate
.


DisplayAspectRatio
Gets and sets the property DisplayAspectRatio.

The value that Elastic Transcoder adds to the metadata in the output file.


Equals(Object)
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
FixedGOP
Gets and sets the property FixedGOP.

Whether to use a fixed value for

CopyC#
FixedGOP
. Valid values are
CopyC#
true
and
CopyC#
false
:

  • CopyC#
    true
    : Elastic Transcoder uses the value of
    CopyC#
    KeyframesMaxDist
    for the distance between key frames (the number of frames in a group of pictures, or GOP).
  • CopyC#
    false
    : The distance between key frames can vary.

FrameRate
Gets and sets the property FrameRate.

The frames per second for the video stream in the output file. Valid values include:

CopyC#
auto
,
CopyC#
10
,
CopyC#
15
,
CopyC#
23.97
,
CopyC#
24
,
CopyC#
25
,
CopyC#
29.97
,
CopyC#
30
,
CopyC#
60

If you specify

CopyC#
auto
, Elastic Transcoder uses the detected frame rate of the input source. If you specify a frame rate, we recommend that you perform the following calculation:

CopyC#
Frame rate = maximum recommended decoding speed in luma samples/second
            / (width in                pixels * height in pixels)

where:

  • width in pixels and height in pixels represent the Resolution of the output video.
  • maximum recommended decoding speed in Luma samples/second is less than or equal to the maximum value listed in the following table, based on the value that you specified for Level.

The maximum recommended decoding speed in Luma samples/second for each level is described in the following list (Level - Decoding speed):

  • 1 - 380160
  • 1b - 380160
  • 1.1 - 76800
  • 1.2 - 1536000
  • 1.3 - 3041280
  • 2 - 3041280
  • 2.1 - 5068800
  • 2.2 - 5184000
  • 3 - 10368000
  • 3.1 - 27648000
  • 3.2 - 55296000
  • 4 - 62914560
  • 4.1 - 62914560

GetHashCode()()()()
Serves as a hash function for a particular type.
(Inherited from Object.)
GetType()()()()
Gets the type of the current instance.
(Inherited from Object.)
KeyframesMaxDist
Gets and sets the property KeyframesMaxDist.

The maximum number of frames between key frames. Key frames are fully encoded frames; the frames between key frames are encoded based, in part, on the content of the key frames. The value is an integer formatted as a string; valid values are between 1 (every frame is a key frame) and 100000, inclusive. A higher value results in higher compression but may also discernibly decrease video quality.


MaxFrameRate
Gets and sets the property MaxFrameRate.

If you specify

CopyC#
auto
for
CopyC#
FrameRate
, Elastic Transcoder uses the frame rate of the input video for the frame rate of the output video. Specify the maximum frame rate that you want Elastic Transcoder to use when the frame rate of the input video is greater than the desired maximum frame rate of the output video. Valid values include:
CopyC#
10
,
CopyC#
15
,
CopyC#
23.97
,
CopyC#
24
,
CopyC#
25
,
CopyC#
29.97
,
CopyC#
30
,
CopyC#
60
.


MaxHeight
Gets and sets the property MaxHeight.

The maximum height of the output video in pixels. If you specify

CopyC#
auto
, Elastic Transcoder uses 1080 (Full HD) as the default value. If you specify a numeric value, enter an even integer between 96 and 3072.


MaxWidth
Gets and sets the property MaxWidth.

The maximum width of the output video in pixels. If you specify

CopyC#
auto
, Elastic Transcoder uses 1920 (Full HD) as the default value. If you specify a numeric value, enter an even integer between 128 and 4096.


PaddingPolicy
Gets and sets the property PaddingPolicy.

When you set

CopyC#
PaddingPolicy
to
CopyC#
Pad
, Elastic Transcoder may add black bars to the top and bottom and/or left and right sides of the output video to make the total size of the output video match the values that you specified for
CopyC#
MaxWidth
and
CopyC#
MaxHeight
.


Resolution
Gets and sets the property Resolution.

To better control resolution and aspect ratio of output videos, we recommend that you use the values

CopyC#
MaxWidth
,
CopyC#
MaxHeight
,
CopyC#
SizingPolicy
,
CopyC#
PaddingPolicy
, and
CopyC#
DisplayAspectRatio
instead of
CopyC#
Resolution
and
CopyC#
AspectRatio
. The two groups of settings are mutually exclusive. Do not use them together.

The width and height of the video in the output file, in pixels. Valid values are

CopyC#
auto
and width x height:

  • CopyC#
    auto
    : Elastic Transcoder attempts to preserve the width and height of the input file, subject to the following rules.
  • CopyC#
    <i>width</i> x <i>height</i>
    : The width and height of the output video in pixels.

Note the following about specifying the width and height:

  • The width must be an even integer between 128 and 4096, inclusive.
  • The height must be an even integer between 96 and 3072, inclusive.
  • If you specify a resolution that is less than the resolution of the input file, Elastic Transcoder rescales the output file to the lower resolution.
  • If you specify a resolution that is greater than the resolution of the input file, Elastic Transcoder rescales the output to the higher resolution.
  • We recommend that you specify a resolution for which the product of width and height is less than or equal to the applicable value in the following list (List - Max width x height value):
    • 1 - 25344
    • 1b - 25344
    • 1.1 - 101376
    • 1.2 - 101376
    • 1.3 - 101376
    • 2 - 101376
    • 2.1 - 202752
    • 2.2 - 404720
    • 3 - 404720
    • 3.1 - 921600
    • 3.2 - 1310720
    • 4 - 2097152
    • 4.1 - 2097152

SizingPolicy
Gets and sets the property SizingPolicy.

Specify one of the following values to control scaling of the output video:

  • CopyC#
    Fit
    : Elastic Transcoder scales the output video so it matches the value that you specified in either
    CopyC#
    MaxWidth
    or
    CopyC#
    MaxHeight
    without exceeding the other value.
  • CopyC#
    Fill
    : Elastic Transcoder scales the output video so it matches the value that you specified in either
    CopyC#
    MaxWidth
    or
    CopyC#
    MaxHeight
    and matches or exceeds the other value. Elastic Transcoder centers the output video and then crops it in the dimension (if any) that exceeds the maximum value.
  • CopyC#
    Stretch
    : Elastic Transcoder stretches the output video to match the values that you specified for
    CopyC#
    MaxWidth
    and
    CopyC#
    MaxHeight
    . If the relative proportions of the input video and the output video are different, the output video will be distorted.
  • CopyC#
    Keep
    : Elastic Transcoder does not scale the output video. If either dimension of the input video exceeds the values that you specified for
    CopyC#
    MaxWidth
    and
    CopyC#
    MaxHeight
    , Elastic Transcoder crops the output video.
  • CopyC#
    ShrinkToFit
    : Elastic Transcoder scales the output video down so that its dimensions match the values that you specified for at least one of
    CopyC#
    MaxWidth
    and
    CopyC#
    MaxHeight
    without exceeding either value. If you specify this option, Elastic Transcoder does not scale the video up.
  • CopyC#
    ShrinkToFill
    : Elastic Transcoder scales the output video down so that its dimensions match the values that you specified for at least one of
    CopyC#
    MaxWidth
    and
    CopyC#
    MaxHeight
    without dropping below either value. If you specify this option, Elastic Transcoder does not scale the video up.


ToString()()()()
Returns a string that represents the current object.
(Inherited from Object.)
Watermarks
Gets and sets the property Watermarks.

Settings for the size, location, and opacity of graphics that you want Elastic Transcoder to overlay over videos that are transcoded using this preset. You can specify settings for up to four watermarks. Watermarks appear in the specified size and location, and with the specified opacity for the duration of the transcoded video.

Watermarks can be in .png or .jpg format. If you want to display a watermark that is not rectangular, use the .png format, which supports transparency.

When you create a job that uses this preset, you specify the .png or .jpg graphics that you want Elastic Transcoder to include in the transcoded videos. You can specify fewer graphics in the job than you specify watermark settings in the preset, which allows you to use the same preset for up to four watermarks that have different dimensions.


WithAspectRatio(String) Obsolete.
Sets the AspectRatio property

WithBitRate(String) Obsolete.
Sets the BitRate property

WithCodec(String) Obsolete.
Sets the Codec property

WithCodecOptions(array<KeyValuePair<(Of <<'(String, String>)>>)>[]()[][]) Obsolete.
Adds the KeyValuePairs to the CodecOptions dictionary.

WithDisplayAspectRatio(String) Obsolete.
Sets the DisplayAspectRatio property

WithFixedGOP(String) Obsolete.
Sets the FixedGOP property

WithFrameRate(String) Obsolete.
Sets the FrameRate property

WithKeyframesMaxDist(String) Obsolete.
Sets the KeyframesMaxDist property

WithMaxFrameRate(String) Obsolete.
Sets the MaxFrameRate property

WithMaxHeight(String) Obsolete.
Sets the MaxHeight property

WithMaxWidth(String) Obsolete.
Sets the MaxWidth property

WithPaddingPolicy(String) Obsolete.
Sets the PaddingPolicy property

WithResolution(String) Obsolete.
Sets the Resolution property

WithSizingPolicy(String) Obsolete.
Sets the SizingPolicy property

WithWatermarks(array<PresetWatermark>[]()[][]) Obsolete.
Sets the Watermarks property

WithWatermarks(IEnumerable<(Of <<'(PresetWatermark>)>>)) Obsolete.
Sets the Watermarks property

Inheritance Hierarchy
Object
VideoParameters

Assembly: AWSSDK (Module: AWSSDK) Version: 1.5.60.0 (1.5.60.0)