30 #define BITSTREAM_READER_LE
43 #define FORMAT_SIMPLE 1
44 #define FORMAT_ENCRYPTED 2
79 if (CRC != (crc ^ 0xFFFFFFFFU)) {
89 uint64_t crc = UINT64_MAX,
poly = 0x42F0E1EBA9EA3693
U;
94 crc ^= (uint64_t)*pass++ << 56;
95 for (i = 0; i < 8; i++)
96 crc = (crc << 1) ^ (poly & (((int64_t) crc) >> 63));
99 return crc ^ UINT64_MAX;
146 av_log(avctx,
AV_LOG_ERROR,
"Missing password for encrypted stream. Please use the -password option\n");
214 int *got_frame_ptr,
AVPacket *avpkt)
219 int buf_size = avpkt->
size;
251 for (i = 0; i < 8; i++)
262 uint32_t unary,
depth, k;
286 value = (unary << k) +
get_bits(&gb, k);
293 rice->
sum1 += value - (rice->
sum1 >> 4);
300 rice->
sum0 += value - (rice->
sum0 >> 4);
308 *p = 1 + ((value >> 1) ^ ((value & 1) - 1));
315 #define PRED(x, k) (int32_t)((((uint64_t)(x) << (k)) - (x)) >> (k))
317 case 1: *p +=
PRED(*predictor, 4);
break;
319 case 3: *p +=
PRED(*predictor, 5);
break;
331 for (*p += *r / 2; r > p - s->
channels; r--)
356 *samples++ = *p + 0x80;
360 int16_t *samples = (int16_t *)frame->
data[0];
404 #define OFFSET(x) offsetof(TTAContext, x)
405 #define DEC (AV_OPT_FLAG_DECODING_PARAM | AV_OPT_FLAG_AUDIO_PARAM)