aboutsummaryrefslogtreecommitdiff
path: root/src/core/hle/service/audio/audio.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/hle/service/audio/audio.cpp')
-rw-r--r--src/core/hle/service/audio/audio.cpp208
1 files changed, 104 insertions, 104 deletions
diff --git a/src/core/hle/service/audio/audio.cpp b/src/core/hle/service/audio/audio.cpp
index 6177efd46c..fde766a275 100644
--- a/src/core/hle/service/audio/audio.cpp
+++ b/src/core/hle/service/audio/audio.cpp
@@ -21,164 +21,164 @@ namespace Service::Audio {
class IAudioOutManagerForApplet final : public ServiceFramework<IAudioOutManagerForApplet> {
public:
explicit IAudioOutManagerForApplet(Core::System& system_)
- : ServiceFramework{system_, "audout:a"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "RequestSuspend"},
- FunctionInfo{1, nullptr, "RequestResume"},
- FunctionInfo{2, nullptr, "GetProcessMasterVolume"},
- FunctionInfo{3, nullptr, "SetProcessMasterVolume"},
- FunctionInfo{4, nullptr, "GetProcessRecordVolume"},
- FunctionInfo{5, nullptr, "SetProcessRecordVolume"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "audout:a"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "RequestSuspend"},
+ {1, nullptr, "RequestResume"},
+ {2, nullptr, "GetProcessMasterVolume"},
+ {3, nullptr, "SetProcessMasterVolume"},
+ {4, nullptr, "GetProcessRecordVolume"},
+ {5, nullptr, "SetProcessRecordVolume"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};
class IAudioSnoopManager final : public ServiceFramework<IAudioSnoopManager> {
public:
explicit IAudioSnoopManager(Core::System& system_)
- : ServiceFramework{system_, "auddev"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "GetDspStatistics"},
- FunctionInfo{1, nullptr, "GetAppletStateSummaries"},
- FunctionInfo{2, nullptr, "SetDspStatisticsParameter"},
- FunctionInfo{3, nullptr, "GetDspStatisticsParameter"},
- FunctionInfo{6, nullptr, "GetDspUsage"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "auddev"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "GetDspStatistics"},
+ {1, nullptr, "GetAppletStateSummaries"},
+ {2, nullptr, "SetDspStatisticsParameter"},
+ {3, nullptr, "GetDspStatisticsParameter"},
+ {6, nullptr, "GetDspUsage"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};
class IAudioInManagerForApplet final : public ServiceFramework<IAudioInManagerForApplet> {
public:
explicit IAudioInManagerForApplet(Core::System& system_)
- : ServiceFramework{system_, "audin:a"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "RequestSuspend"},
- FunctionInfo{1, nullptr, "RequestResume"},
- FunctionInfo{2, nullptr, "GetProcessMasterVolume"},
- FunctionInfo{3, nullptr, "SetProcessMasterVolume"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "audin:a"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "RequestSuspend"},
+ {1, nullptr, "RequestResume"},
+ {2, nullptr, "GetProcessMasterVolume"},
+ {3, nullptr, "SetProcessMasterVolume"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};
class IAudioRendererManagerForApplet final : public ServiceFramework<IAudioRendererManagerForApplet> {
public:
explicit IAudioRendererManagerForApplet(Core::System& system_)
- : ServiceFramework{system_, "audren:a"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "RequestSuspend"},
- FunctionInfo{1, nullptr, "RequestResume"},
- FunctionInfo{2, nullptr, "GetProcessMasterVolume"},
- FunctionInfo{3, nullptr, "SetProcessMasterVolume"},
- FunctionInfo{4, nullptr, "RegisterAppletResourceUserId"},
- FunctionInfo{5, nullptr, "UnregisterAppletResourceUserId"},
- FunctionInfo{6, nullptr, "GetProcessRecordVolume"},
- FunctionInfo{7, nullptr, "SetProcessRecordVolume"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "audren:a"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "RequestSuspend"},
+ {1, nullptr, "RequestResume"},
+ {2, nullptr, "GetProcessMasterVolume"},
+ {3, nullptr, "SetProcessMasterVolume"},
+ {4, nullptr, "RegisterAppletResourceUserId"},
+ {5, nullptr, "UnregisterAppletResourceUserId"},
+ {6, nullptr, "GetProcessRecordVolume"},
+ {7, nullptr, "SetProcessRecordVolume"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};
class IAudioOutManagerForDebugger final : public ServiceFramework<IAudioOutManagerForDebugger> {
public:
explicit IAudioOutManagerForDebugger(Core::System& system_)
- : ServiceFramework{system_, "audout:d"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "RequestSuspend"},
- FunctionInfo{1, nullptr, "RequestResume"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "audout:d"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "RequestSuspend"},
+ {1, nullptr, "RequestResume"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};
class IAudioInManagerForDebugger final : public ServiceFramework<IAudioInManagerForDebugger> {
public:
explicit IAudioInManagerForDebugger(Core::System& system_)
- : ServiceFramework{system_, "audin:d"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "RequestSuspend"},
- FunctionInfo{1, nullptr, "RequestResume"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "audin:d"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "RequestSuspend"},
+ {1, nullptr, "RequestResume"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};
class IFinalOutputRecorderManagerForDebugger final : public ServiceFramework<IFinalOutputRecorderManagerForDebugger> {
public:
explicit IFinalOutputRecorderManagerForDebugger(Core::System& system_)
- : ServiceFramework{system_, "audrec:d"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "RequestSuspend"},
- FunctionInfo{1, nullptr, "RequestResume"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "audrec:d"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "RequestSuspend"},
+ {1, nullptr, "RequestResume"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};
class IAudioRendererManagerForDebugger final : public ServiceFramework<IAudioRendererManagerForDebugger> {
public:
explicit IAudioRendererManagerForDebugger(Core::System& system_)
- : ServiceFramework{system_, "audren:d"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "RequestSuspend"},
- FunctionInfo{1, nullptr, "RequestResume"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "audren:d"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "RequestSuspend"},
+ {1, nullptr, "RequestResume"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};
class IAudioSystemManagerForApplet final : public ServiceFramework<IAudioSystemManagerForApplet> {
public:
explicit IAudioSystemManagerForApplet(Core::System& system_)
- : ServiceFramework{system_, "aud:a"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "RegisterAppletResourceUserId"},
- FunctionInfo{1, nullptr, "UnregisterAppletResourceUserId"},
- FunctionInfo{2, nullptr, "RequestSuspendAudio"},
- FunctionInfo{3, nullptr, "RequestResumeAudio"},
- FunctionInfo{4, nullptr, "GetAudioOutputProcessMasterVolume"},
- FunctionInfo{5, nullptr, "SetAudioOutputProcessMasterVolume"},
- FunctionInfo{6, nullptr, "GetAudioInputProcessMasterVolume"},
- FunctionInfo{7, nullptr, "SetAudioInputProcessMasterVolume"},
- FunctionInfo{8, nullptr, "GetAudioOutputProcessRecordVolume"},
- FunctionInfo{9, nullptr, "SetAudioOutputProcessRecordVolume"},
- FunctionInfo{10, nullptr, "GetAppletStateSummaries"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "aud:a"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "RegisterAppletResourceUserId"},
+ {1, nullptr, "UnregisterAppletResourceUserId"},
+ {2, nullptr, "RequestSuspendAudio"},
+ {3, nullptr, "RequestResumeAudio"},
+ {4, nullptr, "GetAudioOutputProcessMasterVolume"},
+ {5, nullptr, "SetAudioOutputProcessMasterVolume"},
+ {6, nullptr, "GetAudioInputProcessMasterVolume"},
+ {7, nullptr, "SetAudioInputProcessMasterVolume"},
+ {8, nullptr, "GetAudioOutputProcessRecordVolume"},
+ {9, nullptr, "SetAudioOutputProcessRecordVolume"},
+ {10, nullptr, "GetAppletStateSummaries"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};
class IAudioSystemManagerForDebugger final : public ServiceFramework<IAudioSystemManagerForDebugger> {
public:
explicit IAudioSystemManagerForDebugger(Core::System& system_)
- : ServiceFramework{system_, "aud:d"} {}
-
- static constexpr auto functions = CreateStaticMap(
- FunctionInfo{0, nullptr, "RequestSuspendAudioForDebug"},
- FunctionInfo{1, nullptr, "RequestResumeAudioForDebug"}
- );
- std::optional<FunctionInfoBase> FindRequest(u32 key) override {
- return HandlerTableGenerateWithFind(key, functions);
+ : ServiceFramework{system_, "aud:d"} {
+ // clang-format off
+ static const FunctionInfo functions[] = {
+ {0, nullptr, "RequestSuspendAudioForDebug"},
+ {1, nullptr, "RequestResumeAudioForDebug"},
+ };
+ // clang-format on
+ RegisterHandlers(functions);
}
};