ScummVM API documentation
OPL::RetroWaveOPL3::OPL Class Reference
Inheritance diagram for OPL::RetroWaveOPL3::OPL:
OPL::RealOPL OPL::OPL

Public Member Functions

 OPL (Config::OplType type)
 
bool init () override
 
void reset () override
 
void write (int portAddress, int value) override
 
byte read (int portAddress) override
 
void writeReg (int reg, int value) override
 
- Public Member Functions inherited from OPL::RealOPL
void setCallbackFrequency (int timerFrequency)
 
- Public Member Functions inherited from OPL::OPL
void start (TimerCallback *callback, int timerFrequency=kDefaultCallbackFrequency)
 
void stop ()
 

Protected Member Functions

void writeReg (int reg, int value, bool forcePort)
 
void onTimer () override
 
- Protected Member Functions inherited from OPL::RealOPL
void startCallbacks (int timerFrequency)
 
void stopCallbacks ()
 
- Protected Member Functions inherited from OPL::OPL
void initDualOpl2OnOpl3 (Config::OplType oplType)
 
bool emulateDualOpl2OnOpl3 (int r, int v, Config::OplType oplType)
 

Additional Inherited Members

- Public Types inherited from OPL::OPL
enum  { kDefaultCallbackFrequency = 250 }
 
- Protected Attributes inherited from OPL::OPL
Common::ScopedPtr< TimerCallback_callback
 
bool _rhythmMode
 
int _connectionFeedbackValues [3]
 

Member Function Documentation

◆ init()

bool OPL::RetroWaveOPL3::OPL::init ( )
overridevirtual

Initializes the OPL emulator.

Returns
true on success, false on failure

Implements OPL::OPL.

◆ reset()

void OPL::RetroWaveOPL3::OPL::reset ( )
overridevirtual

Reinitializes the OPL emulator

Implements OPL::OPL.

◆ write()

void OPL::RetroWaveOPL3::OPL::write ( int  a,
int  v 
)
overridevirtual

Writes a byte to the given I/O port.

Parameters
aport address
vvalue, which will be written

Implements OPL::OPL.

◆ read()

byte OPL::RetroWaveOPL3::OPL::read ( int  a)
overridevirtual

Reads a byte from the given I/O port.

Parameters
aport address
Returns
value read

Implements OPL::OPL.

◆ writeReg()

void OPL::RetroWaveOPL3::OPL::writeReg ( int  r,
int  v 
)
overridevirtual

Function to directly write to a specific OPL register. This writes to both chips for a Dual OPL2. We allow writing to secondary OPL registers by using register values >= 0x100.

Parameters
rhardware register number to write to
vvalue, which will be written

Implements OPL::OPL.


The documentation for this class was generated from the following file: