* This plugin makes use of liba52 to decode A/52 audio
* (http://liba52.sf.net/).
*****************************************************************************
- * Copyright (C) 2001, 2002 the VideoLAN team
+ * Copyright (C) 2001-2009 the VideoLAN team
* $Id$
*
* Authors: Gildas Bazin <gbazin@videolan.org>
static int Create( vlc_object_t *p_this )
{
aout_filter_t *p_filter = (aout_filter_t *)p_this;
- filter_sys_t *p_sys = (filter_sys_t *)p_filter->p_sys;
+ filter_sys_t *p_sys;
int i_ret;
if ( p_filter->input.i_format != VLC_CODEC_A52
int OpenEncoder( vlc_object_t *p_this )
{
encoder_t *p_enc = (encoder_t *)p_this;
- encoder_sys_t *p_sys = p_enc->p_sys;
+ encoder_sys_t *p_sys;
AVCodecContext *p_context;
AVCodec *p_codec;
int i_codec_id, i_cat;
/*****************************************************************************
* speex.c: speex decoder/packetizer/encoder module making use of libspeex.
*****************************************************************************
- * Copyright (C) 2003-2008 the VideoLAN team
+ * Copyright (C) 2003-2009 the VideoLAN team
* $Id$
*
* Authors: Gildas Bazin <gbazin@videolan.org>
static int OpenDecoder( vlc_object_t *p_this )
{
decoder_t *p_dec = (decoder_t*)p_this;
- decoder_sys_t *p_sys = p_dec->p_sys;
+ decoder_sys_t *p_sys;
if( p_dec->fmt_in.i_codec != VLC_CODEC_SPEEX )
return VLC_EGENERIC;
/* Allocate the memory needed to store the decoder's structure */
- if( ( p_dec->p_sys = p_sys =
- (decoder_sys_t *)malloc(sizeof(decoder_sys_t)) ) == NULL )
+ if( ( p_dec->p_sys = p_sys = malloc(sizeof(decoder_sys_t)) ) == NULL )
return VLC_ENOMEM;
p_dec->p_sys->bits.buf_size = 0;
p_dec->p_sys->b_packetizer = false;
decoder_sys_t *p_sys = p_dec->p_sys;
/* Our current index in the SPU packet */
- unsigned int i_index = p_sys->i_rle_size + 4;
+ unsigned int i_index;
/* The next start-of-control-sequence index and the previous one */
unsigned int i_next_seq = 0, i_cur_seq = 0;
static int OpenEncoder( vlc_object_t *p_this )
{
encoder_t *p_enc = (encoder_t *)p_this;
- encoder_sys_t *p_sys = p_enc->p_sys;
+ encoder_sys_t *p_sys;
ogg_packet header;
uint8_t *p_extra;
vlc_value_t val;
}
/* Allocate the memory needed to store the decoder's structure */
- if( ( p_sys = (encoder_sys_t *)malloc(sizeof(encoder_sys_t)) ) == NULL )
+ if( ( p_sys = malloc(sizeof(encoder_sys_t)) ) == NULL )
return VLC_ENOMEM;
p_enc->p_sys = p_sys;