GP32 Fmopl Documentation


Hooka

That Guy!
Joined
Jul 19, 2003
Messages
1,746
Age
41
Location
Canada
Website
Visit site
Well, I'm just butchering good code here so I thought I'd ask to see if anyone has any information on how fmopl has to be added into a project (I know... if you do it for me I'll never learn anything) I'm just looking for some hints as to how this code is actually supposed to be used within a project.

The code I have right now looks like this: (and it amazingly enough hasn't given me any errors or warning... for what I added anyways :p)

///////////////////////////////////////////////////////////////////////////
//
// SD_MusicOn() - turns on the sequencer
//
///////////////////////////////////////////////////////////////////////////
void SD_MusicOn()
{
FM_OPL *OPL;

OPL = OPLCreate(OPL_TYPE_YM3812, 3579545, 6896);
OPLWrite(OPL, 0x01, 0x20); /* Set WSE=1 */
OPLWrite(OPL, 0x08, 0x00); /* Set CSM=0 & SEL=0 */

}

///////////////////////////////////////////////////////////////////////////
//
// SD_MusicOff() - turns off the sequencer and any playing notes
//
///////////////////////////////////////////////////////////////////////////
void SD_MusicOff()
{
}

///////////////////////////////////////////////////////////////////////////
//
// SD_StartMusic() - starts playing the music pointed to
//
///////////////////////////////////////////////////////////////////////////
void SD_StartMusic(int music)
{
//SD_MusicOff();
}

Any insight into this could possibly be helpful (probably not though I'm an idiot) or even if you just know where there is a document about how to easily and simply use fmopl...
 
Back
Top