Packageorg.si.sion.module
Classpublic class SiOPMTable
InheritanceSiOPMTable Inheritance Object

SiOPM table



Public Properties
 PropertyDefined By
  clock : int
fm clock
SiOPMTable
  clock_ratio : int
(clock/64/sampling_rate)<<CLOCK_RATIO_BITS
SiOPMTable
  dt1Table : Array = null
Table for dt1 (from fmgen.cpp).
SiOPMTable
  dt2Table : Vector.<int>
Table for dt2 (from MAME's opm source).
SiOPMTable
  eg_incTables : Array
EG:increment table.
SiOPMTable
  eg_incTablesAtt : Array
EG:increment table for attack.
SiOPMTable
  eg_levelTables : Array = null
EG:table to calculate eg_level.
SiOPMTable
  eg_lv2tlTable : Vector.<int> = null
EG:tl table from linear-volume to tl.
SiOPMTable
  eg_slTable : Array = null
EG:sl table from 15 to 1024.
SiOPMTable
  eg_ssgTableIndex : Array = null
EG:table from sgg_type to eg_levelTables index.
SiOPMTable
  eg_tableSelector : Array = null
EG:table selector.
SiOPMTable
  eg_timerSteps : Array = null
EG:timer step.
SiOPMTable
  eg_tlTable32dB : Vector.<int> = null
EG:tl table from N88 basic v command.
SiOPMTable
  eg_tlTable48dB : Vector.<int> = null
EG:tl table from psg volume.
SiOPMTable
  eg_tlTable64dB : Vector.<int> = null
EG:tl table of fmp7 based.
SiOPMTable
  eg_tlTable96dB : Vector.<int> = null
EG:tl table of tl based.
SiOPMTable
  eg_tlTableLine : Vector.<int> = null
EG:tl table from linear volume.
SiOPMTable
  eg_tlTables : Vector.<Vector.<int>> = null
EG:tl table from volume to tl.
SiOPMTable
  filter_cutoffTable : Vector.<Number> = null
FILTER: cutoff
SiOPMTable
  filter_eg_rate : Vector.<int> = null
FILTER: envlop rate
SiOPMTable
  filter_feedbackTable : Vector.<Number> = null
FILTER: resonance
SiOPMTable
  final_oscilator_flags : Array
Flags of final oscillator
SiOPMTable
  i2n : Number
int->Number ratio on pulse data
SiOPMTable
  _instance : SiOPMTable = null
[static] internal instance, you can access this after creating SiONDriver.
SiOPMTable
  instance : SiOPMTable
[static] [read-only] static sigleton instance
SiOPMTable
  lfo_chorusTables : Vector.<int> = null
LFO:lfo modulation table for chorus
SiOPMTable
  lfo_timerSteps : Vector.<int> = null
LFO:timer step.
SiOPMTable
  lfo_waveTables : Array = null
LFO:lfo modulation table
SiOPMTable
  logTable : Vector.<int> = null
PG:log table.
SiOPMTable
  nnToKC : Vector.<int> = null
PG:MIDI note number to FM key code.
SiOPMTable
  noWaveTable : SiOPMWaveTable
PG:Wave tables without any waves.
SiOPMTable
  noWaveTableOPM : SiOPMWaveTable
SiOPMTable
  panTable : Vector.<Number> = null
Panning volume table.
SiOPMTable
  phaseStepShiftFilter : Vector.<int> = null
PG:phase step shift filter.
SiOPMTable
  pitchTable : Vector.<Vector.<int>> = null
PG:pitch table.
SiOPMTable
  pitchWaveLength : Vector.<Number> = null
PG:pitch wave length (in samples) table.
SiOPMTable
  psg_clock : Number
psg clock
SiOPMTable
  rate : int
sampling rate
SiOPMTable
  sampleRatePitchShift : int
44100Hz=0, 22050Hz=1
SiOPMTable
  samplerTables : Vector.<SiOPMWaveSamplerTable> = null
PG:Sampler table
SiOPMTable
  soundReference : * = null
PG:Sound reference table
SiOPMTable
  waveTables : Vector.<SiOPMWaveTable> = null
PG:Wave tables
SiOPMTable
Public Methods
 MethodDefined By
  
SiOPMTable(clock:int, psg_clock:Number, rate:int)
constructor
SiOPMTable
  
calcLogTableIndex(n:Number):int
[static] calculate log table index from Number[-1,1].
SiOPMTable
  
get PCM data from a list of SiONDriver and SiONData
SiOPMTable
  
get wave table from a list of SiONDriver and SiONData
SiOPMTable
Public Constants
 ConstantDefined By
  CLOCK_RATIO_BITS : int = 10
[static]
SiOPMTable
  DEFAULT_PG_MAX : int = 256
[static]
SiOPMTable
  ENV_BITS : int = 10
[static]
SiOPMTable
  ENV_BOTTOM : int
[static]
SiOPMTable
  ENV_BOTTOM_SSGEC : int
[static]
SiOPMTable
  ENV_LSHIFT : int = 3.0
[static]
SiOPMTable
  ENV_TIMER_BITS : int = 24
[static]
SiOPMTable
  ENV_TIMER_INITIAL : int
[static]
SiOPMTable
  ENV_TOP : int
[static]
SiOPMTable
  FIXED_BITS : int = 16
[static]
SiOPMTable
  HALF_TONE_BITS : int = 6
[static]
SiOPMTable
  HALF_TONE_RESOLUTION : int
[static]
SiOPMTable
  KEY_CODE_TABLE_SIZE : int = 128
[static]
SiOPMTable
  LFO_FIXED_BITS : int = 20
[static]
SiOPMTable
  LFO_TABLE_SIZE : int = 256
[static]
SiOPMTable
  LFO_TIMER_INITIAL : int
[static]
SiOPMTable
  LFO_WAVE_MAX : int = 8
[static]
SiOPMTable
  LFO_WAVE_NOISE : int = 3
[static]
SiOPMTable
  LFO_WAVE_SAW : int = 0
[static]
SiOPMTable
  LFO_WAVE_SQUARE : int = 1
[static]
SiOPMTable
  LFO_WAVE_TRIANGLE : int = 2
[static]
SiOPMTable
  LOG_TABLE_BOTTOM : int = 6656.0
[static]
SiOPMTable
  LOG_TABLE_MAX_BITS : int = 16
[static]
SiOPMTable
  LOG_TABLE_RESOLUTION : int = 256
[static]
SiOPMTable
  LOG_TABLE_SIZE : int = 8192.0
[static]
SiOPMTable
  LOG_VOLUME_BITS : int = 13
[static]
SiOPMTable
  NOISE_TABLE_BITS : int = 15
[static]
SiOPMTable
  NOISE_TABLE_SIZE : int
[static]
SiOPMTable
  NOISE_WAVE_OUTPUT : Number = 1
[static]
SiOPMTable
  NOTE_BITS : int = 7
[static]
SiOPMTable
  NOTE_TABLE_SIZE : int
[static]
SiOPMTable
  OUTPUT_MAX : Number = 0.5
[static]
SiOPMTable
  PCM_BITS : int = 20
[static]
SiOPMTable
  PCM_DATA_MAX : int = 128
[static]
SiOPMTable
  PG_CUSTOM : int = 256
[static]
SiOPMTable
  PG_FILTER : int = 511
[static]
SiOPMTable
  PG_KNMBSMM : int = 7
[static]
SiOPMTable
  PG_MA3_WAVE : int = 32
[static]
SiOPMTable
  PG_NOISE : int = 6
[static]
SiOPMTable
  PG_NOISE_GB_SHORT : int = 21
[static]
SiOPMTable
  PG_NOISE_HIPAS : int = 19
[static]
SiOPMTable
  PG_NOISE_PINK : int = 20
[static]
SiOPMTable
  PG_NOISE_PULSE : int = 17
[static]
SiOPMTable
  PG_NOISE_SHORT : int = 18
[static]
SiOPMTable
  PG_NOISE_WHITE : int = 16
[static]
SiOPMTable
  PG_OFFSET : int = 10
[static]
SiOPMTable
  PG_PCM : int = 384
[static]
SiOPMTable
  PG_PC_NZ_16BIT : int = 24
[static]
SiOPMTable
  PG_PC_NZ_OPM : int = 26
[static]
SiOPMTable
  PG_PC_NZ_SHORT : int = 25
[static]
SiOPMTable
  PG_PULSE : int = 64
[static]
SiOPMTable
  PG_PULSE_SPIKE : int = 80
[static]
SiOPMTable
  PG_RAMP : int = 128
[static]
SiOPMTable
  PG_SAW_DOWN : int = 2
[static]
SiOPMTable
  PG_SAW_UP : int = 1
[static]
SiOPMTable
  PG_SAW_VC6 : int = 11
[static]
SiOPMTable
  PG_SINE : int = 0
[static]
SiOPMTable
  PG_SQUARE : int = 5
[static]
SiOPMTable
  PG_SYNC_HIGH : int = 9
[static]
SiOPMTable
  PG_SYNC_LOW : int = 8
[static]
SiOPMTable
  PG_TRIANGLE : int = 4
[static]
SiOPMTable
  PG_TRIANGLE_FC : int = 3
[static]
SiOPMTable
  PG_USER_CUSTOM : int = -1
[static]
SiOPMTable
  PG_USER_PCM : int = -2
[static]
SiOPMTable
  PHASE_BITS : int = 26.0
[static]
SiOPMTable
  PHASE_FILTER : int
[static]
SiOPMTable
  PHASE_MAX : int
[static]
SiOPMTable
  PHASE_SIGN_RSHIFT : int = 25.0
[static]
SiOPMTable
  PITCH_TABLE_SIZE : int
[static]
SiOPMTable
  PT_APU_NOISE : int = 5
[static]
SiOPMTable
  PT_GB_NOISE : int = 6
[static]
SiOPMTable
  PT_MAX : int = 7
[static]
SiOPMTable
  PT_OPM : int = 0
[static]
SiOPMTable
  PT_OPM_NOISE : int = 3
[static]
SiOPMTable
  PT_PCM : int = 1
[static]
SiOPMTable
  PT_PSG : int = 2
[static]
SiOPMTable
  PT_PSG_NOISE : int = 4
[static]
SiOPMTable
  SAMPLER_DATA_MAX : int
[static]
SiOPMTable
  SAMPLER_TABLE_MAX : int = 4
[static]
SiOPMTable
  SAMPLING_TABLE_BITS : int = 10
[static]
SiOPMTable
  SAMPLING_TABLE_SIZE : int
[static]
SiOPMTable
  SQUARE_WAVE_OUTPUT : Number = 1
[static]
SiOPMTable
  VM_DR32DB : int = 4
[static]
SiOPMTable
  VM_DR48DB : int = 3
[static]
SiOPMTable
  VM_DR64DB : int = 2
[static]
SiOPMTable
  VM_DR96DB : int = 1
[static]
SiOPMTable
  VM_LINEAR : int = 0
[static]
SiOPMTable
  VM_MAX : int = 5
[static]
SiOPMTable
  WAVE_TABLE_MAX : int = 128
[static]
SiOPMTable
Property Detail
_instanceproperty
public static var _instance:SiOPMTable = null

internal instance, you can access this after creating SiONDriver.

_stencilCustomWaveTablesproperty 
_sion_internal var _stencilCustomWaveTables:Vector.<SiOPMWaveTable> = null

PG:Overriding custom wave tables

_stencilPCMVoicesproperty 
_sion_internal var _stencilPCMVoices:Vector.<SiMMLVoice> = null

PG:PCM voice

clockproperty 
public var clock:int

fm clock

clock_ratioproperty 
public var clock_ratio:int

(clock/64/sampling_rate)<<CLOCK_RATIO_BITS

dt1Tableproperty 
public var dt1Table:Array = null

Table for dt1 (from fmgen.cpp).

dt2Tableproperty 
public var dt2Table:Vector.<int>

Table for dt2 (from MAME's opm source).

eg_incTablesproperty 
public var eg_incTables:Array

EG:increment table. This table is based on MAME's opm emulation.

eg_incTablesAttproperty 
public var eg_incTablesAtt:Array

EG:increment table for attack. This shortcut is based on fmgen (shift=0 means x0).

eg_levelTablesproperty 
public var eg_levelTables:Array = null

EG:table to calculate eg_level.

eg_lv2tlTableproperty 
public var eg_lv2tlTable:Vector.<int> = null

EG:tl table from linear-volume to tl.

eg_slTableproperty 
public var eg_slTable:Array = null

EG:sl table from 15 to 1024.

eg_ssgTableIndexproperty 
public var eg_ssgTableIndex:Array = null

EG:table from sgg_type to eg_levelTables index.

eg_tableSelectorproperty 
public var eg_tableSelector:Array = null

EG:table selector.

eg_timerStepsproperty 
public var eg_timerSteps:Array = null

EG:timer step.

eg_tlTable32dBproperty 
public var eg_tlTable32dB:Vector.<int> = null

EG:tl table from N88 basic v command.

eg_tlTable48dBproperty 
public var eg_tlTable48dB:Vector.<int> = null

EG:tl table from psg volume.

eg_tlTable64dBproperty 
public var eg_tlTable64dB:Vector.<int> = null

EG:tl table of fmp7 based.

eg_tlTable96dBproperty 
public var eg_tlTable96dB:Vector.<int> = null

EG:tl table of tl based.

eg_tlTableLineproperty 
public var eg_tlTableLine:Vector.<int> = null

EG:tl table from linear volume.

eg_tlTablesproperty 
public var eg_tlTables:Vector.<Vector.<int>> = null

EG:tl table from volume to tl.

filter_cutoffTableproperty 
public var filter_cutoffTable:Vector.<Number> = null

FILTER: cutoff

filter_eg_rateproperty 
public var filter_eg_rate:Vector.<int> = null

FILTER: envlop rate

filter_feedbackTableproperty 
public var filter_feedbackTable:Vector.<Number> = null

FILTER: resonance

final_oscilator_flagsproperty 
public var final_oscilator_flags:Array

Flags of final oscillator

i2nproperty 
public var i2n:Number

int->Number ratio on pulse data

instanceproperty 
instance:SiOPMTable  [read-only]

static sigleton instance


Implementation
    public static function get instance():SiOPMTable
lfo_chorusTablesproperty 
public var lfo_chorusTables:Vector.<int> = null

LFO:lfo modulation table for chorus

lfo_timerStepsproperty 
public var lfo_timerSteps:Vector.<int> = null

LFO:timer step.

lfo_waveTablesproperty 
public var lfo_waveTables:Array = null

LFO:lfo modulation table

logTableproperty 
public var logTable:Vector.<int> = null

PG:log table.

nnToKCproperty 
public var nnToKC:Vector.<int> = null

PG:MIDI note number to FM key code.

noWaveTableproperty 
public var noWaveTable:SiOPMWaveTable

PG:Wave tables without any waves.

noWaveTableOPMproperty 
public var noWaveTableOPM:SiOPMWaveTable

panTableproperty 
public var panTable:Vector.<Number> = null

Panning volume table.

phaseStepShiftFilterproperty 
public var phaseStepShiftFilter:Vector.<int> = null

PG:phase step shift filter.

pitchTableproperty 
public var pitchTable:Vector.<Vector.<int>> = null

PG:pitch table.

pitchWaveLengthproperty 
public var pitchWaveLength:Vector.<Number> = null

PG:pitch wave length (in samples) table.

psg_clockproperty 
public var psg_clock:Number

psg clock

rateproperty 
public var rate:int

sampling rate

sampleRatePitchShiftproperty 
public var sampleRatePitchShift:int

44100Hz=0, 22050Hz=1

samplerTablesproperty 
public var samplerTables:Vector.<SiOPMWaveSamplerTable> = null

PG:Sampler table

soundReferenceproperty 
public var soundReference:* = null

PG:Sound reference table

waveTablesproperty 
public var waveTables:Vector.<SiOPMWaveTable> = null

PG:Wave tables

Constructor Detail
SiOPMTable()Constructor
public function SiOPMTable(clock:int, psg_clock:Number, rate:int)

constructor

Parameters
clock:int — FM module's clock.
 
psg_clock:Number — Sampling rate of wave data
 
rate:int
Method Detail
calcLogTableIndex()method
public static function calcLogTableIndex(n:Number):int

calculate log table index from Number[-1,1].

Parameters

n:Number

Returns
int
getPCMData()method 
public function getPCMData(index:int):SiOPMWavePCMTable

get PCM data from a list of SiONDriver and SiONData

Parameters

index:int

Returns
SiOPMWavePCMTable
getWaveTable()method 
public function getWaveTable(index:int):SiOPMWaveTable

get wave table from a list of SiONDriver and SiONData

Parameters

index:int

Returns
SiOPMWaveTable
Constant Detail
CLOCK_RATIO_BITSConstant
public static const CLOCK_RATIO_BITS:int = 10

DEFAULT_PG_MAXConstant 
public static const DEFAULT_PG_MAX:int = 256

ENV_BITSConstant 
public static const ENV_BITS:int = 10

ENV_BOTTOMConstant 
public static const ENV_BOTTOM:int

ENV_BOTTOM_SSGECConstant 
public static const ENV_BOTTOM_SSGEC:int

ENV_LSHIFTConstant 
public static const ENV_LSHIFT:int = 3.0

ENV_TIMER_BITSConstant 
public static const ENV_TIMER_BITS:int = 24

ENV_TIMER_INITIALConstant 
public static const ENV_TIMER_INITIAL:int

ENV_TOPConstant 
public static const ENV_TOP:int

FIXED_BITSConstant 
public static const FIXED_BITS:int = 16

HALF_TONE_BITSConstant 
public static const HALF_TONE_BITS:int = 6

HALF_TONE_RESOLUTIONConstant 
public static const HALF_TONE_RESOLUTION:int

KEY_CODE_TABLE_SIZEConstant 
public static const KEY_CODE_TABLE_SIZE:int = 128

LFO_FIXED_BITSConstant 
public static const LFO_FIXED_BITS:int = 20

LFO_TABLE_SIZEConstant 
public static const LFO_TABLE_SIZE:int = 256

LFO_TIMER_INITIALConstant 
public static const LFO_TIMER_INITIAL:int

LFO_WAVE_MAXConstant 
public static const LFO_WAVE_MAX:int = 8

LFO_WAVE_NOISEConstant 
public static const LFO_WAVE_NOISE:int = 3

LFO_WAVE_SAWConstant 
public static const LFO_WAVE_SAW:int = 0

LFO_WAVE_SQUAREConstant 
public static const LFO_WAVE_SQUARE:int = 1

LFO_WAVE_TRIANGLEConstant 
public static const LFO_WAVE_TRIANGLE:int = 2

LOG_TABLE_BOTTOMConstant 
public static const LOG_TABLE_BOTTOM:int = 6656.0

LOG_TABLE_MAX_BITSConstant 
public static const LOG_TABLE_MAX_BITS:int = 16

LOG_TABLE_RESOLUTIONConstant 
public static const LOG_TABLE_RESOLUTION:int = 256

LOG_TABLE_SIZEConstant 
public static const LOG_TABLE_SIZE:int = 8192.0

LOG_VOLUME_BITSConstant 
public static const LOG_VOLUME_BITS:int = 13

NOISE_TABLE_BITSConstant 
public static const NOISE_TABLE_BITS:int = 15

NOISE_TABLE_SIZEConstant 
public static const NOISE_TABLE_SIZE:int

NOISE_WAVE_OUTPUTConstant 
public static const NOISE_WAVE_OUTPUT:Number = 1

NOTE_BITSConstant 
public static const NOTE_BITS:int = 7

NOTE_TABLE_SIZEConstant 
public static const NOTE_TABLE_SIZE:int

OUTPUT_MAXConstant 
public static const OUTPUT_MAX:Number = 0.5

PCM_BITSConstant 
public static const PCM_BITS:int = 20

PCM_DATA_MAXConstant 
public static const PCM_DATA_MAX:int = 128

PG_CUSTOMConstant 
public static const PG_CUSTOM:int = 256

PG_FILTERConstant 
public static const PG_FILTER:int = 511

PG_KNMBSMMConstant 
public static const PG_KNMBSMM:int = 7

PG_MA3_WAVEConstant 
public static const PG_MA3_WAVE:int = 32

PG_NOISEConstant 
public static const PG_NOISE:int = 6

PG_NOISE_GB_SHORTConstant 
public static const PG_NOISE_GB_SHORT:int = 21

PG_NOISE_HIPASConstant 
public static const PG_NOISE_HIPAS:int = 19

PG_NOISE_PINKConstant 
public static const PG_NOISE_PINK:int = 20

PG_NOISE_PULSEConstant 
public static const PG_NOISE_PULSE:int = 17

PG_NOISE_SHORTConstant 
public static const PG_NOISE_SHORT:int = 18

PG_NOISE_WHITEConstant 
public static const PG_NOISE_WHITE:int = 16

PG_OFFSETConstant 
public static const PG_OFFSET:int = 10

PG_PC_NZ_16BITConstant 
public static const PG_PC_NZ_16BIT:int = 24

PG_PC_NZ_OPMConstant 
public static const PG_PC_NZ_OPM:int = 26

PG_PC_NZ_SHORTConstant 
public static const PG_PC_NZ_SHORT:int = 25

PG_PCMConstant 
public static const PG_PCM:int = 384

PG_PULSEConstant 
public static const PG_PULSE:int = 64

PG_PULSE_SPIKEConstant 
public static const PG_PULSE_SPIKE:int = 80

PG_RAMPConstant 
public static const PG_RAMP:int = 128

PG_SAW_DOWNConstant 
public static const PG_SAW_DOWN:int = 2

PG_SAW_UPConstant 
public static const PG_SAW_UP:int = 1

PG_SAW_VC6Constant 
public static const PG_SAW_VC6:int = 11

PG_SINEConstant 
public static const PG_SINE:int = 0

PG_SQUAREConstant 
public static const PG_SQUARE:int = 5

PG_SYNC_HIGHConstant 
public static const PG_SYNC_HIGH:int = 9

PG_SYNC_LOWConstant 
public static const PG_SYNC_LOW:int = 8

PG_TRIANGLEConstant 
public static const PG_TRIANGLE:int = 4

PG_TRIANGLE_FCConstant 
public static const PG_TRIANGLE_FC:int = 3

PG_USER_CUSTOMConstant 
public static const PG_USER_CUSTOM:int = -1

PG_USER_PCMConstant 
public static const PG_USER_PCM:int = -2

PHASE_BITSConstant 
public static const PHASE_BITS:int = 26.0

PHASE_FILTERConstant 
public static const PHASE_FILTER:int

PHASE_MAXConstant 
public static const PHASE_MAX:int

PHASE_SIGN_RSHIFTConstant 
public static const PHASE_SIGN_RSHIFT:int = 25.0

PITCH_TABLE_SIZEConstant 
public static const PITCH_TABLE_SIZE:int

PT_APU_NOISEConstant 
public static const PT_APU_NOISE:int = 5

PT_GB_NOISEConstant 
public static const PT_GB_NOISE:int = 6

PT_MAXConstant 
public static const PT_MAX:int = 7

PT_OPMConstant 
public static const PT_OPM:int = 0

PT_OPM_NOISEConstant 
public static const PT_OPM_NOISE:int = 3

PT_PCMConstant 
public static const PT_PCM:int = 1

PT_PSGConstant 
public static const PT_PSG:int = 2

PT_PSG_NOISEConstant 
public static const PT_PSG_NOISE:int = 4

SAMPLER_DATA_MAXConstant 
public static const SAMPLER_DATA_MAX:int

SAMPLER_TABLE_MAXConstant 
public static const SAMPLER_TABLE_MAX:int = 4

SAMPLING_TABLE_BITSConstant 
public static const SAMPLING_TABLE_BITS:int = 10

SAMPLING_TABLE_SIZEConstant 
public static const SAMPLING_TABLE_SIZE:int

SQUARE_WAVE_OUTPUTConstant 
public static const SQUARE_WAVE_OUTPUT:Number = 1

VM_DR32DBConstant 
public static const VM_DR32DB:int = 4

VM_DR48DBConstant 
public static const VM_DR48DB:int = 3

VM_DR64DBConstant 
public static const VM_DR64DB:int = 2

VM_DR96DBConstant 
public static const VM_DR96DB:int = 1

VM_LINEARConstant 
public static const VM_LINEAR:int = 0

VM_MAXConstant 
public static const VM_MAX:int = 5

WAVE_TABLE_MAXConstant 
public static const WAVE_TABLE_MAX:int = 128