Documentation
¶
Overview ¶
Package opl2 renders the melodic mode of the Yamaha YM3812. The oscillator and envelope logic are adapted from st3play's Opal derivative. See LICENSE.st3play.
Index ¶
Constants ¶
const Rate = 157500000.0 / (11 * 288)
Rate is the native OPL2 sample rate with the ISA oscillator.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Chip ¶
type Chip struct {
// contains filtered or unexported fields
}
Chip is an independent nine-channel melodic OPL2 instance.
type Output ¶
type Output struct {
Chip
// contains filtered or unexported fields
}
Output resamples the chip's native output with the st3play interpolation kernel. The phase remains continuous across register writes and reads.
func (*Output) RenderSample ¶
RenderSample produces one output frame.