Conditional Outputs Settings

This topic contains details for encoding settings related to conditional outputs, allowing you to skip outputs if certain conditions aren't met.

min_size

min_size:String

API Versions: V2

Parent: conditionals

Compatible Job Types: VOD

Example:

  • 640x480

Description:

If the source's dimensions are smaller than the requested size, the output will be skipped.

Dimensions are calculated by multiplying the height and the width of the source and comparing to the product of provided dimensions.

{
  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "min_size": "640x480"
      }
    }
  ]
}

See Also: max_size

max_size

max_size:String

API Versions: V2

Parent: conditionals

Compatible Job Types: VOD

Example:

  • 640x480

Description:

If the source's dimensions are larger than the requested size, the output will be skipped.

Dimensions are calculated by multiplying the height and the width of the source and comparing to the product of provided dimensions.

{
  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "max_size": "640x480"
      }
    }
  ]
}

See Also: min_size

min_duration

min_duration:Integer

API Versions: V2

Parent: conditionals

Valid Values: A positive integer

Compatible Job Types: VOD

Example:

  • 300

Description:

If the source's duration is shorter than the requested duration, the output will be skipped.

Duration must be provided in seconds. To skip an output if the source is shorter than 5 minutes, use '300'.

{
  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "min_duration": "300"
      }
    }
  ]
}

See Also: max_duration

max_duration

max_duration:Integer

API Versions: V2

Parent: conditionals

Valid Values: A positive integer

Compatible Job Types: VOD

Example:

  • 600

Description:

If the source's duration is longer than the requested duration, the output will be skipped.

Duration must be provided in seconds. To skip an output if the source is longer than 5 minutes, use '300'.

{
  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "max_duration": "600"
      }
    }
  ]
}

See Also: min_duration

min_audio_bitrate

min_audio_bitrate:Integer

API Versions: V2

Parent: conditionals

Valid Values: A positive integer

Compatible Job Types: VOD

Example:

  • 128

Description:

If the source's audio bitrate is less than the specified bitrate (in kbps), the output will be skipped.

Source files without an audio track or without a recognizable audio bitrate will ignore this setting. (See require_audio for more options.) To skip an output if the source audio bitrate is less than 128 Kbps, use 128.

{
  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "min_audio_bitrate": 128
      }
    }
  ]
}

See Also: max_audio_bitrate and require_audio

max_audio_bitrate

max_audio_bitrate:Integer

API Versions: V2

Parent: conditionals

Valid Values: A positive integer

Compatible Job Types: VOD

Example:

  • 160

Description:

If the source's audio bitrate is greater than the specified bitrate (in kbps), the output will be skipped.

Source files without an audio track or without a recognizable audio bitrate will ignore this setting. (See require_audio for more options.) To skip an output if the source audio bitrate is greater than 160 Kbps, use 160.

{
  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "max_audio_bitrate": 160
      }
    }
  ]
}

See Also: min_audio_bitrate and require_audio

min_video_bitrate

min_video_bitrate:Integer

API Versions: V2

Parent: conditionals

Valid Values: A positive integer

Compatible Job Types: VOD

Example:

  • 800

Description:

If the source's video bitrate is less than the specified bitrate (in kbps), the output will be skipped.

Source files without a video track or without a recognizable video bitrate will ignore this setting. (See require_video for more options.) To skip an output if the source video bitrate is less than 800 Kbps, use 800.

{
  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "min_video_bitrate": 800
      }
    }
  ]
}

See Also: max_video_bitrate and require_video

max_video_bitrate

max_video_bitrate:Integer

API Versions: V2

Parent: conditionals

Valid Values: A positive integer

Compatible Job Types: VOD

Example:

  • 1500

Description:

If the source's video bitrate is greater than the specified bitrate (in kbps), the output will be skipped.

Source files without a video track or without a recognizable video bitrate will ignore this setting. (See require_video for more options.) To skip an output if the source video bitrate is greater than 1500 Kbps, use 1500.

{
  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "max_video_bitrate": 1500
      }
    }
  ]
}

See Also: min_video_bitrate and require_video

require_audio

require_audio:Boolean

API Versions: V2

Parent: conditionals

Default: false

Valid Values: true or false

Compatible Job Types: VOD

Example: true

Description:

If the source file does not have an audio track, the output will be skipped.

To skip an output if the source does not have an audio track, set this option to true.


  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "require_audio": true,
        "min_audio_bitrate": 64
      }
    }
  ]
}

See Also: min_audio_bitrate and require_video

require_video

require_video:Boolean

API Versions: V2

Parent: conditionals

Default: false

Valid Values: true or false

Compatible Job Types: VOD

Example: true

Description:

If the source file does not have a video track, the output will be skipped.

To skip an output if the source does not have a video track, set this option to true.

{
  "input": "s3://zencodertesting/test.mov",
  "outputs": [
    {
      "skip": {
        "require_video": true,
        "min_video_bitrate": 400
      }
    }
  ]
}

See Also: min_video_bitrate and require_audio