From c1f5c9bd3fa0b963e1d5d938fc9ffc3fc074e071 Mon Sep 17 00:00:00 2001 From: diego Date: Fri, 16 May 2008 00:23:02 +0000 Subject: cosmetics: Remove pointless parentheses from return calls. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@26786 b3059339-0415-0410-9bf9-f77b7e298cf2 --- libmpcodecs/ve_xvid4.c | 72 +++++++++++++++++++++++++------------------------- 1 file changed, 36 insertions(+), 36 deletions(-) (limited to 'libmpcodecs/ve_xvid4.c') diff --git a/libmpcodecs/ve_xvid4.c b/libmpcodecs/ve_xvid4.c index 73b9d0631a..6b50885647 100644 --- a/libmpcodecs/ve_xvid4.c +++ b/libmpcodecs/ve_xvid4.c @@ -405,14 +405,14 @@ config(struct vf_instance_s* vf, mod->d_height = d_height; if(dispatch_settings(mod) == BAD) - return(BAD); + return BAD; /*-------------------------------------------------------------------- * Set remaining information in the xvid_enc_create_t structure *------------------------------------------------------------------*/ if(set_create_struct(mod) == BAD) - return(BAD); + return BAD; /*-------------------------------------------------------------------- * Encoder instance creation @@ -423,7 +423,7 @@ config(struct vf_instance_s* vf, if(err<0) { mp_msg(MSGT_MENCODER, MSGL_ERR, "xvid: xvidcore returned a '%s' error\n", errorstring(err)); - return(BAD); + return BAD; } /* Store the encoder instance into the private data */ @@ -431,7 +431,7 @@ config(struct vf_instance_s* vf, mod->mux->decoder_delay = mod->create.max_bframes ? 1 : 0; - return(FINE); + return FINE; } /*============================================================================ @@ -487,7 +487,7 @@ xvid_mplayer_module_t *mod = (xvid_mplayer_module_t *)vf->priv; flush_internal_buffers(mod); break; } - return(CONTROL_UNKNOWN); + return CONTROL_UNKNOWN; } /*============================================================================ @@ -501,12 +501,12 @@ query_format(struct vf_instance_s* vf, unsigned int fmt) case IMGFMT_YV12: case IMGFMT_IYUV: case IMGFMT_I420: - return(VFCAP_CSP_SUPPORTED | VFCAP_CSP_SUPPORTED_BY_HW); + return VFCAP_CSP_SUPPORTED | VFCAP_CSP_SUPPORTED_BY_HW; case IMGFMT_YUY2: case IMGFMT_UYVY: - return(VFCAP_CSP_SUPPORTED); + return VFCAP_CSP_SUPPORTED; } - return(BAD); + return BAD; } /*============================================================================ @@ -531,7 +531,7 @@ put_image(struct vf_instance_s* vf, mp_image_t *mpi, double pts) * -----------------------------------------------------------------*/ if(set_frame_struct(mod, mpi) == BAD) - return(BAD); + return BAD; /* ------------------------------------------------------------------- * Encode the frame @@ -543,13 +543,13 @@ put_image(struct vf_instance_s* vf, mp_image_t *mpi, double pts) if(size<0) { mp_msg(MSGT_MENCODER, MSGL_ERR, "xvid: xvidcore returned a '%s' error\n", errorstring(size)); - return(BAD); + return BAD; } /* If size is == 0, we're done with that frame */ if(size == 0) { ++mod->mux->encoder_delay; - return(FINE); + return FINE; } /* xvidcore returns stats about encoded frame in an asynchronous way @@ -561,7 +561,7 @@ put_image(struct vf_instance_s* vf, mp_image_t *mpi, double pts) size, (mod->frame.out_flags & XVID_KEYFRAME)?0x10:0, MP_NOPTS_VALUE, MP_NOPTS_VALUE); - return(FINE); + return FINE; } /*============================================================================ @@ -590,7 +590,7 @@ vf_open(vf_instance_t *vf, char* args) if(mod == NULL) { mp_msg(MSGT_MENCODER,MSGL_ERR, "xvid: memory allocation failure (private data)\n"); - return(BAD); + return BAD; } /* Initialize the module to zeros */ @@ -607,7 +607,7 @@ vf_open(vf_instance_t *vf, char* args) if(mod->mux->bih == NULL) { mp_msg(MSGT_MENCODER,MSGL_ERR, "xvid: memory allocation failure (BITMAP header)\n"); - return(BAD); + return BAD; } mod->mux->bih->biSize = sizeof(BITMAPINFOHEADER); @@ -639,10 +639,10 @@ vf_open(vf_instance_t *vf, char* args) /* Initialize the xvidcore library */ if (xvid_global(NULL, XVID_GBL_INIT, &xvid_gbl_init, NULL) < 0) { mp_msg(MSGT_MENCODER,MSGL_ERR, "xvid: initialisation failure\n"); - return(BAD); + return BAD; } - return(FINE); + return FINE; } /***************************************************************************** @@ -679,7 +679,7 @@ static int dispatch_settings(xvid_mplayer_module_t *mod) { mp_msg(MSGT_MENCODER,MSGL_ERR, "xvid:[ERROR] \"%s\" is an invalid profile name\n", xvidenc_profile); - return(BAD); + return BAD; } /* ------------------------------------------------------------------- @@ -954,7 +954,7 @@ static int dispatch_settings(xvid_mplayer_module_t *mod) else mp_msg(MSGT_MENCODER, MSGL_INFO, "xvid: par=0/0 (vga11) forced by choosing a DXN profile\n"); - return(FINE); + return FINE; } static int set_create_struct(xvid_mplayer_module_t *mod) @@ -968,7 +968,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) if(xvidenc_profile) selected_profile = profileFromName(xvidenc_profile); if(!selected_profile) - return(BAD); + return BAD; /* Most of the structure is initialized by dispatch settings, only a * few things are missing */ @@ -988,7 +988,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) mp_msg(MSGT_MENCODER,MSGL_ERR, "xvid:[ERROR] resolution must be <= %dx%d for the chosen profile\n", selected_profile->width, selected_profile->height); - return(BAD); + return BAD; } /* FPS */ @@ -1002,7 +1002,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) mp_msg(MSGT_MENCODER,MSGL_ERR, "xvid:[ERROR] frame rate must be <= %d for the chosen profile\n", selected_profile->fps); - return(BAD); + return BAD; } /* Encodings zones */ @@ -1024,7 +1024,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) mp_msg(MSGT_MENCODER, MSGL_ERR, "xvid: you can't mix Fixed Quantizer Rate Control" " with other Rate Control mechanisms\n"); - return(BAD); + return BAD; } if(xvidenc_bitrate != 0 && xvidenc_pass == 1) { @@ -1062,7 +1062,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) mp_msg(MSGT_MENCODER, MSGL_ERR, "xvid: you must specify one or a valid combination of " "'bitrate', 'pass', 'fixed_quant' settings\n"); - return(BAD); + return BAD; } /* Sanity checking */ @@ -1071,7 +1071,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) mp_msg(MSGT_MENCODER, MSGL_ERR, "xvid: this code should not be reached - fill a bug " "report\n"); - return(BAD); + return BAD; } /* This is a single pass encoding: either a CBR pass or a constant @@ -1183,7 +1183,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) if(e != 3) { mp_msg(MSGT_MENCODER,MSGL_ERR, "error parsing zones\n"); - return(BAD); + return BAD; } q = (int)(value * 100); if (mode == 'q') @@ -1191,7 +1191,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) if (q < 200 || q > 3100) // make sure that quantizer is in allowable range { mp_msg(MSGT_MENCODER, MSGL_ERR, "zone quantizer must be between 2 and 31\n"); - return(BAD); + return BAD; } else { @@ -1203,7 +1203,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) if (q < 1 || q > 200) { mp_msg(MSGT_MENCODER, MSGL_ERR, "zone weight must be between 1 and 200\n"); - return(BAD); + return BAD; } else { @@ -1222,7 +1222,7 @@ static int set_create_struct(xvid_mplayer_module_t *mod) if(p) p++; } } - return(FINE); + return FINE; } static int set_frame_struct(xvid_mplayer_module_t *mod, mp_image_t *mpi) @@ -1253,7 +1253,7 @@ static int set_frame_struct(xvid_mplayer_module_t *mod, mp_image_t *mpi) mp_msg(MSGT_MENCODER, MSGL_ERR, "xvid: unsupported picture format (%s)!\n", vo_format_name(mpi->imgfmt)); - return(BAD); + return BAD; } /* Bind source frame */ @@ -1268,7 +1268,7 @@ static int set_frame_struct(xvid_mplayer_module_t *mod, mp_image_t *mpi) * plugins */ frame->quant = 0; - return(FINE); + return FINE; } static void @@ -1411,7 +1411,7 @@ static void *read_matrix(unsigned char *filename) /* Allocate matrix space */ if((matrix = malloc(64*sizeof(unsigned char))) == NULL) - return(NULL); + return NULL; /* Open the matrix file */ if((input = fopen(filename, "rb")) == NULL) { @@ -1419,7 +1419,7 @@ static void *read_matrix(unsigned char *filename) "xvid: Error opening the matrix file %s\n", filename); free(matrix); - return(NULL); + return NULL; } /* Read the matrix */ @@ -1434,7 +1434,7 @@ static void *read_matrix(unsigned char *filename) filename); free(matrix); fclose(input); - return(NULL); + return NULL; } /* Clamp the value to safe range */ @@ -1449,7 +1449,7 @@ static void *read_matrix(unsigned char *filename) /* We're done */ fclose(input); - return(matrix); + return matrix; } @@ -1481,7 +1481,7 @@ par_string(int parcode) par_string = "unknown"; break; } - return (par_string); + return par_string; } static const char *errorstring(int err) @@ -1507,7 +1507,7 @@ static const char *errorstring(int err) error = "Unknown"; } - return(error); + return error; } /***************************************************************************** -- cgit v1.2.3