Remove wrapper for pressNote and make the function externally visible

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14978 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Nils Wallménius 2007-10-04 10:30:01 +00:00
parent b0a373681b
commit cb9ba11de6
2 changed files with 8 additions and 21 deletions

View file

@ -16,7 +16,12 @@
*
****************************************************************************/
#include "../../plugin.h"
#include "plugin.h"
#include "midi/guspat.h"
#include "midi/midiutil.h"
#include "midi/synth.h"
#include "midi/sequencer.h"
#include "midi/midifile.h"
PLUGIN_HEADER
PLUGIN_IRAM_DECLARE
@ -114,15 +119,6 @@ struct MIDIfile * mf IBSS_ATTR;
int numberOfSamples IBSS_ATTR;
long bpm IBSS_ATTR;
#include "plugin.h"
#include "midi/guspat.h"
#include "midi/midiutil.h"
#include "midi/synth.h"
#include "midi/sequencer.h"
#include "midi/midifile.h"
const unsigned char * drumNames[]={
"Bass Drum 2 ",
"Bass Drum 1 ",
@ -362,7 +358,7 @@ void sendEvents()
for(i=0; i<V_NUMCELLS; i++)
{
if(trackData[trackPos[i]][i] == VAL_ENABLED)
pressNote_Nonstatic(9, trackMap[i], 127);
pressNote(9, trackMap[i], 127);
}
}

View file

@ -157,7 +157,7 @@ static inline void setPW(int ch, int msb, int lsb)
}
}
static void pressNote(int ch, int note, int vol)
inline void pressNote(int ch, int note, int vol)
{
static int lastKill = 0;
/* Silences all channels but one, for easy debugging, for me. */
@ -379,12 +379,3 @@ int tick(void)
return 0;
}
/* Ugly hack so that beatbox can get at teh pressnote function */
/* Is there a speed advantage to keeping pressNote itself static? */
/* Note that midiplay needs the speed much more than beatbox does */
void pressNote_Nonstatic(int ch, int note, int vol)
{
pressNote(ch, note, vol);
}