2015-05-23 22:55:12 -06:00
|
|
|
// Copyright 2009 Dolphin Emulator Project
|
2015-05-17 17:08:10 -06:00
|
|
|
// Licensed under GPLv2+
|
2013-04-17 21:09:55 -06:00
|
|
|
// Refer to the license.txt file included.
|
2009-07-05 20:10:26 -06:00
|
|
|
|
2014-02-10 11:54:46 -07:00
|
|
|
#pragma once
|
2009-07-05 20:10:26 -06:00
|
|
|
|
2016-07-31 10:35:08 -06:00
|
|
|
#include <memory>
|
2016-12-11 04:11:34 -07:00
|
|
|
#include <string>
|
|
|
|
#include <vector>
|
2016-07-31 10:35:08 -06:00
|
|
|
|
2014-02-17 03:18:15 -07:00
|
|
|
#include "AudioCommon/SoundStream.h"
|
2009-07-05 20:10:26 -06:00
|
|
|
|
2017-06-26 15:41:12 -06:00
|
|
|
class Mixer;
|
2009-07-05 20:10:26 -06:00
|
|
|
|
2016-07-31 10:35:08 -06:00
|
|
|
extern std::unique_ptr<SoundStream> g_sound_stream;
|
2009-07-05 20:10:26 -06:00
|
|
|
|
2013-10-28 23:23:17 -06:00
|
|
|
namespace AudioCommon
|
2009-07-05 20:10:26 -06:00
|
|
|
{
|
2016-07-31 10:35:08 -06:00
|
|
|
void InitSoundStream();
|
2016-06-24 02:43:46 -06:00
|
|
|
void ShutdownSoundStream();
|
2017-02-04 18:15:38 -07:00
|
|
|
std::string GetDefaultSoundBackend();
|
2016-06-24 02:43:46 -06:00
|
|
|
std::vector<std::string> GetSoundBackends();
|
2016-10-09 20:18:16 -06:00
|
|
|
bool SupportsDPL2Decoder(const std::string& backend);
|
|
|
|
bool SupportsLatencyControl(const std::string& backend);
|
|
|
|
bool SupportsVolumeChanges(const std::string& backend);
|
2016-06-24 02:43:46 -06:00
|
|
|
void UpdateSoundStream();
|
2017-10-21 13:35:58 -06:00
|
|
|
void SetSoundStreamRunning(bool running);
|
2016-07-31 17:14:20 -06:00
|
|
|
void SendAIBuffer(const short* samples, unsigned int num_samples);
|
2016-06-24 02:43:46 -06:00
|
|
|
void StartAudioDump();
|
|
|
|
void StopAudioDump();
|
|
|
|
void IncreaseVolume(unsigned short offset);
|
|
|
|
void DecreaseVolume(unsigned short offset);
|
|
|
|
void ToggleMuteVolume();
|
2019-05-05 17:48:12 -06:00
|
|
|
} // namespace AudioCommon
|