## faac faac — Free MPEG-2/4 AAC encoder |

## Synopsis

                        GstFaac;

## Properties

      "bitrate"                  gint                  : Read / Write
      "midside"                  gboolean              : Read / Write
      "outputformat"             GstFaacOutputFormat   : Read / Write
      "profile"                  GstFaacProfile        : Read / Write
      "shortctl"                 GstFaacShortCtl       : Read / Write
      "tns"                      gboolean              : Read / Write

## Description

faac encodes raw audio to AAC (MPEG-4 part 3) streams.

The "outputformat" property determines whether or not the AAC data needs additional framing provided by a container (such as Matroska or Quicktime). This is required for raw data, whereas ADTS formatted AAC already provides framing and needs no container.

The "profile" property determines the AAC profile, where the default LC (Low Complexity) profile is most widely used, supported and suitable for general use. The other profiles are very rarely used and often not supported.

### Example launch line

    1
    gst-launch audiotestsrc wave=sine num-buffers=100 ! audioconvert ! faac ! matroskamux ! filesink location=sine.mkv

Encode a sine beep as aac and write to matroska container.

## Details

### GstFaac

    typedef struct {
      GstElement element;

      /* pads */
      GstPad *srcpad, *sinkpad;

      /* stream properties */
      gint samplerate,
           channels,
           format,
           bps,
           bitrate,
           profile,
           shortctl,
           outputformat;
      gboolean tns,
               midside;
      gulong bytes,
             samples;

      /* FAAC object */
      faacEncHandle handle;

      /* cache of the input */
      GstAdapter *adapter;
      /* offset of data to be encoded next */
      guint offset;
    } GstFaac;

## Property Details

### The `"bitrate"` property

      "bitrate"                  gint                  : Read / Write

Bitrate in bits/sec.

Allowed values: [8000,320000]

Default value: 128000

### The `"midside"` property

      "midside"                  gboolean              : Read / Write

Allow mid/side encoding.

Default value: TRUE

### The `"outputformat"` property

      "outputformat"             GstFaacOutputFormat   : Read / Write

Format of output frames.

Default value: OUTPUTFORMAT_RAW

### The `"profile"` property

      "profile"                  GstFaacProfile        : Read / Write

MPEG/AAC encoding profile.

Default value: LC

### The `"shortctl"` property

      "shortctl"                 GstFaacShortCtl       : Read / Write

Block type encorcing.

Default value: SHORTCTL_NORMAL

### The `"tns"` property

      "tns"                      gboolean              : Read / Write

Use temporal noise shaping.

Default value: FALSE

## See Also

faad