summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/sound/okim9810.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/emu/sound/okim9810.h')
-rw-r--r--src/emu/sound/okim9810.h76
1 files changed, 38 insertions, 38 deletions
diff --git a/src/emu/sound/okim9810.h b/src/emu/sound/okim9810.h
index 459c4edc046..75316b7cf96 100644
--- a/src/emu/sound/okim9810.h
+++ b/src/emu/sound/okim9810.h
@@ -27,15 +27,15 @@ enum
OKIM9810_ADPCM_PLAYBACK = 0,
OKIM9810_ADPCM2_PLAYBACK = 1,
OKIM9810_STRAIGHT8_PLAYBACK = 2,
- OKIM9810_NONLINEAR8_PLAYBACK = 3
+ OKIM9810_NONLINEAR8_PLAYBACK = 3
};
enum
{
OKIM9810_SECONDARY_FILTER = 0,
OKIM9810_PRIMARY_FILTER = 1,
- OKIM9810_NO_FILTER = 2,
- OKIM9810_NO_FILTER2 = 3
+ OKIM9810_NO_FILTER = 2,
+ OKIM9810_NO_FILTER2 = 3
};
enum
@@ -93,43 +93,43 @@ protected:
// device_sound_interface overrides
virtual void sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples);
- // a single voice
+ // a single voice
class okim_voice
{
public:
okim_voice();
void generate_audio(direct_read_data &direct,
- stream_sample_t **buffers,
- int samples,
- const UINT8 global_volume,
- const UINT32 clock,
- const UINT8 filter_type);
+ stream_sample_t **buffers,
+ int samples,
+ const UINT8 global_volume,
+ const UINT32 clock,
+ const UINT8 filter_type);
- // computes volume scale from 3 volume numbers
+ // computes volume scale from 3 volume numbers
UINT8 volume_scale(const UINT8 global_volume,
- const UINT8 channel_volume,
- const UINT8 pan_volume) const;
-
- oki_adpcm_state m_adpcm; // current ADPCM state
- oki_adpcm2_state m_adpcm2; // current ADPCM2 state
- UINT8 m_playbackAlgo; // current playback method
- bool m_looping;
- UINT8 m_startFlags;
- UINT8 m_endFlags;
- offs_t m_base_offset; // pointer to the base memory location
- UINT32 m_count; // total samples to play
- UINT32 m_samplingFreq; // voice sampling frequency
-
- bool m_playing; // playback state
- UINT32 m_sample; // current sample number
-
- UINT8 m_channel_volume; // volume index set with the CVOL command
- UINT8 m_pan_volume_left; // volume index set with the PAN command
- UINT8 m_pan_volume_right; // volume index set with the PAN command
-
- INT32 m_startSample; // interpolation state - sample to interpolate from
- INT32 m_endSample; // interpolation state - sample to interpolate to
- UINT32 m_interpSampleNum; // interpolation state - fraction between start & end
+ const UINT8 channel_volume,
+ const UINT8 pan_volume) const;
+
+ oki_adpcm_state m_adpcm; // current ADPCM state
+ oki_adpcm2_state m_adpcm2; // current ADPCM2 state
+ UINT8 m_playbackAlgo; // current playback method
+ bool m_looping;
+ UINT8 m_startFlags;
+ UINT8 m_endFlags;
+ offs_t m_base_offset; // pointer to the base memory location
+ UINT32 m_count; // total samples to play
+ UINT32 m_samplingFreq; // voice sampling frequency
+
+ bool m_playing; // playback state
+ UINT32 m_sample; // current sample number
+
+ UINT8 m_channel_volume; // volume index set with the CVOL command
+ UINT8 m_pan_volume_left; // volume index set with the PAN command
+ UINT8 m_pan_volume_right; // volume index set with the PAN command
+
+ INT32 m_startSample; // interpolation state - sample to interpolate from
+ INT32 m_endSample; // interpolation state - sample to interpolate to
+ UINT32 m_interpSampleNum; // interpolation state - fraction between start & end
static const UINT8 s_volume_table[16];
};
@@ -141,16 +141,16 @@ protected:
sound_stream* m_stream;
direct_read_data* m_direct;
- UINT8 m_TMP_register;
+ UINT8 m_TMP_register;
- UINT8 m_global_volume; // volume index set with the OPT command
- UINT8 m_filter_type; // interpolation filter type set with the OPT command
- UINT8 m_output_level; // flag stating if a voltage follower is connected
+ UINT8 m_global_volume; // volume index set with the OPT command
+ UINT8 m_filter_type; // interpolation filter type set with the OPT command
+ UINT8 m_output_level; // flag stating if a voltage follower is connected
static const int OKIM9810_VOICES = 8;
okim_voice m_voice[OKIM9810_VOICES];
- static const UINT32 s_sampling_freq_table[16];
+ static const UINT32 s_sampling_freq_table[16];
};