1
0
Fork 0
forked from len0rd/rockbox

Optimisation of the midi player, reducing the number of multiplications and memory accesses inside a very frequently executed loop, also does shifting of the whole sample when synthing is done which improves accurracy slightly, ~10% fewer buffer misses

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14983 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Nils Wallménius 2007-10-04 19:36:42 +00:00
parent cc5b50b231
commit e1940b87b0
5 changed files with 20 additions and 27 deletions

View file

@ -46,15 +46,6 @@ static inline void setVol(int ch, int vol)
setVolScale(a);
}
static inline void setPan(int ch, int pan)
{
// printf("\npanning[%d] %d ==> %d", ch, chPanRight[ch], pan);
chPanLeft[ch]=128-pan;
chPanRight[ch]=pan;
}
static inline void setPatch(int ch, int pat)
{
chPat[ch]=pat;
@ -286,7 +277,7 @@ static void sendEvent(struct Event * ev)
}
case CTRL_PANNING:
{
setPan((status_low), d2);
chPan[status_low]=d2;
return;
}
}