diff options
| -rw-r--r-- | src/core/CMakeLists.txt | 14 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audctl.cpp | 45 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audctl.h | 16 | ||||
| -rw-r--r-- | src/core/hle/service/audio/auddbg.cpp | 20 | ||||
| -rw-r--r-- | src/core/hle/service/audio/auddbg.h | 16 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audin_a.cpp | 24 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audin_a.h | 16 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audio.cpp | 16 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audout_a.cpp | 26 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audout_a.h | 16 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audrec_a.cpp | 22 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audrec_a.h | 16 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audren_a.cpp | 28 | ||||
| -rw-r--r-- | src/core/hle/service/audio/audren_a.h | 16 |
14 files changed, 289 insertions, 2 deletions
diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt index 3e13fc25b..cd2960f81 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt | |||
| @@ -126,17 +126,27 @@ add_library(core STATIC | |||
| 126 | hle/service/apm/apm.h | 126 | hle/service/apm/apm.h |
| 127 | hle/service/apm/interface.cpp | 127 | hle/service/apm/interface.cpp |
| 128 | hle/service/apm/interface.h | 128 | hle/service/apm/interface.h |
| 129 | hle/service/audio/audctl.cpp | ||
| 130 | hle/service/audio/audctl.h | ||
| 131 | hle/service/audio/auddbg.cpp | ||
| 132 | hle/service/audio/auddbg.h | ||
| 133 | hle/service/audio/audin_a.cpp | ||
| 134 | hle/service/audio/audin_a.h | ||
| 129 | hle/service/audio/audin_u.cpp | 135 | hle/service/audio/audin_u.cpp |
| 130 | hle/service/audio/audin_u.h | 136 | hle/service/audio/audin_u.h |
| 131 | hle/service/audio/audio.cpp | 137 | hle/service/audio/audio.cpp |
| 132 | hle/service/audio/audio.h | 138 | hle/service/audio/audio.h |
| 139 | hle/service/audio/audout_a.cpp | ||
| 140 | hle/service/audio/audout_a.h | ||
| 133 | hle/service/audio/audout_u.cpp | 141 | hle/service/audio/audout_u.cpp |
| 134 | hle/service/audio/audout_u.h | 142 | hle/service/audio/audout_u.h |
| 143 | hle/service/audio/audrec_a.cpp | ||
| 144 | hle/service/audio/audrec_a.h | ||
| 135 | hle/service/audio/audrec_u.cpp | 145 | hle/service/audio/audrec_u.cpp |
| 136 | hle/service/audio/audrec_u.h | 146 | hle/service/audio/audrec_u.h |
| 147 | hle/service/audio/audren_a.cpp | ||
| 148 | hle/service/audio/audren_a.h | ||
| 137 | hle/service/audio/audren_u.cpp | 149 | hle/service/audio/audren_u.cpp |
| 138 | hle/service/audio/audren_u.cpp | ||
| 139 | hle/service/audio/audren_u.h | ||
| 140 | hle/service/audio/audren_u.h | 150 | hle/service/audio/audren_u.h |
| 141 | hle/service/audio/codecctl.cpp | 151 | hle/service/audio/codecctl.cpp |
| 142 | hle/service/audio/codecctl.h | 152 | hle/service/audio/codecctl.h |
diff --git a/src/core/hle/service/audio/audctl.cpp b/src/core/hle/service/audio/audctl.cpp new file mode 100644 index 000000000..37c3fdcac --- /dev/null +++ b/src/core/hle/service/audio/audctl.cpp | |||
| @@ -0,0 +1,45 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #include "core/hle/service/audio/audctl.h" | ||
| 6 | |||
| 7 | namespace Service::Audio { | ||
| 8 | |||
| 9 | AudCtl::AudCtl() : ServiceFramework{"audctl"} { | ||
| 10 | // clang-format off | ||
| 11 | static const FunctionInfo functions[] = { | ||
| 12 | {0, nullptr, "GetTargetVolume"}, | ||
| 13 | {1, nullptr, "SetTargetVolume"}, | ||
| 14 | {2, nullptr, "GetTargetVolumeMin"}, | ||
| 15 | {3, nullptr, "GetTargetVolumeMax"}, | ||
| 16 | {4, nullptr, "IsTargetMute"}, | ||
| 17 | {5, nullptr, "SetTargetMute"}, | ||
| 18 | {6, nullptr, "IsTargetConnected"}, | ||
| 19 | {7, nullptr, "SetDefaultTarget"}, | ||
| 20 | {8, nullptr, "GetDefaultTarget"}, | ||
| 21 | {9, nullptr, "GetAudioOutputMode"}, | ||
| 22 | {10, nullptr, "SetAudioOutputMode"}, | ||
| 23 | {11, nullptr, "SetForceMutePolicy"}, | ||
| 24 | {12, nullptr, "GetForceMutePolicy"}, | ||
| 25 | {13, nullptr, "GetOutputModeSetting"}, | ||
| 26 | {14, nullptr, "SetOutputModeSetting"}, | ||
| 27 | {15, nullptr, "SetOutputTarget"}, | ||
| 28 | {16, nullptr, "SetInputTargetForceEnabled"}, | ||
| 29 | {17, nullptr, "SetHeadphoneOutputLevelMode"}, | ||
| 30 | {18, nullptr, "GetHeadphoneOutputLevelMode"}, | ||
| 31 | {19, nullptr, "AcquireAudioVolumeUpdateEventForPlayReport"}, | ||
| 32 | {20, nullptr, "AcquireAudioOutputDeviceUpdateEventForPlayReport"}, | ||
| 33 | {21, nullptr, "GetAudioOutputTargetForPlayReport"}, | ||
| 34 | {22, nullptr, "NotifyHeadphoneVolumeWarningDisplayedEvent"}, | ||
| 35 | {23, nullptr, "SetSystemOutputMasterVolume"}, | ||
| 36 | {24, nullptr, "GetSystemOutputMasterVolume"}, | ||
| 37 | {25, nullptr, "GetAudioVolumeDataForPlayReport"}, | ||
| 38 | {26, nullptr, "UpdateHeadphoneSettings"}, | ||
| 39 | }; | ||
| 40 | // clang-format on | ||
| 41 | |||
| 42 | RegisterHandlers(functions); | ||
| 43 | } | ||
| 44 | |||
| 45 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/audctl.h b/src/core/hle/service/audio/audctl.h new file mode 100644 index 000000000..ed837bdf2 --- /dev/null +++ b/src/core/hle/service/audio/audctl.h | |||
| @@ -0,0 +1,16 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/service.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | class AudCtl final : public ServiceFramework<AudCtl> { | ||
| 12 | public: | ||
| 13 | explicit AudCtl(); | ||
| 14 | }; | ||
| 15 | |||
| 16 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/auddbg.cpp b/src/core/hle/service/audio/auddbg.cpp new file mode 100644 index 000000000..b08c21a20 --- /dev/null +++ b/src/core/hle/service/audio/auddbg.cpp | |||
| @@ -0,0 +1,20 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #include "core/hle/service/audio/auddbg.h" | ||
| 6 | |||
| 7 | namespace Service::Audio { | ||
| 8 | |||
| 9 | AudDbg::AudDbg(const char* name) : ServiceFramework{name} { | ||
| 10 | // clang-format off | ||
| 11 | static const FunctionInfo functions[] = { | ||
| 12 | {0, nullptr, "RequestSuspendForDebug"}, | ||
| 13 | {1, nullptr, "RequestResumeForDebug"}, | ||
| 14 | }; | ||
| 15 | // clang-format on | ||
| 16 | |||
| 17 | RegisterHandlers(functions); | ||
| 18 | } | ||
| 19 | |||
| 20 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/auddbg.h b/src/core/hle/service/audio/auddbg.h new file mode 100644 index 000000000..a2f540b75 --- /dev/null +++ b/src/core/hle/service/audio/auddbg.h | |||
| @@ -0,0 +1,16 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/service.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | class AudDbg final : public ServiceFramework<AudDbg> { | ||
| 12 | public: | ||
| 13 | explicit AudDbg(const char* name); | ||
| 14 | }; | ||
| 15 | |||
| 16 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/audin_a.cpp b/src/core/hle/service/audio/audin_a.cpp new file mode 100644 index 000000000..e62a27945 --- /dev/null +++ b/src/core/hle/service/audio/audin_a.cpp | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/audio/audin_a.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | AudInA::AudInA() : ServiceFramework{"audin:a"} { | ||
| 12 | // clang-format off | ||
| 13 | static const FunctionInfo functions[] = { | ||
| 14 | {0, nullptr, "RequestSuspendAudioIns"}, | ||
| 15 | {1, nullptr, "RequestResumeAudioIns"}, | ||
| 16 | {2, nullptr, "GetAudioInsProcessMasterVolume"}, | ||
| 17 | {3, nullptr, "SetAudioInsProcessMasterVolume"}, | ||
| 18 | }; | ||
| 19 | // clang-format on | ||
| 20 | |||
| 21 | RegisterHandlers(functions); | ||
| 22 | } | ||
| 23 | |||
| 24 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/audin_a.h b/src/core/hle/service/audio/audin_a.h new file mode 100644 index 000000000..e4c75510f --- /dev/null +++ b/src/core/hle/service/audio/audin_a.h | |||
| @@ -0,0 +1,16 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/service.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | class AudInA final : public ServiceFramework<AudInA> { | ||
| 12 | public: | ||
| 13 | explicit AudInA(); | ||
| 14 | }; | ||
| 15 | |||
| 16 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/audio.cpp b/src/core/hle/service/audio/audio.cpp index d231e91e1..6b5e15633 100644 --- a/src/core/hle/service/audio/audio.cpp +++ b/src/core/hle/service/audio/audio.cpp | |||
| @@ -2,10 +2,16 @@ | |||
| 2 | // Licensed under GPLv2 or any later version | 2 | // Licensed under GPLv2 or any later version |
| 3 | // Refer to the license.txt file included. | 3 | // Refer to the license.txt file included. |
| 4 | 4 | ||
| 5 | #include "core/hle/service/audio/audctl.h" | ||
| 6 | #include "core/hle/service/audio/auddbg.h" | ||
| 7 | #include "core/hle/service/audio/audin_a.h" | ||
| 5 | #include "core/hle/service/audio/audin_u.h" | 8 | #include "core/hle/service/audio/audin_u.h" |
| 6 | #include "core/hle/service/audio/audio.h" | 9 | #include "core/hle/service/audio/audio.h" |
| 10 | #include "core/hle/service/audio/audout_a.h" | ||
| 7 | #include "core/hle/service/audio/audout_u.h" | 11 | #include "core/hle/service/audio/audout_u.h" |
| 12 | #include "core/hle/service/audio/audrec_a.h" | ||
| 8 | #include "core/hle/service/audio/audrec_u.h" | 13 | #include "core/hle/service/audio/audrec_u.h" |
| 14 | #include "core/hle/service/audio/audren_a.h" | ||
| 9 | #include "core/hle/service/audio/audren_u.h" | 15 | #include "core/hle/service/audio/audren_u.h" |
| 10 | #include "core/hle/service/audio/codecctl.h" | 16 | #include "core/hle/service/audio/codecctl.h" |
| 11 | #include "core/hle/service/audio/hwopus.h" | 17 | #include "core/hle/service/audio/hwopus.h" |
| @@ -13,12 +19,22 @@ | |||
| 13 | namespace Service::Audio { | 19 | namespace Service::Audio { |
| 14 | 20 | ||
| 15 | void InstallInterfaces(SM::ServiceManager& service_manager) { | 21 | void InstallInterfaces(SM::ServiceManager& service_manager) { |
| 22 | std::make_shared<AudCtl>()->InstallAsService(service_manager); | ||
| 23 | std::make_shared<AudOutA>()->InstallAsService(service_manager); | ||
| 16 | std::make_shared<AudOutU>()->InstallAsService(service_manager); | 24 | std::make_shared<AudOutU>()->InstallAsService(service_manager); |
| 25 | std::make_shared<AudInA>()->InstallAsService(service_manager); | ||
| 17 | std::make_shared<AudInU>()->InstallAsService(service_manager); | 26 | std::make_shared<AudInU>()->InstallAsService(service_manager); |
| 27 | std::make_shared<AudRecA>()->InstallAsService(service_manager); | ||
| 18 | std::make_shared<AudRecU>()->InstallAsService(service_manager); | 28 | std::make_shared<AudRecU>()->InstallAsService(service_manager); |
| 29 | std::make_shared<AudRenA>()->InstallAsService(service_manager); | ||
| 19 | std::make_shared<AudRenU>()->InstallAsService(service_manager); | 30 | std::make_shared<AudRenU>()->InstallAsService(service_manager); |
| 20 | std::make_shared<CodecCtl>()->InstallAsService(service_manager); | 31 | std::make_shared<CodecCtl>()->InstallAsService(service_manager); |
| 21 | std::make_shared<HwOpus>()->InstallAsService(service_manager); | 32 | std::make_shared<HwOpus>()->InstallAsService(service_manager); |
| 33 | |||
| 34 | std::make_shared<AudDbg>("audin:d")->InstallAsService(service_manager); | ||
| 35 | std::make_shared<AudDbg>("audout:d")->InstallAsService(service_manager); | ||
| 36 | std::make_shared<AudDbg>("audrec:d")->InstallAsService(service_manager); | ||
| 37 | std::make_shared<AudDbg>("audren:d")->InstallAsService(service_manager); | ||
| 22 | } | 38 | } |
| 23 | 39 | ||
| 24 | } // namespace Service::Audio | 40 | } // namespace Service::Audio |
diff --git a/src/core/hle/service/audio/audout_a.cpp b/src/core/hle/service/audio/audout_a.cpp new file mode 100644 index 000000000..57b934dd6 --- /dev/null +++ b/src/core/hle/service/audio/audout_a.cpp | |||
| @@ -0,0 +1,26 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/audio/audout_a.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | AudOutA::AudOutA() : ServiceFramework{"audout:a"} { | ||
| 12 | // clang-format off | ||
| 13 | static const FunctionInfo functions[] = { | ||
| 14 | {0, nullptr, "RequestSuspendAudioOuts"}, | ||
| 15 | {1, nullptr, "RequestResumeAudioOuts"}, | ||
| 16 | {2, nullptr, "GetAudioOutsProcessMasterVolume"}, | ||
| 17 | {3, nullptr, "SetAudioOutsProcessMasterVolume"}, | ||
| 18 | {4, nullptr, "GetAudioOutsProcessRecordVolume"}, | ||
| 19 | {5, nullptr, "SetAudioOutsProcessRecordVolume"}, | ||
| 20 | }; | ||
| 21 | // clang-format on | ||
| 22 | |||
| 23 | RegisterHandlers(functions); | ||
| 24 | } | ||
| 25 | |||
| 26 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/audout_a.h b/src/core/hle/service/audio/audout_a.h new file mode 100644 index 000000000..91a069152 --- /dev/null +++ b/src/core/hle/service/audio/audout_a.h | |||
| @@ -0,0 +1,16 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/service.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | class AudOutA final : public ServiceFramework<AudOutA> { | ||
| 12 | public: | ||
| 13 | explicit AudOutA(); | ||
| 14 | }; | ||
| 15 | |||
| 16 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/audrec_a.cpp b/src/core/hle/service/audio/audrec_a.cpp new file mode 100644 index 000000000..9c32f9b98 --- /dev/null +++ b/src/core/hle/service/audio/audrec_a.cpp | |||
| @@ -0,0 +1,22 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/audio/audrec_a.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | AudRecA::AudRecA() : ServiceFramework{"audrec:a"} { | ||
| 12 | // clang-format off | ||
| 13 | static const FunctionInfo functions[] = { | ||
| 14 | {0, nullptr, "RequestSuspendFinalOutputRecorders"}, | ||
| 15 | {1, nullptr, "RequestResumeFinalOutputRecorders"}, | ||
| 16 | }; | ||
| 17 | // clang-format on | ||
| 18 | |||
| 19 | RegisterHandlers(functions); | ||
| 20 | } | ||
| 21 | |||
| 22 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/audrec_a.h b/src/core/hle/service/audio/audrec_a.h new file mode 100644 index 000000000..9685047f2 --- /dev/null +++ b/src/core/hle/service/audio/audrec_a.h | |||
| @@ -0,0 +1,16 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/service.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | class AudRecA final : public ServiceFramework<AudRecA> { | ||
| 12 | public: | ||
| 13 | explicit AudRecA(); | ||
| 14 | }; | ||
| 15 | |||
| 16 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/audren_a.cpp b/src/core/hle/service/audio/audren_a.cpp new file mode 100644 index 000000000..bc9930d79 --- /dev/null +++ b/src/core/hle/service/audio/audren_a.cpp | |||
| @@ -0,0 +1,28 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/audio/audren_a.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | AudRenA::AudRenA() : ServiceFramework{"audren:a"} { | ||
| 12 | // clang-format off | ||
| 13 | static const FunctionInfo functions[] = { | ||
| 14 | {0, nullptr, "RequestSuspendAudioRenderers"}, | ||
| 15 | {1, nullptr, "RequestResumeAudioRenderers"}, | ||
| 16 | {2, nullptr, "GetAudioRenderersProcessMasterVolume"}, | ||
| 17 | {3, nullptr, "SetAudioRenderersProcessMasterVolume"}, | ||
| 18 | {4, nullptr, "RegisterAppletResourceUserId"}, | ||
| 19 | {5, nullptr, "UnregisterAppletResourceUserId"}, | ||
| 20 | {6, nullptr, "GetAudioRenderersProcessRecordVolume"}, | ||
| 21 | {7, nullptr, "SetAudioRenderersProcessRecordVolume"}, | ||
| 22 | }; | ||
| 23 | // clang-format on | ||
| 24 | |||
| 25 | RegisterHandlers(functions); | ||
| 26 | } | ||
| 27 | |||
| 28 | } // namespace Service::Audio | ||
diff --git a/src/core/hle/service/audio/audren_a.h b/src/core/hle/service/audio/audren_a.h new file mode 100644 index 000000000..5ecf2e184 --- /dev/null +++ b/src/core/hle/service/audio/audren_a.h | |||
| @@ -0,0 +1,16 @@ | |||
| 1 | // Copyright 2018 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include "core/hle/service/service.h" | ||
| 8 | |||
| 9 | namespace Service::Audio { | ||
| 10 | |||
| 11 | class AudRenA final : public ServiceFramework<AudRenA> { | ||
| 12 | public: | ||
| 13 | explicit AudRenA(); | ||
| 14 | }; | ||
| 15 | |||
| 16 | } // namespace Service::Audio | ||