s->offset[chan][i] = mean;
}
-static int inline get_le32(GetBitContext *gb)
+static inline int get_le32(GetBitContext *gb)
{
return bswap_32(get_bits_long(gb, 32));
}
-static short inline get_le16(GetBitContext *gb)
+static inline short get_le16(GetBitContext *gb)
{
return bswap_16(get_bits_long(gb, 16));
}
static int shorten_decode_frame(AVCodecContext *avctx,
void *data, int *data_size,
- uint8_t *buf, int buf_size)
+ const uint8_t *buf, int buf_size)
{
ShortenContext *s = avctx->priv_data;
int i, input_buf_size = 0;
s->bitstream_size= buf_size;
if(buf_size < s->max_framesize){
- //dprintf("wanna more data ... %d\n", buf_size);
+ //dprintf(avctx, "wanna more data ... %d\n", buf_size);
+ *data_size = 0;
return input_buf_size;
}
}
init_get_bits(&s->gb, buf, buf_size*8);
- get_bits(&s->gb, s->bitindex);
+ skip_bits(&s->gb, s->bitindex);
if (!s->blocksize)
{
int maxnlpc = 0;
s->lpcqoffset = V2LPCQOFFSET;
if (get_ur_golomb_shorten(&s->gb, FNSIZE) != FN_VERBATIM) {
- av_log(s->avctx, AV_LOG_ERROR, "missing verbatim section at begining of stream\n");
+ av_log(s->avctx, AV_LOG_ERROR, "missing verbatim section at beginning of stream\n");
return -1;
}
s->blocksize = get_uint(s, av_log2(s->blocksize));
break;
case FN_QUIT:
+ *data_size = 0;
return buf_size;
break;
default: