Revision 43cbf8ad

View differences:

libswscale/swscale_altivec_template.c
220 220
            for (j=0; j<filterSize; j++) {
221 221
                val += ((int)src[srcPos + j])*filter[filterSize*i + j];
222 222
            }
223
            dst[i] = av_clip(val>>7, 0, (1<<15)-1);
223
            dst[i] = FFMIN(val>>7, (1<<15)-1);
224 224
        }
225 225
    }
226 226
    else
......
259 259
        val_vEven = vec_mule(src_v, filter_v);
260 260
        val_s = vec_sums(val_vEven, vzero);
261 261
        vec_st(val_s, 0, tempo);
262
        dst[i] = av_clip(tempo[3]>>7, 0, (1<<15)-1);
262
        dst[i] = FFMIN(tempo[3]>>7, (1<<15)-1);
263 263
    }
264 264
    }
265 265
    break;
......
286 286
        val_v = vec_msums(src_v, filter_v, (vector signed int)vzero);
287 287
        val_s = vec_sums(val_v, vzero);
288 288
        vec_st(val_s, 0, tempo);
289
        dst[i] = av_clip(tempo[3]>>7, 0, (1<<15)-1);
289
        dst[i] = FFMIN(tempo[3]>>7, (1<<15)-1);
290 290
    }
291 291
    }
292 292
    break;
......
315 315
            vector signed int val_s = vec_sums(val_v, vzero);
316 316

  
317 317
            vec_st(val_s, 0, tempo);
318
            dst[i] = av_clip(tempo[3]>>7, 0, (1<<15)-1);
318
            dst[i] = FFMIN(tempo[3]>>7, (1<<15)-1);
319 319
        }
320 320
    }
321 321
    break;
......
377 377
        val_s = vec_sums(val_v, vzero);
378 378

  
379 379
        vec_st(val_s, 0, tempo);
380
        dst[i] = av_clip(tempo[3]>>7, 0, (1<<15)-1);
380
        dst[i] = FFMIN(tempo[3]>>7, (1<<15)-1);
381 381
    }
382 382

  
383 383
    }

Also available in: Unified diff