summaryrefslogtreecommitdiff
path: root/libavcodec/ac3enc_float.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/ac3enc_float.c')
-rw-r--r--libavcodec/ac3enc_float.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/libavcodec/ac3enc_float.c b/libavcodec/ac3enc_float.c
index 4f61440b52..012c31de5d 100644
--- a/libavcodec/ac3enc_float.c
+++ b/libavcodec/ac3enc_float.c
@@ -100,6 +100,7 @@ static void scale_coefficients(AC3EncodeContext *s)
}
+#if CONFIG_AC3_ENCODER
AVCodec ff_ac3_encoder = {
"ac3",
AVMEDIA_TYPE_AUDIO,
@@ -114,3 +115,20 @@ AVCodec ff_ac3_encoder = {
.priv_class = &ac3enc_class,
.channel_layouts = ac3_channel_layouts,
};
+#endif
+
+#if CONFIG_EAC3_ENCODER
+AVCodec ff_eac3_encoder = {
+ .name = "eac3",
+ .type = AVMEDIA_TYPE_AUDIO,
+ .id = CODEC_ID_EAC3,
+ .priv_data_size = sizeof(AC3EncodeContext),
+ .init = ac3_encode_init,
+ .encode = ac3_encode_frame,
+ .close = ac3_encode_close,
+ .sample_fmts = (const enum AVSampleFormat[]){AV_SAMPLE_FMT_FLT,AV_SAMPLE_FMT_NONE},
+ .long_name = NULL_IF_CONFIG_SMALL("ATSC A/52 E-AC-3"),
+ .priv_class = &eac3enc_class,
+ .channel_layouts = ac3_channel_layouts,
+};
+#endif