# HG changeset patch # User diego # Date 1210926807 0 # Node ID 46f0b4d34fa1b00aa59b77f9efdd3e6a962386f0 # Parent 63630c09e23712d9416ac32ecfcce5acfdebff4a cosmetics: Remove useless parentheses from from return statements. diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/mga_common.c --- a/libvo/mga_common.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/mga_common.c Fri May 16 08:33:27 2008 +0000 @@ -368,7 +368,7 @@ mga_vid_config.format=MGA_VID_FORMAT_UYVY; break; default: mp_msg(MSGT_VO,MSGL_WARN, MSGTR_LIBVO_MGA_InvalidOutputFormat,format); - return (-1); + return -1; } mga_vid_config.src_width = width; @@ -386,7 +386,7 @@ if(width > 1024 && height > 1024) { mp_msg(MSGT_VO,MSGL_ERR, MGSTR_LIBVO_MGA_ResolutionTooHigh); - return (-1); + return -1; } else if(height <= 1024) { // try whether we have a G550 @@ -397,7 +397,7 @@ { // we don't have a G550, so our resolution is too high mp_msg(MSGT_VO,MSGL_ERR, MGSTR_LIBVO_MGA_ResolutionTooHigh); - return (-1); + return -1; } else { // there is a deeper problem // we have a G550, but still couldn't configure mga_vid @@ -457,7 +457,7 @@ { perror("open"); mp_msg(MSGT_VO,MSGL_WARN, MSGTR_LIBVO_MGA_CouldntOpen,devname); - return(-1); + return -1; } #ifdef VO_XMGA diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_cvidix.c --- a/libvo/vo_cvidix.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_cvidix.c Fri May 16 08:33:27 2008 +0000 @@ -134,7 +134,7 @@ } static int query_format(uint32_t format){ - return(vidix_query_fourcc(format)); + return vidix_query_fourcc(format); } static void uninit(void){ diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_dfbmga.c --- a/libvo/vo_dfbmga.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_dfbmga.c Fri May 16 08:33:27 2008 +0000 @@ -917,11 +917,11 @@ return 0; } - return (VFCAP_HWSCALE_UP | + return VFCAP_HWSCALE_UP | VFCAP_HWSCALE_DOWN | VFCAP_CSP_SUPPORTED_BY_HW | VFCAP_CSP_SUPPORTED | - VFCAP_OSD); + VFCAP_OSD; } static void diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_dga.c --- a/libvo/vo_dga.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_dga.c Fri May 16 08:33:27 2008 +0000 @@ -119,11 +119,11 @@ static int vd_ModeEqual(int depth, int bitspp, int rmask, int gmask, int bmask, int index) { - return ((vo_dga_modes[index].vdm_depth == depth && + return (vo_dga_modes[index].vdm_depth == depth && vo_dga_modes[index].vdm_bitspp == bitspp && vo_dga_modes[index].vdm_rmask == rmask && vo_dga_modes[index].vdm_gmask == gmask && - vo_dga_modes[index].vdm_bmask == bmask) ? 1 : 0); + vo_dga_modes[index].vdm_bmask == bmask) ? 1 : 0; } @@ -964,7 +964,7 @@ || (mpi->type == MP_IMGTYPE_STATIC && vo_dga_nr_video_buffers > 1) || (mpi->type == MP_IMGTYPE_IP && vo_dga_nr_video_buffers < 2) || (mpi->type == MP_IMGTYPE_IPB)) - return (VO_FALSE); + return VO_FALSE; if ((mpi->flags & MP_IMGFLAG_ACCEPT_STRIDE) || (mpi->flags & MP_IMGFLAG_ACCEPT_WIDTH && @@ -978,10 +978,10 @@ mpi->width = (vo_dga_bytes_per_line + vo_dga_vp_skip) / (mpi->bpp / 8); mpi->flags |= MP_IMGFLAG_DIRECT; - return (VO_TRUE); + return VO_TRUE; } - return (VO_FALSE); + return VO_FALSE; } static int control(uint32_t request, void *data, ...) diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_directfb2.c --- a/libvo/vo_directfb2.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_directfb2.c Fri May 16 08:33:27 2008 +0000 @@ -1429,7 +1429,7 @@ value = va_arg(ap, int); va_end(ap); - return(directfb_set_video_eq(data, value)); + return directfb_set_video_eq(data, value); } case VOCTRL_GET_EQUALIZER: { @@ -1440,7 +1440,7 @@ value = va_arg(ap, int*); va_end(ap); - return(directfb_get_video_eq(data, value)); + return directfb_get_video_eq(data, value); } }; return VO_NOTIMPL; diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_fbdev.c --- a/libvo/vo_fbdev.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_fbdev.c Fri May 16 08:33:27 2008 +0000 @@ -1038,7 +1038,7 @@ return 0; #ifdef CONFIG_VIDIX if(vidix_name) - return (vidix_query_fourcc(format)); + return vidix_query_fourcc(format); #endif if ((format & IMGFMT_BGR_MASK) == IMGFMT_BGR) { int bpp = format & 0xff; @@ -1140,8 +1140,8 @@ fb_dev_name = strdup(vo_subdevice); } } - if(!pre_init_err) return (pre_init_err=(fb_preinit(0)?0:-1)); - return(-1); + if(!pre_init_err) return pre_init_err = (fb_preinit(0) ? 0 : -1); + return -1; } static uint32_t get_image(mp_image_t *mpi) @@ -1155,12 +1155,12 @@ (mpi->width != in_width) || (mpi->height != in_height) ) - return(VO_FALSE); + return VO_FALSE; mpi->planes[0] = center; mpi->stride[0] = fb_line_len; mpi->flags |= MP_IMGFLAG_DIRECT; - return(VO_TRUE); + return VO_TRUE; } static int control(uint32_t request, void *data, ...) diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_ggi.c --- a/libvo/vo_ggi.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_ggi.c Fri May 16 08:33:27 2008 +0000 @@ -141,17 +141,17 @@ if (ggiSetMode(ggi_conf.vis, &mode) < 0) { mp_msg(MSGT_VO, MSGL_ERR, "[ggi] unable to set display mode\n"); - return (-1); + return -1; } if (ggiGetMode(ggi_conf.vis, &mode) < 0) { mp_msg(MSGT_VO, MSGL_ERR, "[ggi] unable to get display mode\n"); - return (-1); + return -1; } if ((mode.graphtype == GT_INVALID) || (mode.graphtype == GT_AUTO)) { mp_msg(MSGT_VO, MSGL_ERR, "[ggi] not supported depth/bpp\n"); - return (-1); + return -1; } #if 0 @@ -221,7 +221,7 @@ } else { mp_msg(MSGT_VO, MSGL_FATAL, "[ggi] Unknown image format: %s\n", vo_format_name(ggi_conf.srcformat)); - return (-1); + return -1; } mp_msg(MSGT_VO, MSGL_INFO, "[ggi] input: %dx%dx%d, output: %dx%dx%d\n", @@ -235,7 +235,7 @@ ggi_conf.flushregion.x2 = vo_dwidth; ggi_conf.flushregion.y2 = vo_dheight; - return (0); + return 0; } static uint32_t get_image(mp_image_t *mpi) @@ -244,19 +244,19 @@ if (!((IMGFMT_IS_BGR(mpi->imgfmt)) && (IMGFMT_BGR_DEPTH(mpi->imgfmt) == vo_dbpp))) { - return (VO_FALSE); + return VO_FALSE; } if (!((IMGFMT_IS_RGB(mpi->imgfmt)) && (IMGFMT_RGB_DEPTH(mpi->imgfmt) == vo_dbpp))) { - return (VO_FALSE); + return VO_FALSE; } if (!((mpi->width == ggi_conf.srcwidth) && (mpi->height == ggi_conf.srcheight))) { - return (VO_FALSE); + return VO_FALSE; } mpi->planes[1] = mpi->planes[2] = NULL; @@ -272,7 +272,7 @@ } #endif - return (VO_TRUE); + return VO_TRUE; } @@ -286,7 +286,7 @@ ggi_conf.flushregion.x2 = vo_dwidth; ggi_conf.flushregion.y2 = vo_dheight; - return (0); + return 0; } static void draw_osd(void) @@ -346,7 +346,7 @@ ggi_conf.flushregion.y2 = vo_dy + y + h; } - return (1); + return 1; } static int query_format(uint32_t format) @@ -386,19 +386,19 @@ return vfcap; } } - return (0); + return 0; } static int preinit(const char *arg) { if (ggiInit() != 0) { mp_msg(MSGT_VO, MSGL_FATAL, "[ggi] unable to initialize GGI\n"); - return (-1); + return -1; } #ifdef HAVE_GGIWMH if (ggiWmhInit() < 0) { mp_msg(MSGT_VO, MSGL_FATAL, "[ggi] unable to initialize libggiwmh\n"); - return (-1); + return -1; } #endif @@ -419,7 +419,7 @@ mp_msg(MSGT_VO, MSGL_FATAL, "[ggi] unable to open '%s' output\n", (ggi_conf.driver == NULL) ? "default" : ggi_conf.driver); ggiExit(); - return (-1); + return -1; } ggi_conf.drawvis = ggi_conf.vis; diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_gl.c --- a/libvo/vo_gl.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_gl.c Fri May 16 08:33:27 2008 +0000 @@ -915,8 +915,8 @@ static int control(uint32_t request, void *data, ...) { switch (request) { - case VOCTRL_PAUSE: return (int_pause=1); - case VOCTRL_RESUME: return (int_pause=0); + case VOCTRL_PAUSE: return int_pause = 1; + case VOCTRL_RESUME: return int_pause = 0; case VOCTRL_QUERY_FORMAT: return query_format(*((uint32_t*)data)); case VOCTRL_GET_IMAGE: diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_gl2.c --- a/libvo/vo_gl2.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_gl2.c Fri May 16 08:33:27 2008 +0000 @@ -870,8 +870,8 @@ static int control(uint32_t request, void *data, ...) { switch (request) { - case VOCTRL_PAUSE: return (int_pause=1); - case VOCTRL_RESUME: return (int_pause=0); + case VOCTRL_PAUSE: return int_pause = 1; + case VOCTRL_RESUME: return int_pause = 0; case VOCTRL_QUERY_FORMAT: return query_format(*((uint32_t*)data)); case VOCTRL_GUISUPPORT: diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_macosx.m --- a/libvo/vo_macosx.m Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_macosx.m Fri May 16 08:33:27 2008 +0000 @@ -363,8 +363,8 @@ { switch (request) { - case VOCTRL_PAUSE: return (int_pause=1); - case VOCTRL_RESUME: return (int_pause=0); + case VOCTRL_PAUSE: return int_pause = 1; + case VOCTRL_RESUME: return int_pause = 0; case VOCTRL_QUERY_FORMAT: return query_format(*((uint32_t*)data)); case VOCTRL_ONTOP: vo_ontop = (!(vo_ontop)); if(!shared_buffer){ [mpGLView ontop]; } else { [mplayerosxProto ontop]; } return VO_TRUE; case VOCTRL_ROOTWIN: vo_rootwin = (!(vo_rootwin)); [mpGLView rootwin]; return VO_TRUE; diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_quartz.c --- a/libvo/vo_quartz.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_quartz.c Fri May 16 08:33:27 2008 +0000 @@ -1236,8 +1236,8 @@ { switch (request) { - case VOCTRL_PAUSE: return (int_pause=1); - case VOCTRL_RESUME: return (int_pause=0); + case VOCTRL_PAUSE: return int_pause = 1; + case VOCTRL_RESUME: return int_pause = 0; case VOCTRL_FULLSCREEN: vo_fs = (!(vo_fs)); window_fullscreen(); return VO_TRUE; case VOCTRL_ONTOP: vo_ontop = (!(vo_ontop)); window_ontop(); return VO_TRUE; case VOCTRL_QUERY_FORMAT: return query_format(*((uint32_t*)data)); diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_svga.c --- a/libvo/vo_svga.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_svga.c Fri May 16 08:33:27 2008 +0000 @@ -574,7 +574,7 @@ #endif vga_setdisplaystart(0); - return (0); + return 0; } static int draw_slice(uint8_t *image[],int stride[], @@ -723,7 +723,7 @@ if(!IMGFMT_IS_BGR(mpi->imgfmt) && !IMGFMT_IS_RGB(mpi->imgfmt) ){ assert(0);//should never happen - return(VO_FALSE); + return VO_FALSE; } if ( @@ -731,7 +731,7 @@ (mpi->flags & MP_IMGFLAG_PLANAR) || (mpi->flags & MP_IMGFLAG_YUV) ) - return(VO_FALSE); + return VO_FALSE; //reading from video memory is horribly slow if( !(mpi->flags & MP_IMGFLAG_READABLE) && vo_directrendering && @@ -749,9 +749,9 @@ mpi->priv=(void *)page; if( mp_msg_test(MSGT_VO,MSGL_DBG3) ) mp_msg(MSGT_VO,MSGL_DBG3, "vo_svga: direct render allocated! page=%d\n",page); - return(VO_TRUE); + return VO_TRUE; } } - return(VO_FALSE); + return VO_FALSE; } diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_tga.c --- a/libvo/vo_tga.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_tga.c Fri May 16 08:33:27 2008 +0000 @@ -165,7 +165,7 @@ if (er) { fprintf(stderr, "Error writing file [%s]\n", file); } - return(er); + return er; } static uint32_t draw_image(mp_image_t* mpi) diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_vesa.c --- a/libvo/vo_vesa.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_vesa.c Fri May 16 08:33:27 2008 +0000 @@ -460,7 +460,7 @@ if( mp_msg_test(MSGT_VO,MSGL_DBG3) ) mp_msg(MSGT_VO,MSGL_DBG3, "vo_vesa: query_format was called: %x (%s)\n",format,vo_format_name(format)); #ifdef CONFIG_VIDIX - if(vidix_name)return(vidix_query_fourcc(format)); + if(vidix_name) return vidix_query_fourcc(format); #endif if (format == IMGFMT_MPEGPES) return 0; diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_winvidix.c --- a/libvo/vo_winvidix.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_winvidix.c Fri May 16 08:33:27 2008 +0000 @@ -256,7 +256,7 @@ ShowWindow(hWnd,SW_SHOW); if(vo_fs)ShowWindow(hWndFS,SW_SHOW); - return(0); + return 0; } static void check_events(void){ @@ -288,17 +288,17 @@ UNUSED(x); UNUSED(y); mp_msg(MSGT_VO, MSGL_FATAL, "[winvidix] error: didn't use vidix draw_slice!\n"); - return(-1); + return -1; } static int draw_frame(uint8_t *src[]){ UNUSED(src); mp_msg(MSGT_VO, MSGL_FATAL, "[winvidix] error: didn't use vidix draw_frame!\n"); - return(-1); + return -1; } static int query_format(uint32_t format){ - return(vidix_query_fourcc(format)); + return vidix_query_fourcc(format); } static void uninit(void){ @@ -324,9 +324,9 @@ } if (vidix_preinit(vidix_name, &video_out_winvidix) != 0) - return(1); + return 1; - return(0); + return 0; } static int control(uint32_t request, void *data, ...){ diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_x11.c --- a/libvo/vo_x11.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_x11.c Fri May 16 08:33:27 2008 +0000 @@ -667,7 +667,7 @@ || (mpi->flags & MP_IMGFLAG_PLANAR) || (mpi->flags & MP_IMGFLAG_YUV) || (mpi->width != image_width) || (mpi->height != image_height)) - return (VO_FALSE); + return VO_FALSE; if (Flip_Flag) { @@ -680,7 +680,7 @@ } mpi->flags |= MP_IMGFLAG_DIRECT; - return (VO_TRUE); + return VO_TRUE; } static int query_format(uint32_t format) @@ -753,9 +753,9 @@ switch (request) { case VOCTRL_PAUSE: - return (int_pause = 1); + return int_pause = 1; case VOCTRL_RESUME: - return (int_pause = 0); + return int_pause = 0; case VOCTRL_QUERY_FORMAT: return query_format(*((uint32_t *) data)); case VOCTRL_GUISUPPORT: diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_xover.c --- a/libvo/vo_xover.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_xover.c Fri May 16 08:33:27 2008 +0000 @@ -332,7 +332,7 @@ panscan_calc(); - return(0); + return 0; } static void check_events(void) diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_xv.c --- a/libvo/vo_xv.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_xv.c Fri May 16 08:33:27 2008 +0000 @@ -852,9 +852,9 @@ switch (request) { case VOCTRL_PAUSE: - return (int_pause = 1); + return int_pause = 1; case VOCTRL_RESUME: - return (int_pause = 0); + return int_pause = 0; case VOCTRL_QUERY_FORMAT: return query_format(*((uint32_t *) data)); case VOCTRL_GET_IMAGE: @@ -902,7 +902,7 @@ va_end(ap); - return (vo_xv_set_eq(xv_port, data, value)); + return vo_xv_set_eq(xv_port, data, value); } case VOCTRL_GET_EQUALIZER: { @@ -914,7 +914,7 @@ va_end(ap); - return (vo_xv_get_eq(xv_port, data, value)); + return vo_xv_get_eq(xv_port, data, value); } case VOCTRL_ONTOP: vo_x11_ontop(); diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_xvidix.c --- a/libvo/vo_xvidix.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_xvidix.c Fri May 16 08:33:27 2008 +0000 @@ -378,7 +378,7 @@ if (vo_ontop) vo_x11_setlayer(mDisplay, vo_window, vo_ontop); - return (0); + return 0; } static void check_events(void) @@ -418,7 +418,7 @@ UNUSED(y); mp_msg(MSGT_VO, MSGL_FATAL, "[xvidix] error: didn't used vidix draw_slice!\n"); - return (-1); + return -1; } static int draw_frame(uint8_t * src[]) @@ -426,12 +426,12 @@ UNUSED(src); mp_msg(MSGT_VO, MSGL_FATAL, "[xvidix] error: didn't used vidix draw_frame!\n"); - return (-1); + return -1; } static int query_format(uint32_t format) { - return (vidix_query_fourcc(format)); + return vidix_query_fourcc(format); } static void uninit(void) @@ -462,12 +462,12 @@ } if (!vo_init()) - return (-1); + return -1; if (vidix_preinit(vidix_name, &video_out_xvidix) != 0) - return (1); + return 1; - return (0); + return 0; } static int control(uint32_t request, void *data, ...) diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vo_xvmc.c --- a/libvo/vo_xvmc.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vo_xvmc.c Fri May 16 08:33:27 2008 +0000 @@ -1410,7 +1410,7 @@ value = va_arg(ap, int); va_end(ap); - return(vo_xv_set_eq(xv_port, data, value)); + return vo_xv_set_eq(xv_port, data, value); } case VOCTRL_GET_EQUALIZER: @@ -1422,7 +1422,7 @@ value = va_arg(ap, int*); va_end(ap); - return(vo_xv_get_eq(xv_port, data, value)); + return vo_xv_get_eq(xv_port, data, value); } case VOCTRL_UPDATE_SCREENINFO: update_xinerama_info(); diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/vosub_vidix.c --- a/libvo/vosub_vidix.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/vosub_vidix.c Fri May 16 08:33:27 2008 +0000 @@ -318,17 +318,17 @@ int vidix_grkey_support(void) { - return(vidix_fourcc.flags & VID_CAP_COLORKEY); + return vidix_fourcc.flags & VID_CAP_COLORKEY; } int vidix_grkey_get(vidix_grkey_t *gr_key) { - return(vdlGetGrKeys(vidix_handler, gr_key)); + return vdlGetGrKeys(vidix_handler, gr_key); } int vidix_grkey_set(const vidix_grkey_t *gr_key) { - return(vdlSetGrKeys(vidix_handler, gr_key)); + return vdlSetGrKeys(vidix_handler, gr_key); } diff -r 63630c09e237 -r 46f0b4d34fa1 libvo/x11_common.c --- a/libvo/x11_common.c Fri May 16 00:23:02 2008 +0000 +++ b/libvo/x11_common.c Fri May 16 08:33:27 2008 +0000 @@ -279,11 +279,11 @@ int format; unsigned long bytesafter; - return (Success == + return Success == XGetWindowProperty(mDisplay, mRootWin, type, 0, 16384, False, AnyPropertyType, &type, &format, nitems, &bytesafter, (unsigned char **) args) - && *nitems > 0); + && *nitems > 0; } static int vo_wm_detect(void) @@ -2102,10 +2102,10 @@ (port_value + 100) * (port_max - port_min) / 200 + port_min; XvSetPortAttribute(mDisplay, xv_port, xv_atom, port_value); - return (VO_TRUE); + return VO_TRUE; } } - return (VO_FALSE); + return VO_FALSE; } int vo_xv_get_eq(uint32_t xv_port, char *name, int *value) @@ -2168,10 +2168,10 @@ mp_dbg(MSGT_VO, MSGL_V, "xv_get_eq called! (%s, %d)\n", name, *value); - return (VO_TRUE); + return VO_TRUE; } } - return (VO_FALSE); + return VO_FALSE; } /** \brief contains flags changing the execution of the colorkeying code */