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

int calcOutput (unsigned eg_cnt, unsigned lfo_pm, unsigned lfo_am, int fm)
 Calculate the value of the current sample produced by this channel.
 
void setFrequency (int block_fnum)
 Sets the frequency for this channel.
 
void setFrequencyLow (uint8_t value)
 Changes the lower 8 bits of the frequency for this channel.
 
void setFrequencyHigh (uint8_t value)
 Changes the higher 4 bits of the frequency for this channel.
 
void updateInstrumentPart (int part, uint8_t value)
 Sets some synthesis parameters as specified by the instrument.
 
void updateInstrument (std::span< const uint8_t, 8 > inst)
 Sets all synthesis parameters as specified by the instrument.
 
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 176 of file YM2413Burczynski.hh.

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 553 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 823 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 833 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 800 of file YM2413Burczynski.cc.

References car, 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 818 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 813 of file YM2413Burczynski.cc.

References setFrequency().

◆ setSustain()

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

Definition at line 849 of file YM2413Burczynski.cc.

◆ updateInstrument()

void openmsx::YM2413Burczynski::Channel::updateInstrument ( std::span< const uint8_t, 8 >  inst)

Sets all synthesis parameters as specified by the instrument.

Parameters
instInstrument data.

Definition at line 902 of file YM2413Burczynski.cc.

References updateInstrumentPart(), and xrange().

◆ updateInstrumentPart()

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

Member Data Documentation

◆ car

Slot openmsx::YM2413Burczynski::Channel::car

Definition at line 217 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: