comparison dsputil.c @ 996:ad44196ea483 libavcodec

add/diff_bytes bugfix patch by (Felix von Leitner <felix-ffmpeg at fefe dot de>)
author michaelni
date Sat, 11 Jan 2003 21:04:47 +0000
parents e162c09efbe7
children 4dfe15ae0078
comparison
equal deleted inserted replaced
995:edc10966b081 996:ad44196ea483
1609 memset(blocks, 0, sizeof(DCTELEM)*6*64); 1609 memset(blocks, 0, sizeof(DCTELEM)*6*64);
1610 } 1610 }
1611 1611
1612 static void add_bytes_c(uint8_t *dst, uint8_t *src, int w){ 1612 static void add_bytes_c(uint8_t *dst, uint8_t *src, int w){
1613 int i; 1613 int i;
1614 for(i=0; i+7<w; i++){ 1614 for(i=0; i+7<w; i+=8){
1615 dst[i+0] += src[i+0]; 1615 dst[i+0] += src[i+0];
1616 dst[i+1] += src[i+1]; 1616 dst[i+1] += src[i+1];
1617 dst[i+2] += src[i+2]; 1617 dst[i+2] += src[i+2];
1618 dst[i+3] += src[i+3]; 1618 dst[i+3] += src[i+3];
1619 dst[i+4] += src[i+4]; 1619 dst[i+4] += src[i+4];
1625 dst[i+0] += src[i+0]; 1625 dst[i+0] += src[i+0];
1626 } 1626 }
1627 1627
1628 static void diff_bytes_c(uint8_t *dst, uint8_t *src1, uint8_t *src2, int w){ 1628 static void diff_bytes_c(uint8_t *dst, uint8_t *src1, uint8_t *src2, int w){
1629 int i; 1629 int i;
1630 for(i=0; i+7<w; i++){ 1630 for(i=0; i+7<w; i+=8){
1631 dst[i+0] = src1[i+0]-src2[i+0]; 1631 dst[i+0] = src1[i+0]-src2[i+0];
1632 dst[i+1] = src1[i+1]-src2[i+1]; 1632 dst[i+1] = src1[i+1]-src2[i+1];
1633 dst[i+2] = src1[i+2]-src2[i+2]; 1633 dst[i+2] = src1[i+2]-src2[i+2];
1634 dst[i+3] = src1[i+3]-src2[i+3]; 1634 dst[i+3] = src1[i+3]-src2[i+3];
1635 dst[i+4] = src1[i+4]-src2[i+4]; 1635 dst[i+4] = src1[i+4]-src2[i+4];