## Revision 901775c7 libswscale/swscale.c

View differences:

libswscale/swscale.c
1888 1888
```            int b=((xpos+xInc)>>16) - xx;
```
1889 1889
```            int c=((xpos+xInc*2)>>16) - xx;
```
1890 1890
```            int d=((xpos+xInc*3)>>16) - xx;
```
1891
```            int inc                = (d+1<4);
```
1891 1892

1892 1893
```            filter[i  ] = (( xpos         & 0xFFFF) ^ 0xFFFF)>>9;
```
1893 1894
```            filter[i+1] = (((xpos+xInc  ) & 0xFFFF) ^ 0xFFFF)>>9;
```
......
1897 1898

1898 1899
```            if (d+1<4)
```
1899 1900
```            {
```
1900
```                int maxShift= 3-(d+1);
```
1901
```                int maxShift= 3-(d+inc);
```
1901 1902
```                int shift=0;
```
1902 1903

1903 1904
```                memcpy(funnyCode + fragmentPos, fragmentB, fragmentLengthB);
```
1904 1905

1905 1906
```                funnyCode[fragmentPos + imm8OfPShufW1B]=
```
1906
```                    (a+1) | ((b+1)<<2) | ((c+1)<<4) | ((d+1)<<6);
```
1907
```                    (a+inc) | ((b+inc)<<2) | ((c+inc)<<4) | ((d+inc)<<6);
```
1907 1908
```                funnyCode[fragmentPos + imm8OfPShufW2B]=
```
1908 1909
```                    a | (b<<2) | (c<<4) | (d<<6);
```
1909 1910

1910
```                if (i+3>=dstW) shift=maxShift; //avoid overread
```
1911
```                if (i+4-inc>=dstW) shift=maxShift; //avoid overread
```
1911 1912
```                else if ((filterPos[i/2]&3) <= maxShift) shift=filterPos[i/2]&3; //Align
```
1912 1913

1913 1914
```                if (shift && i>=shift)
```

Also available in: Unified diff