[MPlayer-cvslog] r26790 - in trunk/libmpdemux: demux_avs.h demux_film.c demux_fli.c demux_xmms.c demuxer.c muxer_mpeg.c
diego
subversion at mplayerhq.hu
Fri May 16 11:41:01 CEST 2008
Author: diego
Date: Fri May 16 11:41:00 2008
New Revision: 26790
Log:
cosmetics: Remove pointless parentheses from return statements.
Modified:
trunk/libmpdemux/demux_avs.h
trunk/libmpdemux/demux_film.c
trunk/libmpdemux/demux_fli.c
trunk/libmpdemux/demux_xmms.c
trunk/libmpdemux/demuxer.c
trunk/libmpdemux/muxer_mpeg.c
Modified: trunk/libmpdemux/demux_avs.h
==============================================================================
--- trunk/libmpdemux/demux_avs.h (original)
+++ trunk/libmpdemux/demux_avs.h Fri May 16 11:41:00 2008
@@ -132,15 +132,15 @@ static inline AVS_Value avs_new_value_ar
static inline int avs_is_error(AVS_Value v) { return v.type == 'e'; }
static inline int avs_is_clip(AVS_Value v) { return v.type == 'c'; }
static inline int avs_is_string(AVS_Value v) { return v.type == 's'; }
-static inline int avs_has_video(const AVS_VideoInfo * p) { return (p->width!=0); }
-static inline int avs_has_audio(const AVS_VideoInfo * p) { return (p->audio_samples_per_second!=0); }
+static inline int avs_has_video(const AVS_VideoInfo * p) { return p->width != 0; }
+static inline int avs_has_audio(const AVS_VideoInfo * p) { return p->audio_samples_per_second != 0; }
static inline const char * avs_as_string(AVS_Value v)
{ return avs_is_error(v) || avs_is_string(v) ? v.d.string : 0; }
/* Color spaces */
static inline int avs_is_rgb(const AVS_VideoInfo * p)
-{ return (p->pixel_type&AVS_CS_BGR); }
+{ return p->pixel_type & AVS_CS_BGR; }
static inline int avs_is_rgb24(const AVS_VideoInfo * p)
{ return (p->pixel_type&AVS_CS_BGR24)==AVS_CS_BGR24; } // Clear out additional properties
@@ -149,7 +149,7 @@ static inline int avs_is_rgb32(const AVS
{ return (p->pixel_type & AVS_CS_BGR32) == AVS_CS_BGR32 ; }
static inline int avs_is_yuy(const AVS_VideoInfo * p)
-{ return (p->pixel_type&AVS_CS_YUV ); }
+{ return p->pixel_type & AVS_CS_YUV; }
static inline int avs_is_yuy2(const AVS_VideoInfo * p)
{ return (p->pixel_type & AVS_CS_YUY2) == AVS_CS_YUY2; }
Modified: trunk/libmpdemux/demux_film.c
==============================================================================
--- trunk/libmpdemux/demux_film.c (original)
+++ trunk/libmpdemux/demux_film.c Fri May 16 11:41:00 2008
@@ -238,7 +238,7 @@ static demuxer_t* demux_open_film(demuxe
{
mp_msg(MSGT_DEMUX, MSGL_ERR, "Not a FILM file\n");
free(film_data);
- return(NULL);
+ return NULL;
}
// get the header size, which implicitly points past the header and
@@ -428,7 +428,7 @@ static demuxer_t* demux_open_film(demuxe
default:
mp_msg(MSGT_DEMUX, MSGL_ERR, "Unrecognized FILM header chunk: %08X\n",
chunk_type);
- return(NULL);
+ return NULL;
break;
}
}
Modified: trunk/libmpdemux/demux_fli.c
==============================================================================
--- trunk/libmpdemux/demux_fli.c (original)
+++ trunk/libmpdemux/demux_fli.c Fri May 16 11:41:00 2008
@@ -95,7 +95,7 @@ static demuxer_t* demux_open_fli(demuxer
magic_number);
free(header);
free(frames);
- return(NULL);
+ return NULL;
}
// fetch the number of frames
Modified: trunk/libmpdemux/demux_xmms.c
==============================================================================
--- trunk/libmpdemux/demux_xmms.c (original)
+++ trunk/libmpdemux/demux_xmms.c Fri May 16 11:41:00 2008
@@ -75,8 +75,8 @@ static void disk_flush(int time) {
}
static int disk_free(void) { // vqf plugin sends more than it should
- return (XMMS_PACKETSIZE-xmms_audiopos<XMMS_PACKETSIZE/4 ?
- 0:XMMS_PACKETSIZE-xmms_audiopos-XMMS_PACKETSIZE/4);
+ return XMMS_PACKETSIZE - xmms_audiopos < XMMS_PACKETSIZE / 4 ?
+ 0 : XMMS_PACKETSIZE - xmms_audiopos - XMMS_PACKETSIZE / 4;
}
static int disk_playing(void) {
Modified: trunk/libmpdemux/demuxer.c
==============================================================================
--- trunk/libmpdemux/demuxer.c (original)
+++ trunk/libmpdemux/demuxer.c Fri May 16 11:41:00 2008
@@ -1236,7 +1236,7 @@ int demuxer_seek_chapter(demuxer_t *demu
}
}
- return (ris != STREAM_UNSUPPORTED ? chapter : -1);
+ return ris != STREAM_UNSUPPORTED ? chapter : -1;
} else { //chapters structure is set in the demuxer
total = demuxer->num_chapters;
Modified: trunk/libmpdemux/muxer_mpeg.c
==============================================================================
--- trunk/libmpdemux/muxer_mpeg.c (original)
+++ trunk/libmpdemux/muxer_mpeg.c Fri May 16 11:41:00 2008
@@ -231,27 +231,25 @@ static void fix_audio_sys_header(muxer_p
static inline int is_mpeg1(uint32_t x)
{
- return (
+ return
(x == 0x10000001) ||
(x == mmioFOURCC('m','p','g','1')) ||
- (x == mmioFOURCC('M','P','G','1'))
- );
+ (x == mmioFOURCC('M','P','G','1'));
}
static inline int is_mpeg2(uint32_t x)
{
- return (
+ return
(x == 0x10000002) ||
(x == mmioFOURCC('m','p','g','2')) ||
(x == mmioFOURCC('M','P','G','2')) ||
(x == mmioFOURCC('m','p','e','g')) ||
- (x == mmioFOURCC('M','P','E','G'))
- );
+ (x == mmioFOURCC('M','P','E','G'));
}
static inline int is_mpeg4(uint32_t x)
{
- return (
+ return
(x == 0x10000004) ||
(x == mmioFOURCC('d','i','v','x')) ||
(x == mmioFOURCC('D','I','V','X')) ||
@@ -265,8 +263,7 @@ static inline int is_mpeg4(uint32_t x)
(x == mmioFOURCC('F', 'M','P','4')) ||
(x == mmioFOURCC('f', 'm','p','4')) ||
(x == mmioFOURCC('D', 'X','5','0')) ||
- (x == mmioFOURCC('d', 'x','5','0'))
- );
+ (x == mmioFOURCC('d', 'x','5','0'));
}
//from unrarlib.c
@@ -666,7 +663,7 @@ static int write_mpeg_psm(muxer_t *muxer
static int psm_is_late(muxer_priv_t *priv)
{
- return (!priv->data_size || (priv->scr >= priv->last_psm_scr + 27000000ULL));
+ return !priv->data_size || (priv->scr >= priv->last_psm_scr + 27000000ULL);
}
static int write_mpeg_pes_header(muxer_headers_t *h, uint8_t *pes_id, uint8_t *buff, uint16_t plen, int stuffing_len, int mux_type)
More information about the MPlayer-cvslog
mailing list