Commit 36ac7f92 authored by Christophe Massiot's avatar Christophe Massiot

* Minor ShowBits() optimization ;

* Fixed a bug in vlc.spec ;
* New --disable-plugins option ; make all plug-ins built-in.
parent 6811de9c
This diff is collapsed.
...@@ -990,6 +990,18 @@ AC_ARG_ENABLE(alsa, ...@@ -990,6 +990,18 @@ AC_ARG_ENABLE(alsa,
dnl end of non-BeOS stuff dnl end of non-BeOS stuff
fi fi
dnl
dnl Plug-ins - this must be AT THE END
dnl
AC_ARG_ENABLE(plugins,
[ --disable-plugins Make all plug-ins built-in (default plug-ins enabled)],
[if test x$enable_plugins = xno
then
BUILTINS="${BUILTINS} ${PLUGINS}"
PLUGINS=
fi])
dnl dnl
dnl Configuration is finished dnl Configuration is finished
dnl dnl
...@@ -1074,7 +1086,7 @@ trace mode : ${TRACE} ...@@ -1074,7 +1086,7 @@ trace mode : ${TRACE}
cprof/gprof support : ${CPROF}/${GPROF} cprof/gprof support : ${CPROF}/${GPROF}
need builtin getopt : ${NEED_GETOPT} need builtin getopt : ${NEED_GETOPT}
built-in modules :${BUILTINS} built-in modules :${BUILTINS}
plugin modules :${PLUGINS} plug-in modules :${PLUGINS}
vlc aliases :${ALIASES}" vlc aliases :${ALIASES}"
fi fi
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* input_ext-dec.h: structures exported to the VideoLAN decoders * input_ext-dec.h: structures exported to the VideoLAN decoders
***************************************************************************** *****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN * Copyright (C) 1999, 2000 VideoLAN
* $Id: input_ext-dec.h,v 1.35 2001/09/24 11:17:49 massiot Exp $ * $Id: input_ext-dec.h,v 1.36 2001/10/03 12:46:17 massiot Exp $
* *
* Authors: Christophe Massiot <massiot@via.ecp.fr> * Authors: Christophe Massiot <massiot@via.ecp.fr>
* Michel Kaempf <maxx@via.ecp.fr> * Michel Kaempf <maxx@via.ecp.fr>
...@@ -203,7 +203,7 @@ typedef struct bit_stream_s ...@@ -203,7 +203,7 @@ typedef struct bit_stream_s
/***************************************************************************** /*****************************************************************************
* Protoypes from input_ext-dec.c * Protoypes from input_ext-dec.c
*****************************************************************************/ *****************************************************************************/
void UnalignedShowBits( struct bit_stream_s *, unsigned int ); u32 UnalignedShowBits( struct bit_stream_s *, unsigned int );
void UnalignedRemoveBits( struct bit_stream_s * ); void UnalignedRemoveBits( struct bit_stream_s * );
u32 UnalignedGetBits( struct bit_stream_s *, unsigned int ); u32 UnalignedGetBits( struct bit_stream_s *, unsigned int );
...@@ -254,19 +254,7 @@ static __inline__ u32 ShowBits( bit_stream_t * p_bit_stream, ...@@ -254,19 +254,7 @@ static __inline__ u32 ShowBits( bit_stream_t * p_bit_stream,
>> (8 * sizeof(WORD_TYPE) - i_bits) ); >> (8 * sizeof(WORD_TYPE) - i_bits) );
} }
UnalignedShowBits( p_bit_stream, i_bits ); return( UnalignedShowBits( p_bit_stream, i_bits ) );
/* Now that we have filled in the buffers, do it again. Can't call
* ShowBits() instead, because the function is inline... */
if( p_bit_stream->fifo.i_available >= i_bits )
{
return( p_bit_stream->fifo.buffer >> (8 * sizeof(WORD_TYPE) - i_bits) );
}
return( (p_bit_stream->fifo.buffer |
(WORD_AT( p_bit_stream->p_byte )
>> p_bit_stream->fifo.i_available))
>> (8 * sizeof(WORD_TYPE) - i_bits) );
} }
/***************************************************************************** /*****************************************************************************
...@@ -508,38 +496,6 @@ static __inline__ void GetChunk( bit_stream_t * p_bit_stream, ...@@ -508,38 +496,6 @@ static __inline__ void GetChunk( bit_stream_t * p_bit_stream,
} }
/*
* The following functions are now deprecated.
*/
static __inline__ byte_t _GetByte( bit_stream_t * p_bit_stream )
{
if ( p_bit_stream->p_byte >= p_bit_stream->p_end )
{
p_bit_stream->pf_next_data_packet( p_bit_stream );
}
return( *(p_bit_stream->p_byte++) );
}
static __inline__ void NeedBits( bit_stream_t * p_bit_stream, int i_bits )
{
while ( p_bit_stream->fifo.i_available < i_bits )
{
p_bit_stream->fifo.buffer |= ((WORD_TYPE)_GetByte( p_bit_stream ))
<< (8 * sizeof(WORD_TYPE) - 8
- p_bit_stream->fifo.i_available);
p_bit_stream->fifo.i_available += 8;
}
}
static __inline__ void DumpBits( bit_stream_t * p_bit_stream, int i_bits )
{
p_bit_stream->fifo.buffer <<= i_bits;
p_bit_stream->fifo.i_available -= i_bits;
}
/* /*
* Communication interface between input and decoders * Communication interface between input and decoders
*/ */
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* input_ext-dec.c: services to the decoders * input_ext-dec.c: services to the decoders
***************************************************************************** *****************************************************************************
* Copyright (C) 1998, 1999, 2000 VideoLAN * Copyright (C) 1998, 1999, 2000 VideoLAN
* $Id: input_ext-dec.c,v 1.19 2001/09/24 11:17:49 massiot Exp $ * $Id: input_ext-dec.c,v 1.20 2001/10/03 12:46:17 massiot Exp $
* *
* Authors: Christophe Massiot <massiot@via.ecp.fr> * Authors: Christophe Massiot <massiot@via.ecp.fr>
* *
...@@ -153,7 +153,7 @@ void NextDataPacket( bit_stream_t * p_bit_stream ) ...@@ -153,7 +153,7 @@ void NextDataPacket( bit_stream_t * p_bit_stream )
* UnalignedShowBits : places i_bits bits into the bit buffer, even when * UnalignedShowBits : places i_bits bits into the bit buffer, even when
* not aligned on a word boundary * not aligned on a word boundary
*****************************************************************************/ *****************************************************************************/
void UnalignedShowBits( bit_stream_t * p_bit_stream, unsigned int i_bits ) u32 UnalignedShowBits( bit_stream_t * p_bit_stream, unsigned int i_bits )
{ {
/* We just fill in the bit buffer. */ /* We just fill in the bit buffer. */
while( p_bit_stream->fifo.i_available < i_bits ) while( p_bit_stream->fifo.i_available < i_bits )
...@@ -221,6 +221,9 @@ void UnalignedShowBits( bit_stream_t * p_bit_stream, unsigned int i_bits ) ...@@ -221,6 +221,9 @@ void UnalignedShowBits( bit_stream_t * p_bit_stream, unsigned int i_bits )
break; break;
} }
} }
/* It shouldn't loop :-)) */
return( ShowBits( p_bit_stream, i_bits ) );
} }
/***************************************************************************** /*****************************************************************************
......
...@@ -108,7 +108,7 @@ install vlc-ncurses ...@@ -108,7 +108,7 @@ install vlc-ncurses
--enable-esd --disable-alsa \ --enable-esd --disable-alsa \
--enable-fb \ --enable-fb \
--enable-xvideo \ --enable-xvideo \
--with-sdl --enable-sdl
export QTDIR=%{_libdir}/qt2 export QTDIR=%{_libdir}/qt2
%make %make
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment