/* samples output by the codec. we reserve more space for avsync
compensation */
uint8_t audio_buf[(AVCODEC_MAX_AUDIO_FRAME_SIZE * 3) / 2];
- int audio_buf_size; /* in bytes */
+ unsigned int audio_buf_size; /* in bytes */
int audio_buf_index; /* in bytes */
AVPacket audio_pkt;
uint8_t *audio_pkt_data;
/* used to avoid missaligned exceptions on some archs (alpha, ...) */
#ifdef ARCH_X86
-# define unaligned32(a) (*(uint32_t*)(a))
+# define unaligned32(a) (*(const uint32_t*)(a))
#else
# ifdef __GNUC__
static inline uint32_t unaligned32(const void *v) {
(gb)->index= name##_index;\
# define UPDATE_CACHE(name, gb)\
- name##_cache= unaligned32_be( ((uint8_t *)(gb)->buffer)+(name##_index>>3) ) << (name##_index&0x07);\
+ name##_cache= unaligned32_be( ((const uint8_t *)(gb)->buffer)+(name##_index>>3) ) << (name##_index&0x07);\
# define SKIP_CACHE(name, gb, num)\
name##_cache <<= (num);\
#endif
#ifdef ARCH_X86
-static inline long long rdtsc()
+static inline long long rdtsc(void)
{
long long l;
asm volatile( "rdtsc\n\t"
static void iv_alloc_frames(Indeo3DecodeContext *s)
{
int luma_width, luma_height, luma_pixels, chroma_width, chroma_height,
- chroma_pixels, bufsize, i;
+ chroma_pixels, i;
+ unsigned int bufsize;
luma_width = (s->width + 3) & (~3);
luma_height = (s->height + 3) & (~3);
/* do quarter-block output */
-static void do_output_subblock(Real144_internal *glob, int x)
+static void do_output_subblock(Real144_internal *glob, unsigned int x)
{
int a,b,c,d,e,f,g;
/* initial decode */
-static void unpack(unsigned short *tgt, unsigned char *src, int len)
+static void unpack(unsigned short *tgt, unsigned char *src, unsigned int len)
{
int x,y,z;
int n,temp;
/* format I/O context */
typedef struct AVFormatContext {
- AVClass *av_class; /* set by av_alloc_format_context */
+ const AVClass *av_class; /* set by av_alloc_format_context */
/* can only be iformat or oformat, not both at the same time */
struct AVInputFormat *iformat;
struct AVOutputFormat *oformat;
return 0;
}
-static unsigned int codec_get_asf_tag(const CodecTag *tags, int id)
+static unsigned int codec_get_asf_tag(const CodecTag *tags, unsigned int id)
{
while (tags->id != 0) {
if (!tags->invalid_asf && tags->id == id)
long current_sample;
long left_in_chunk; /* how many samples before next chunk */
/* specific MPEG4 header which is added at the beginning of the stream */
- int header_len;
+ unsigned int header_len;
uint8_t *header_data;
MOV_esds_t esds;
} MOVStreamContext;