spu: fix xa masking, was causing noise
authornotaz <notasas@gmail.com>
Thu, 3 Feb 2011 21:56:14 +0000 (23:56 +0200)
committernotaz <notasas@gmail.com>
Fri, 4 Feb 2011 13:11:59 +0000 (15:11 +0200)
plugins/dfsound/xa.c

index fdae4f9..df60346 100644 (file)
@@ -359,7 +359,6 @@ INLINE void FeedXA(xa_decode_t *xap)
          vr+=(gauss[vl+2]*gvall(2))&~2047;
          vr+=(gauss[vl+3]*gvall(3))&~2047;
          l=s= vr >> 11;
-         l &= 0xffff;
         }
        else
         {
@@ -371,6 +370,7 @@ INLINE void FeedXA(xa_decode_t *xap)
          l=s;
         }
 
+       l &= 0xffff;
        *XAFeed++=(l|(l<<16));
 
        if(XAFeed==XAEnd) XAFeed=XAStart;