openMSX
Public Member Functions | Public Attributes | List of all members
openmsx::YM2413Burczynski::Channel Class Reference

#include <YM2413Burczynski.hh>

Collaboration diagram for openmsx::YM2413Burczynski::Channel:
Collaboration graph
[legend]

Public Member Functions

 Channel ()
 
int calcOutput (unsigned eg_cnt, unsigned lfo_pm, unsigned lfo_am, int fm)
 Calculate the value of the current sample produced by this channel. More...
 
void setFrequency (int block_fnum)
 Sets the frequency for this channel. More...
 
void setFrequencyLow (uint8_t value)
 Changes the lower 8 bits of the frequency for this channel. More...
 
void setFrequencyHigh (uint8_t value)
 Changes the higher 4 bits of the frequency for this channel. More...
 
void updateInstrumentPart (int part, uint8_t value)
 Sets some synthesis parameters as specified by the instrument. More...
 
void updateInstrument (const uint8_t *inst)
 Sets all synthesis parameters as specified by the instrument. More...
 
int getBlockFNum () const
 
FreqIndex getFrequencyIncrement () const
 
int getKeyScaleLevelBase () const
 
uint8_t getKeyCode () const
 
bool isSustained () const
 
void setSustain (bool sustained)
 
template<typename Archive >
void serialize (Archive &ar, unsigned version)
 

Public Attributes

Slot mod
 
Slot car
 

Detailed Description

Definition at line 170 of file YM2413Burczynski.hh.

Constructor & Destructor Documentation

◆ Channel()

openmsx::YM2413Burczynski::Channel::Channel ( )

Definition at line 819 of file YM2413Burczynski.cc.

Member Function Documentation

◆ calcOutput()

int openmsx::YM2413Burczynski::Channel::calcOutput ( unsigned  eg_cnt,
unsigned  lfo_pm,
unsigned  lfo_am,
int  fm 
)
inline

Calculate the value of the current sample produced by this channel.

Definition at line 564 of file YM2413Burczynski.cc.

References openmsx::YM2413Burczynski::Slot::calc_phase(), openmsx::YM2413Burczynski::Slot::calcOutput(), and car.

Referenced by openmsx::YM2413Burczynski::YM2413::generateChannels().

◆ getBlockFNum()

int openmsx::YM2413Burczynski::Channel::getBlockFNum ( ) const

Definition at line 849 of file YM2413Burczynski.cc.

Referenced by openmsx::YM2413Burczynski::Slot::calc_phase().

◆ getFrequencyIncrement()

FreqIndex openmsx::YM2413Burczynski::Channel::getFrequencyIncrement ( ) const

◆ getKeyCode()

uint8_t openmsx::YM2413Burczynski::Channel::getKeyCode ( ) const

◆ getKeyScaleLevelBase()

int openmsx::YM2413Burczynski::Channel::getKeyScaleLevelBase ( ) const

Definition at line 859 of file YM2413Burczynski.cc.

◆ isSustained()

bool openmsx::YM2413Burczynski::Channel::isSustained ( ) const

◆ serialize()

template<typename Archive >
void openmsx::YM2413Burczynski::Channel::serialize ( Archive &  ar,
unsigned  version 
)

◆ setFrequency()

void openmsx::YM2413Burczynski::Channel::setFrequency ( int  block_fnum)

Sets the frequency for this channel.

Definition at line 826 of file YM2413Burczynski.cc.

References car, openmsx::YM2413Burczynski::ksl_tab, mod, and openmsx::YM2413Burczynski::Slot::updateFrequency().

Referenced by setFrequencyHigh(), and setFrequencyLow().

◆ setFrequencyHigh()

void openmsx::YM2413Burczynski::Channel::setFrequencyHigh ( uint8_t  value)

Changes the higher 4 bits of the frequency for this channel.

Definition at line 844 of file YM2413Burczynski.cc.

References setFrequency().

◆ setFrequencyLow()

void openmsx::YM2413Burczynski::Channel::setFrequencyLow ( uint8_t  value)

Changes the lower 8 bits of the frequency for this channel.

Definition at line 839 of file YM2413Burczynski.cc.

References setFrequency().

◆ setSustain()

void openmsx::YM2413Burczynski::Channel::setSustain ( bool  sustained)

Definition at line 875 of file YM2413Burczynski.cc.

◆ updateInstrument()

void openmsx::YM2413Burczynski::Channel::updateInstrument ( const uint8_t *  inst)

Sets all synthesis parameters as specified by the instrument.

Parameters
instInstrument data.

Definition at line 928 of file YM2413Burczynski.cc.

References updateInstrumentPart().

◆ updateInstrumentPart()

void openmsx::YM2413Burczynski::Channel::updateInstrumentPart ( int  part,
uint8_t  value 
)

Member Data Documentation

◆ car

Slot openmsx::YM2413Burczynski::Channel::car

Definition at line 213 of file YM2413Burczynski.hh.

Referenced by calcOutput(), serialize(), setFrequency(), and updateInstrumentPart().

◆ mod

Slot openmsx::YM2413Burczynski::Channel::mod

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