mirror of
https://github.com/mpv-player/mpv
synced 2024-12-25 00:02:13 +00:00
MPEG-2 blocks at qp 1 get overfiltered by spp, apparently because "qp>>1" turns
it into 0, which causes an integer overflow later. Clip qp at 1 to avoid this. patch by Alexander Strange, astrange ithinksw com git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24572 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
b2a9d6aa1b
commit
04586de1dd
@ -402,7 +402,7 @@ static void filter(struct vf_priv_s *p, uint8_t *dst, uint8_t *src, int dst_stri
|
||||
qp= p->qp;
|
||||
else{
|
||||
qp= qp_store[ (XMIN(x, width-1)>>qps) + (XMIN(y, height-1)>>qps) * qp_stride];
|
||||
if(p->mpeg2) qp>>=1;
|
||||
if(p->mpeg2) qp = FFMAX(1, qp>>1);
|
||||
}
|
||||
for(i=0; i<count; i++){
|
||||
const int x1= x + offset[i+count-1][0];
|
||||
|
Loading…
Reference in New Issue
Block a user