public final class DDAudio extends Audio
Describes Dolby Digital Audio Codec (AC3) audio encoding settings. The current implementation for Dolby Digital Audio support are: Audio channel numbers at 1((mono), 2(stereo), 6(5.1side); Audio sampling frequency rates at: 32K/44.1K/48K Hz; Audio bitrate values as AC3 specification supports: 32000, 40000, 48000, 56000, 64000, 80000, 96000, 112000, 128000, 160000, 192000, 224000, 256000, 320000, 384000, 448000, 512000, 576000, 640000 bps.
  • Constructor Details

    • DDAudio

      public DDAudio()
      Creates an instance of DDAudio class.
  • Method Details

    • withChannels

      public DDAudio withChannels(Integer channels)
      Set the channels property: The number of channels in the audio.
      Overrides:
      withChannels in class Audio
      Parameters:
      channels - the channels value to set.
      Returns:
      the Audio object itself.
    • withSamplingRate

      public DDAudio withSamplingRate(Integer samplingRate)
      Set the samplingRate property: The sampling rate to use for encoding in hertz.
      Overrides:
      withSamplingRate in class Audio
      Parameters:
      samplingRate - the samplingRate value to set.
      Returns:
      the Audio object itself.
    • withBitrate

      public DDAudio withBitrate(Integer bitrate)
      Set the bitrate property: The bitrate, in bits per second, of the output encoded audio.
      Overrides:
      withBitrate in class Audio
      Parameters:
      bitrate - the bitrate value to set.
      Returns:
      the Audio object itself.
    • withLabel

      public DDAudio withLabel(String label)
      Set the label property: An optional label for the codec. The label can be used to control muxing behavior.
      Overrides:
      withLabel in class Audio
      Parameters:
      label - the label value to set.
      Returns:
      the Codec object itself.
    • validate

      public void validate()
      Validates the instance.
      Overrides:
      validate in class Audio
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.