diff options
author | michael <michael@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2008-09-10 16:39:56 +0000 |
---|---|---|
committer | michael <michael@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2008-09-10 16:39:56 +0000 |
commit | a92e68d5a87dacda88a2510997988974d82c48a8 (patch) | |
tree | bb390e95066a3116ff732fbe1892ebb9723109f6 /libswscale/swscale_template.c | |
parent | 9af0a56c0592954f3b74d287102c8f497a24f781 (diff) | |
download | mpv-a92e68d5a87dacda88a2510997988974d82c48a8.tar.bz2 mpv-a92e68d5a87dacda88a2510997988974d82c48a8.tar.xz |
Change RGB2YUV_SHIFT from 16 to 15 to make it able to work
with 16bit signed constants (like SIMD might use).
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@27568 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libswscale/swscale_template.c')
-rw-r--r-- | libswscale/swscale_template.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/libswscale/swscale_template.c b/libswscale/swscale_template.c index f969fc6cb2..ea111418ff 100644 --- a/libswscale/swscale_template.c +++ b/libswscale/swscale_template.c @@ -1891,10 +1891,8 @@ static inline void RENAME(name ## _half)(uint8_t *dstU, uint8_t *dstV, uint8_t * \ g>>=shg;\ \ - dstU[i]= (((RU)>>1)*r + ((GU)>>1)*g + ((BU)>>1)*b + (257<<((S)-1)))>>(S);\ - dstV[i]= (((RV)>>1)*r + ((GV)>>1)*g + ((BV)>>1)*b + (257<<((S)-1)))>>(S);\ -/* dstU[i]= ((RU)*r + (GU)*g + (BU)*b + (257<<(S)))>>((S)+1);\ - dstV[i]= ((RV)*r + (GV)*g + (BV)*b + (257<<(S)))>>((S)+1);*/\ + dstU[i]= ((RU)*r + (GU)*g + (BU)*b + (257<<(S)))>>((S)+1);\ + dstV[i]= ((RV)*r + (GV)*g + (BV)*b + (257<<(S)))>>((S)+1);\ }\ } |