[MPlayer-cvslog] r25061 - trunk/libmpdemux/demux_mf.c

Rich Felker dalias at aerifal.cx
Sun Nov 18 09:10:43 CET 2007


On Sat, Nov 17, 2007 at 06:27:31PM +0100, reimar wrote:
> Author: reimar
> Date: Sat Nov 17 18:27:30 2007
> New Revision: 25061
> 
> Log:
> Replace if-else constructs for type -> fourcc mapping by a table in demux_mf
> 
> 
> Modified:
>    trunk/libmpdemux/demux_mf.c
> 
> Modified: trunk/libmpdemux/demux_mf.c
> ==============================================================================
> --- trunk/libmpdemux/demux_mf.c	(original)
> +++ trunk/libmpdemux/demux_mf.c	Sat Nov 17 18:27:30 2007
> @@ -62,9 +62,24 @@ static int demux_mf_fill_buffer(demuxer_
>    return 1;
>  }
>  
> +static const struct {
> +  const char *type;
> +  uint32_t *format;
> +} type2format[] = {
> +  { "bmp",  mmioFOURCC('b', 'm', 'p', ' ') },

Why is this uint32_t * and not uint32_t ? Am I missing something??
Also, const char type[5]; would probably be saner than const char
*type.. If nothing else it will be smaller on 64bit and no worse on
32bit.

Rich



More information about the MPlayer-cvslog mailing list