ScummVM API documentation
OPL::NullOPL Class Referencefinal

#include <fmopl.h>

Inheritance diagram for OPL::NullOPL:
OPL::OPL Audio::RealChip Audio::Chip Audio::Chip

Public Member Functions

bool init () override
 
void reset () override
 
void write (int a, int v) override
 
void writeReg (int r, int v) override
 
- Public Member Functions inherited from OPL::OPL
void start (TimerCallback *callback)
 
- Public Member Functions inherited from Audio::Chip
void start (TimerCallback *callback, int timerFrequency)
 
void stop ()
 
- Public Member Functions inherited from Audio::RealChip
void setCallbackFrequency (int timerFrequency)
 

Additional Inherited Members

- Public Types inherited from OPL::OPL
enum  { kDefaultCallbackFrequency = 250 }
 
- Public Types inherited from Audio::Chip
typedef Common::Functor0< void > TimerCallback
 
- Protected Member Functions inherited from OPL::OPL
void initDualOpl2OnOpl3 (Config::OplType oplType)
 
bool emulateDualOpl2OnOpl3 (int r, int v, Config::OplType oplType)
 
- Protected Member Functions inherited from Audio::RealChip
void startCallbacks (int timerFrequency)
 
void stopCallbacks ()
 
virtual void onTimer ()
 
- Protected Attributes inherited from OPL::OPL
bool _rhythmMode
 
int _connectionFeedbackValues [3]
 
- Protected Attributes inherited from Audio::Chip
Common::ScopedPtr< TimerCallback_callback
 

Detailed Description

A null implementation of a Yamaha OPL chip that runs the callback but doesn't output any audio.

Member Function Documentation

◆ init()

bool OPL::NullOPL::init ( )
inlineoverridevirtual

Initializes the OPL emulator.

Returns
true on success, false on failure

Implements OPL::OPL.

◆ reset()

void OPL::NullOPL::reset ( )
inlineoverridevirtual

Reinitializes the OPL emulator

Implements OPL::OPL.

◆ write()

void OPL::NullOPL::write ( int  a,
int  v 
)
inlineoverridevirtual

Writes a byte to the given I/O port.

Parameters
aport address
vvalue, which will be written

Implements OPL::OPL.

◆ writeReg()

void OPL::NullOPL::writeReg ( int  r,
int  v 
)
inlineoverridevirtual

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: