From 0eb321bf2c1cc0e048faff26a01f86cdd3ec254f Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Tue, 7 Jul 2009 02:26:13 +0300 Subject: Remove trailing whitespace from most files --- libaf/af_channels.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'libaf/af_channels.c') diff --git a/libaf/af_channels.c b/libaf/af_channels.c index ffed84bfb0..b42cde380a 100644 --- a/libaf/af_channels.c +++ b/libaf/af_channels.c @@ -108,7 +108,7 @@ static void copy(void* in, void* out, int ins, int inos,int outs, int outos, int break; } default: - mp_msg(MSGT_AFILTER, MSGL_ERR, "[channels] Unsupported number of bytes/sample: %i" + mp_msg(MSGT_AFILTER, MSGL_ERR, "[channels] Unsupported number of bytes/sample: %i" " please report this error on the MPlayer mailing list. \n",bps); } } @@ -118,11 +118,11 @@ static int check_routes(af_channels_t* s, int nin, int nout) { int i; if((s->nr < 1) || (s->nr > AF_NCH)){ - mp_msg(MSGT_AFILTER, MSGL_ERR, "[channels] The number of routing pairs must be" + mp_msg(MSGT_AFILTER, MSGL_ERR, "[channels] The number of routing pairs must be" " between 1 and %i. Current value is %i\n",AF_NCH,s->nr); return AF_ERROR; } - + for(i=0;inr;i++){ if((s->route[i][FR] >= nin) || (s->route[i][TO] >= nout)){ mp_msg(MSGT_AFILTER, MSGL_ERR, "[channels] Invalid routing in pair nr. %i.\n", i); @@ -142,7 +142,7 @@ static int control(struct af_instance_s* af, int cmd, void* arg) // Set default channel assignment if(!s->router){ int i; - // Make sure this filter isn't redundant + // Make sure this filter isn't redundant if(af->data->nch == ((af_data_t*)arg)->nch) return AF_DETACH; @@ -180,14 +180,14 @@ static int control(struct af_instance_s* af, int cmd, void* arg) int ch = 0; // Sanity check if((s->nr < 1) || (s->nr > AF_NCH)){ - mp_msg(MSGT_AFILTER, MSGL_ERR, "[channels] The number of routing pairs must be" + mp_msg(MSGT_AFILTER, MSGL_ERR, "[channels] The number of routing pairs must be" " between 1 and %i. Current value is %i\n",AF_NCH,s->nr); - } + } s->router = 1; // Scan for pairs on commandline while((*cp == ':') && (ch < s->nr)){ sscanf(cp, ":%i:%i%n" ,&s->route[ch][FR], &s->route[ch][TO], &n); - mp_msg(MSGT_AFILTER, MSGL_V, "[channels] Routing from channel %i to" + mp_msg(MSGT_AFILTER, MSGL_V, "[channels] Routing from channel %i to" " channel %i\n",s->route[ch][FR],s->route[ch][TO]); cp = &cp[n]; ch++; @@ -197,20 +197,20 @@ static int control(struct af_instance_s* af, int cmd, void* arg) if(AF_OK != af->control(af,AF_CONTROL_CHANNELS | AF_CONTROL_SET ,&nch)) return AF_ERROR; return AF_OK; - } - case AF_CONTROL_CHANNELS | AF_CONTROL_SET: + } + case AF_CONTROL_CHANNELS | AF_CONTROL_SET: // Reinit must be called after this function has been called - + // Sanity check if(((int*)arg)[0] <= 0 || ((int*)arg)[0] > AF_NCH){ - mp_msg(MSGT_AFILTER, MSGL_ERR, "[channels] The number of output channels must be" + mp_msg(MSGT_AFILTER, MSGL_ERR, "[channels] The number of output channels must be" " between 1 and %i. Current value is %i\n",AF_NCH,((int*)arg)[0]); return AF_ERROR; } - af->data->nch=((int*)arg)[0]; + af->data->nch=((int*)arg)[0]; if(!s->router) - mp_msg(MSGT_AFILTER, MSGL_V, "[channels] Changing number of channels" + mp_msg(MSGT_AFILTER, MSGL_V, "[channels] Changing number of channels" " to %i\n",af->data->nch); return AF_OK; case AF_CONTROL_CHANNELS | AF_CONTROL_GET: @@ -246,7 +246,7 @@ static int control(struct af_instance_s* af, int cmd, void* arg) return AF_UNKNOWN; } -// Deallocate memory +// Deallocate memory static void uninit(struct af_instance_s* af) { free(af->setup); @@ -262,18 +262,18 @@ static af_data_t* play(struct af_instance_s* af, af_data_t* data) af_data_t* l = af->data; // Local data af_channels_t* s = af->setup; int i; - + if(AF_OK != RESIZE_LOCAL_BUFFER(af,data)) return NULL; // Reset unused channels memset(l->audio,0,c->len / c->nch * l->nch); - + if(AF_OK == check_routes(s,c->nch,l->nch)) for(i=0;inr;i++) copy(c->audio,l->audio,c->nch,s->route[i][FR], l->nch,s->route[i][TO],c->len,c->bps); - + // Set output data c->audio = l->audio; c->len = c->len / c->nch * l->nch; -- cgit v1.2.3