00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #include "avcodec.h"
00023 #include "put_bits.h"
00024 #include "dsputil.h"
00025 #include "internal.h"
00026 #include "lpc.h"
00027 #include "mathops.h"
00028 #include "alac_data.h"
00029
00030 #define DEFAULT_FRAME_SIZE 4096
00031 #define ALAC_EXTRADATA_SIZE 36
00032 #define ALAC_FRAME_HEADER_SIZE 55
00033 #define ALAC_FRAME_FOOTER_SIZE 3
00034
00035 #define ALAC_ESCAPE_CODE 0x1FF
00036 #define ALAC_MAX_LPC_ORDER 30
00037 #define DEFAULT_MAX_PRED_ORDER 6
00038 #define DEFAULT_MIN_PRED_ORDER 4
00039 #define ALAC_MAX_LPC_PRECISION 9
00040 #define ALAC_MAX_LPC_SHIFT 9
00041
00042 #define ALAC_CHMODE_LEFT_RIGHT 0
00043 #define ALAC_CHMODE_LEFT_SIDE 1
00044 #define ALAC_CHMODE_RIGHT_SIDE 2
00045 #define ALAC_CHMODE_MID_SIDE 3
00046
00047 typedef struct RiceContext {
00048 int history_mult;
00049 int initial_history;
00050 int k_modifier;
00051 int rice_modifier;
00052 } RiceContext;
00053
00054 typedef struct AlacLPCContext {
00055 int lpc_order;
00056 int lpc_coeff[ALAC_MAX_LPC_ORDER+1];
00057 int lpc_quant;
00058 } AlacLPCContext;
00059
00060 typedef struct AlacEncodeContext {
00061 int frame_size;
00062 int verbatim;
00063 int compression_level;
00064 int min_prediction_order;
00065 int max_prediction_order;
00066 int max_coded_frame_size;
00067 int write_sample_size;
00068 int extra_bits;
00069 int32_t sample_buf[2][DEFAULT_FRAME_SIZE];
00070 int32_t predictor_buf[DEFAULT_FRAME_SIZE];
00071 int interlacing_shift;
00072 int interlacing_leftweight;
00073 PutBitContext pbctx;
00074 RiceContext rc;
00075 AlacLPCContext lpc[2];
00076 LPCContext lpc_ctx;
00077 AVCodecContext *avctx;
00078 } AlacEncodeContext;
00079
00080
00081 static void init_sample_buffers(AlacEncodeContext *s, int channels,
00082 uint8_t const *samples[2])
00083 {
00084 int ch, i;
00085 int shift = av_get_bytes_per_sample(s->avctx->sample_fmt) * 8 -
00086 s->avctx->bits_per_raw_sample;
00087
00088 #define COPY_SAMPLES(type) do { \
00089 for (ch = 0; ch < channels; ch++) { \
00090 int32_t *bptr = s->sample_buf[ch]; \
00091 const type *sptr = (const type *)samples[ch]; \
00092 for (i = 0; i < s->frame_size; i++) \
00093 bptr[i] = sptr[i] >> shift; \
00094 } \
00095 } while (0)
00096
00097 if (s->avctx->sample_fmt == AV_SAMPLE_FMT_S32P)
00098 COPY_SAMPLES(int32_t);
00099 else
00100 COPY_SAMPLES(int16_t);
00101 }
00102
00103 static void encode_scalar(AlacEncodeContext *s, int x,
00104 int k, int write_sample_size)
00105 {
00106 int divisor, q, r;
00107
00108 k = FFMIN(k, s->rc.k_modifier);
00109 divisor = (1<<k) - 1;
00110 q = x / divisor;
00111 r = x % divisor;
00112
00113 if (q > 8) {
00114
00115 put_bits(&s->pbctx, 9, ALAC_ESCAPE_CODE);
00116 put_bits(&s->pbctx, write_sample_size, x);
00117 } else {
00118 if (q)
00119 put_bits(&s->pbctx, q, (1<<q) - 1);
00120 put_bits(&s->pbctx, 1, 0);
00121
00122 if (k != 1) {
00123 if (r > 0)
00124 put_bits(&s->pbctx, k, r+1);
00125 else
00126 put_bits(&s->pbctx, k-1, 0);
00127 }
00128 }
00129 }
00130
00131 static void write_element_header(AlacEncodeContext *s,
00132 enum AlacRawDataBlockType element,
00133 int instance)
00134 {
00135 int encode_fs = 0;
00136
00137 if (s->frame_size < DEFAULT_FRAME_SIZE)
00138 encode_fs = 1;
00139
00140 put_bits(&s->pbctx, 3, element);
00141 put_bits(&s->pbctx, 4, instance);
00142 put_bits(&s->pbctx, 12, 0);
00143 put_bits(&s->pbctx, 1, encode_fs);
00144 put_bits(&s->pbctx, 2, s->extra_bits >> 3);
00145 put_bits(&s->pbctx, 1, s->verbatim);
00146 if (encode_fs)
00147 put_bits32(&s->pbctx, s->frame_size);
00148 }
00149
00150 static void calc_predictor_params(AlacEncodeContext *s, int ch)
00151 {
00152 int32_t coefs[MAX_LPC_ORDER][MAX_LPC_ORDER];
00153 int shift[MAX_LPC_ORDER];
00154 int opt_order;
00155
00156 if (s->compression_level == 1) {
00157 s->lpc[ch].lpc_order = 6;
00158 s->lpc[ch].lpc_quant = 6;
00159 s->lpc[ch].lpc_coeff[0] = 160;
00160 s->lpc[ch].lpc_coeff[1] = -190;
00161 s->lpc[ch].lpc_coeff[2] = 170;
00162 s->lpc[ch].lpc_coeff[3] = -130;
00163 s->lpc[ch].lpc_coeff[4] = 80;
00164 s->lpc[ch].lpc_coeff[5] = -25;
00165 } else {
00166 opt_order = ff_lpc_calc_coefs(&s->lpc_ctx, s->sample_buf[ch],
00167 s->frame_size,
00168 s->min_prediction_order,
00169 s->max_prediction_order,
00170 ALAC_MAX_LPC_PRECISION, coefs, shift,
00171 FF_LPC_TYPE_LEVINSON, 0,
00172 ORDER_METHOD_EST, ALAC_MAX_LPC_SHIFT, 1);
00173
00174 s->lpc[ch].lpc_order = opt_order;
00175 s->lpc[ch].lpc_quant = shift[opt_order-1];
00176 memcpy(s->lpc[ch].lpc_coeff, coefs[opt_order-1], opt_order*sizeof(int));
00177 }
00178 }
00179
00180 static int estimate_stereo_mode(int32_t *left_ch, int32_t *right_ch, int n)
00181 {
00182 int i, best;
00183 int32_t lt, rt;
00184 uint64_t sum[4];
00185 uint64_t score[4];
00186
00187
00188 sum[0] = sum[1] = sum[2] = sum[3] = 0;
00189 for (i = 2; i < n; i++) {
00190 lt = left_ch[i] - 2 * left_ch[i - 1] + left_ch[i - 2];
00191 rt = right_ch[i] - 2 * right_ch[i - 1] + right_ch[i - 2];
00192 sum[2] += FFABS((lt + rt) >> 1);
00193 sum[3] += FFABS(lt - rt);
00194 sum[0] += FFABS(lt);
00195 sum[1] += FFABS(rt);
00196 }
00197
00198
00199 score[0] = sum[0] + sum[1];
00200 score[1] = sum[0] + sum[3];
00201 score[2] = sum[1] + sum[3];
00202 score[3] = sum[2] + sum[3];
00203
00204
00205 best = 0;
00206 for (i = 1; i < 4; i++) {
00207 if (score[i] < score[best])
00208 best = i;
00209 }
00210 return best;
00211 }
00212
00213 static void alac_stereo_decorrelation(AlacEncodeContext *s)
00214 {
00215 int32_t *left = s->sample_buf[0], *right = s->sample_buf[1];
00216 int i, mode, n = s->frame_size;
00217 int32_t tmp;
00218
00219 mode = estimate_stereo_mode(left, right, n);
00220
00221 switch (mode) {
00222 case ALAC_CHMODE_LEFT_RIGHT:
00223 s->interlacing_leftweight = 0;
00224 s->interlacing_shift = 0;
00225 break;
00226 case ALAC_CHMODE_LEFT_SIDE:
00227 for (i = 0; i < n; i++)
00228 right[i] = left[i] - right[i];
00229 s->interlacing_leftweight = 1;
00230 s->interlacing_shift = 0;
00231 break;
00232 case ALAC_CHMODE_RIGHT_SIDE:
00233 for (i = 0; i < n; i++) {
00234 tmp = right[i];
00235 right[i] = left[i] - right[i];
00236 left[i] = tmp + (right[i] >> 31);
00237 }
00238 s->interlacing_leftweight = 1;
00239 s->interlacing_shift = 31;
00240 break;
00241 default:
00242 for (i = 0; i < n; i++) {
00243 tmp = left[i];
00244 left[i] = (tmp + right[i]) >> 1;
00245 right[i] = tmp - right[i];
00246 }
00247 s->interlacing_leftweight = 1;
00248 s->interlacing_shift = 1;
00249 break;
00250 }
00251 }
00252
00253 static void alac_linear_predictor(AlacEncodeContext *s, int ch)
00254 {
00255 int i;
00256 AlacLPCContext lpc = s->lpc[ch];
00257
00258 if (lpc.lpc_order == 31) {
00259 s->predictor_buf[0] = s->sample_buf[ch][0];
00260
00261 for (i = 1; i < s->frame_size; i++) {
00262 s->predictor_buf[i] = s->sample_buf[ch][i ] -
00263 s->sample_buf[ch][i - 1];
00264 }
00265
00266 return;
00267 }
00268
00269
00270
00271 if (lpc.lpc_order > 0) {
00272 int32_t *samples = s->sample_buf[ch];
00273 int32_t *residual = s->predictor_buf;
00274
00275
00276 residual[0] = samples[0];
00277 for (i = 1; i <= lpc.lpc_order; i++)
00278 residual[i] = samples[i] - samples[i-1];
00279
00280
00281 for (i = lpc.lpc_order + 1; i < s->frame_size; i++) {
00282 int sum = 1 << (lpc.lpc_quant - 1), res_val, j;
00283
00284 for (j = 0; j < lpc.lpc_order; j++) {
00285 sum += (samples[lpc.lpc_order-j] - samples[0]) *
00286 lpc.lpc_coeff[j];
00287 }
00288
00289 sum >>= lpc.lpc_quant;
00290 sum += samples[0];
00291 residual[i] = sign_extend(samples[lpc.lpc_order+1] - sum,
00292 s->write_sample_size);
00293 res_val = residual[i];
00294
00295 if (res_val) {
00296 int index = lpc.lpc_order - 1;
00297 int neg = (res_val < 0);
00298
00299 while (index >= 0 && (neg ? (res_val < 0) : (res_val > 0))) {
00300 int val = samples[0] - samples[lpc.lpc_order - index];
00301 int sign = (val ? FFSIGN(val) : 0);
00302
00303 if (neg)
00304 sign *= -1;
00305
00306 lpc.lpc_coeff[index] -= sign;
00307 val *= sign;
00308 res_val -= (val >> lpc.lpc_quant) * (lpc.lpc_order - index);
00309 index--;
00310 }
00311 }
00312 samples++;
00313 }
00314 }
00315 }
00316
00317 static void alac_entropy_coder(AlacEncodeContext *s)
00318 {
00319 unsigned int history = s->rc.initial_history;
00320 int sign_modifier = 0, i, k;
00321 int32_t *samples = s->predictor_buf;
00322
00323 for (i = 0; i < s->frame_size;) {
00324 int x;
00325
00326 k = av_log2((history >> 9) + 3);
00327
00328 x = -2 * (*samples) -1;
00329 x ^= x >> 31;
00330
00331 samples++;
00332 i++;
00333
00334 encode_scalar(s, x - sign_modifier, k, s->write_sample_size);
00335
00336 history += x * s->rc.history_mult -
00337 ((history * s->rc.history_mult) >> 9);
00338
00339 sign_modifier = 0;
00340 if (x > 0xFFFF)
00341 history = 0xFFFF;
00342
00343 if (history < 128 && i < s->frame_size) {
00344 unsigned int block_size = 0;
00345
00346 k = 7 - av_log2(history) + ((history + 16) >> 6);
00347
00348 while (*samples == 0 && i < s->frame_size) {
00349 samples++;
00350 i++;
00351 block_size++;
00352 }
00353 encode_scalar(s, block_size, k, 16);
00354 sign_modifier = (block_size <= 0xFFFF);
00355 history = 0;
00356 }
00357
00358 }
00359 }
00360
00361 static void write_element(AlacEncodeContext *s,
00362 enum AlacRawDataBlockType element, int instance,
00363 const uint8_t *samples0, const uint8_t *samples1)
00364 {
00365 uint8_t const *samples[2] = { samples0, samples1 };
00366 int i, j, channels;
00367 int prediction_type = 0;
00368 PutBitContext *pb = &s->pbctx;
00369
00370 channels = element == TYPE_CPE ? 2 : 1;
00371
00372 if (s->verbatim) {
00373 write_element_header(s, element, instance);
00374
00375 if (s->avctx->sample_fmt == AV_SAMPLE_FMT_S32P) {
00376 int shift = 32 - s->avctx->bits_per_raw_sample;
00377 int32_t const *samples_s32[2] = { (const int32_t *)samples0,
00378 (const int32_t *)samples1 };
00379 for (i = 0; i < s->frame_size; i++)
00380 for (j = 0; j < channels; j++)
00381 put_sbits(pb, s->avctx->bits_per_raw_sample,
00382 samples_s32[j][i] >> shift);
00383 } else {
00384 int16_t const *samples_s16[2] = { (const int16_t *)samples0,
00385 (const int16_t *)samples1 };
00386 for (i = 0; i < s->frame_size; i++)
00387 for (j = 0; j < channels; j++)
00388 put_sbits(pb, s->avctx->bits_per_raw_sample,
00389 samples_s16[j][i]);
00390 }
00391 } else {
00392 s->write_sample_size = s->avctx->bits_per_raw_sample - s->extra_bits +
00393 channels - 1;
00394
00395 init_sample_buffers(s, channels, samples);
00396 write_element_header(s, element, instance);
00397
00398 if (channels == 2)
00399 alac_stereo_decorrelation(s);
00400 else
00401 s->interlacing_shift = s->interlacing_leftweight = 0;
00402 put_bits(pb, 8, s->interlacing_shift);
00403 put_bits(pb, 8, s->interlacing_leftweight);
00404
00405 for (i = 0; i < channels; i++) {
00406 calc_predictor_params(s, i);
00407
00408 put_bits(pb, 4, prediction_type);
00409 put_bits(pb, 4, s->lpc[i].lpc_quant);
00410
00411 put_bits(pb, 3, s->rc.rice_modifier);
00412 put_bits(pb, 5, s->lpc[i].lpc_order);
00413
00414 for (j = 0; j < s->lpc[i].lpc_order; j++)
00415 put_sbits(pb, 16, s->lpc[i].lpc_coeff[j]);
00416 }
00417
00418
00419 if (s->extra_bits) {
00420 uint32_t mask = (1 << s->extra_bits) - 1;
00421 for (i = 0; i < s->frame_size; i++) {
00422 for (j = 0; j < channels; j++) {
00423 put_bits(pb, s->extra_bits, s->sample_buf[j][i] & mask);
00424 s->sample_buf[j][i] >>= s->extra_bits;
00425 }
00426 }
00427 }
00428
00429
00430 for (i = 0; i < channels; i++) {
00431 alac_linear_predictor(s, i);
00432
00433
00434 if (prediction_type == 15) {
00435
00436 for (j = s->frame_size - 1; j > 0; j--)
00437 s->predictor_buf[j] -= s->predictor_buf[j - 1];
00438 }
00439 alac_entropy_coder(s);
00440 }
00441 }
00442 }
00443
00444 static int write_frame(AlacEncodeContext *s, AVPacket *avpkt,
00445 uint8_t * const *samples)
00446 {
00447 PutBitContext *pb = &s->pbctx;
00448 const enum AlacRawDataBlockType *ch_elements = ff_alac_channel_elements[s->avctx->channels - 1];
00449 const uint8_t *ch_map = ff_alac_channel_layout_offsets[s->avctx->channels - 1];
00450 int ch, element, sce, cpe;
00451
00452 init_put_bits(pb, avpkt->data, avpkt->size);
00453
00454 ch = element = sce = cpe = 0;
00455 while (ch < s->avctx->channels) {
00456 if (ch_elements[element] == TYPE_CPE) {
00457 write_element(s, TYPE_CPE, cpe, samples[ch_map[ch]],
00458 samples[ch_map[ch + 1]]);
00459 cpe++;
00460 ch += 2;
00461 } else {
00462 write_element(s, TYPE_SCE, sce, samples[ch_map[ch]], NULL);
00463 sce++;
00464 ch++;
00465 }
00466 element++;
00467 }
00468
00469 put_bits(pb, 3, TYPE_END);
00470 flush_put_bits(pb);
00471
00472 return put_bits_count(pb) >> 3;
00473 }
00474
00475 static av_always_inline int get_max_frame_size(int frame_size, int ch, int bps)
00476 {
00477 int header_bits = 23 + 32 * (frame_size < DEFAULT_FRAME_SIZE);
00478 return FFALIGN(header_bits + bps * ch * frame_size + 3, 8) / 8;
00479 }
00480
00481 static av_cold int alac_encode_close(AVCodecContext *avctx)
00482 {
00483 AlacEncodeContext *s = avctx->priv_data;
00484 ff_lpc_end(&s->lpc_ctx);
00485 av_freep(&avctx->extradata);
00486 avctx->extradata_size = 0;
00487 av_freep(&avctx->coded_frame);
00488 return 0;
00489 }
00490
00491 static av_cold int alac_encode_init(AVCodecContext *avctx)
00492 {
00493 AlacEncodeContext *s = avctx->priv_data;
00494 int ret;
00495 uint8_t *alac_extradata;
00496
00497 avctx->frame_size = s->frame_size = DEFAULT_FRAME_SIZE;
00498
00499 if (avctx->sample_fmt == AV_SAMPLE_FMT_S32P) {
00500 if (avctx->bits_per_raw_sample != 24)
00501 av_log(avctx, AV_LOG_WARNING, "encoding as 24 bits-per-sample\n");
00502 avctx->bits_per_raw_sample = 24;
00503 } else {
00504 avctx->bits_per_raw_sample = 16;
00505 s->extra_bits = 0;
00506 }
00507
00508
00509 if (avctx->compression_level == FF_COMPRESSION_DEFAULT)
00510 s->compression_level = 2;
00511 else
00512 s->compression_level = av_clip(avctx->compression_level, 0, 2);
00513
00514
00515 s->rc.history_mult = 40;
00516 s->rc.initial_history = 10;
00517 s->rc.k_modifier = 14;
00518 s->rc.rice_modifier = 4;
00519
00520 s->max_coded_frame_size = get_max_frame_size(avctx->frame_size,
00521 avctx->channels,
00522 avctx->bits_per_raw_sample);
00523
00524 avctx->extradata = av_mallocz(ALAC_EXTRADATA_SIZE + FF_INPUT_BUFFER_PADDING_SIZE);
00525 if (!avctx->extradata) {
00526 ret = AVERROR(ENOMEM);
00527 goto error;
00528 }
00529 avctx->extradata_size = ALAC_EXTRADATA_SIZE;
00530
00531 alac_extradata = avctx->extradata;
00532 AV_WB32(alac_extradata, ALAC_EXTRADATA_SIZE);
00533 AV_WB32(alac_extradata+4, MKBETAG('a','l','a','c'));
00534 AV_WB32(alac_extradata+12, avctx->frame_size);
00535 AV_WB8 (alac_extradata+17, avctx->bits_per_raw_sample);
00536 AV_WB8 (alac_extradata+21, avctx->channels);
00537 AV_WB32(alac_extradata+24, s->max_coded_frame_size);
00538 AV_WB32(alac_extradata+28,
00539 avctx->sample_rate * avctx->channels * avctx->bits_per_raw_sample);
00540 AV_WB32(alac_extradata+32, avctx->sample_rate);
00541
00542
00543 if (s->compression_level > 0) {
00544 AV_WB8(alac_extradata+18, s->rc.history_mult);
00545 AV_WB8(alac_extradata+19, s->rc.initial_history);
00546 AV_WB8(alac_extradata+20, s->rc.k_modifier);
00547 }
00548
00549 s->min_prediction_order = DEFAULT_MIN_PRED_ORDER;
00550 if (avctx->min_prediction_order >= 0) {
00551 if (avctx->min_prediction_order < MIN_LPC_ORDER ||
00552 avctx->min_prediction_order > ALAC_MAX_LPC_ORDER) {
00553 av_log(avctx, AV_LOG_ERROR, "invalid min prediction order: %d\n",
00554 avctx->min_prediction_order);
00555 ret = AVERROR(EINVAL);
00556 goto error;
00557 }
00558
00559 s->min_prediction_order = avctx->min_prediction_order;
00560 }
00561
00562 s->max_prediction_order = DEFAULT_MAX_PRED_ORDER;
00563 if (avctx->max_prediction_order >= 0) {
00564 if (avctx->max_prediction_order < MIN_LPC_ORDER ||
00565 avctx->max_prediction_order > ALAC_MAX_LPC_ORDER) {
00566 av_log(avctx, AV_LOG_ERROR, "invalid max prediction order: %d\n",
00567 avctx->max_prediction_order);
00568 ret = AVERROR(EINVAL);
00569 goto error;
00570 }
00571
00572 s->max_prediction_order = avctx->max_prediction_order;
00573 }
00574
00575 if (s->max_prediction_order < s->min_prediction_order) {
00576 av_log(avctx, AV_LOG_ERROR,
00577 "invalid prediction orders: min=%d max=%d\n",
00578 s->min_prediction_order, s->max_prediction_order);
00579 ret = AVERROR(EINVAL);
00580 goto error;
00581 }
00582
00583 avctx->coded_frame = avcodec_alloc_frame();
00584 if (!avctx->coded_frame) {
00585 ret = AVERROR(ENOMEM);
00586 goto error;
00587 }
00588
00589 s->avctx = avctx;
00590
00591 if ((ret = ff_lpc_init(&s->lpc_ctx, avctx->frame_size,
00592 s->max_prediction_order,
00593 FF_LPC_TYPE_LEVINSON)) < 0) {
00594 goto error;
00595 }
00596
00597 return 0;
00598 error:
00599 alac_encode_close(avctx);
00600 return ret;
00601 }
00602
00603 static int alac_encode_frame(AVCodecContext *avctx, AVPacket *avpkt,
00604 const AVFrame *frame, int *got_packet_ptr)
00605 {
00606 AlacEncodeContext *s = avctx->priv_data;
00607 int out_bytes, max_frame_size, ret;
00608
00609 s->frame_size = frame->nb_samples;
00610
00611 if (frame->nb_samples < DEFAULT_FRAME_SIZE)
00612 max_frame_size = get_max_frame_size(s->frame_size, avctx->channels,
00613 avctx->bits_per_raw_sample);
00614 else
00615 max_frame_size = s->max_coded_frame_size;
00616
00617 if ((ret = ff_alloc_packet2(avctx, avpkt, 2 * max_frame_size)))
00618 return ret;
00619
00620
00621 if (s->compression_level) {
00622 s->verbatim = 0;
00623 s->extra_bits = avctx->bits_per_raw_sample - 16;
00624 } else {
00625 s->verbatim = 1;
00626 s->extra_bits = 0;
00627 }
00628
00629 out_bytes = write_frame(s, avpkt, frame->extended_data);
00630
00631 if (out_bytes > max_frame_size) {
00632
00633 s->verbatim = 1;
00634 s->extra_bits = 0;
00635 out_bytes = write_frame(s, avpkt, frame->extended_data);
00636 }
00637
00638 avpkt->size = out_bytes;
00639 *got_packet_ptr = 1;
00640 return 0;
00641 }
00642
00643 AVCodec ff_alac_encoder = {
00644 .name = "alac",
00645 .type = AVMEDIA_TYPE_AUDIO,
00646 .id = AV_CODEC_ID_ALAC,
00647 .priv_data_size = sizeof(AlacEncodeContext),
00648 .init = alac_encode_init,
00649 .encode2 = alac_encode_frame,
00650 .close = alac_encode_close,
00651 .capabilities = CODEC_CAP_SMALL_LAST_FRAME,
00652 .channel_layouts = ff_alac_channel_layouts,
00653 .sample_fmts = (const enum AVSampleFormat[]){ AV_SAMPLE_FMT_S32P,
00654 AV_SAMPLE_FMT_S16P,
00655 AV_SAMPLE_FMT_NONE },
00656 .long_name = NULL_IF_CONFIG_SMALL("ALAC (Apple Lossless Audio Codec)"),
00657 };