mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-29 12:19:12 +00:00
Core/AudioCommon: Add config caching to Mixer.
This commit is contained in:
parent
ed1a1c1fae
commit
eb5bb2993e
2 changed files with 41 additions and 13 deletions
|
@ -69,7 +69,8 @@ private:
|
|||
}
|
||||
void DoState(PointerWrap& p);
|
||||
void PushSamples(const short* samples, unsigned int num_samples);
|
||||
unsigned int Mix(short* samples, unsigned int numSamples, bool consider_framelimit = true);
|
||||
unsigned int Mix(short* samples, unsigned int numSamples, bool consider_framelimit,
|
||||
float emulationspeed, int timing_variance);
|
||||
void SetInputSampleRate(unsigned int rate);
|
||||
unsigned int GetInputSampleRate() const;
|
||||
void SetVolume(unsigned int lvolume, unsigned int rvolume);
|
||||
|
@ -89,6 +90,8 @@ private:
|
|||
u32 m_frac = 0;
|
||||
};
|
||||
|
||||
void RefreshConfig();
|
||||
|
||||
MixerFifo m_dma_mixer{this, 32000, false};
|
||||
MixerFifo m_streaming_mixer{this, 48000, false};
|
||||
MixerFifo m_wiimote_speaker_mixer{this, 3000, true};
|
||||
|
@ -109,4 +112,10 @@ private:
|
|||
|
||||
// Current rate of emulation (1.0 = 100% speed)
|
||||
std::atomic<float> m_speed{0.0f};
|
||||
|
||||
float m_config_emulation_speed;
|
||||
int m_config_timing_variance;
|
||||
bool m_config_audio_stretch;
|
||||
|
||||
size_t m_config_changed_callback_id;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue