class RemiAudio::Codecs::YM2610Codec

Overview

A codec for YM2610 ADPCM-A samples.

Defined in:

remiaudio/codecs/ngadpcm.cr

Constant Summary

YM2610_DELTAS = [1, 3, 5, 7, 9, 11, 13, 15, -1, -3, -5, -7, -9, -11, -13, -15]
YM2610_STEP_ADJUST = [-1, -1, -1, -1, 2, 5, 7, 9]

Instance Method Summary

Instance Method Detail

def adpcmToInt16(sample : UInt8) : Tuple(Int16, Int16) #

Convert a YM2610 ADPCM-A sample into two signed 16-bit integer samples.


[View source]
def adpcmToInt16(samples : Array(UInt8)) : Array(Int16) #

Converts an array of YM2610 ADPCM-A samples into an array of signed 16-bit integer samples.


[View source]
def int16ToAdpcm(sample1 : Int16, sample2 : Int16) : UInt8 #

Converts two signed 16-bit integer samples into one YM2610 ADPCM-A sample.


[View source]
def int16ToAdpcm(samples : Array(Int16)) : Array(UInt8) #

Converts an array of signed 16-bit integer samples into an array of YM2610 ADPCM-A samples.


[View source]