1
0
Fork 0
mirror of https://github.com/Ryujinx/Ryujinx.git synced 2024-12-01 03:42:02 +00:00
Ryujinx/Ryujinx.HLE/HOS/Services/Apm/ISession.cs

41 lines
1.2 KiB
C#
Raw Normal View History

using Ryujinx.Common.Logging;
using Ryujinx.HLE.HOS.Ipc;
using System.Collections.Generic;
namespace Ryujinx.HLE.HOS.Services.Apm
{
class ISession : IpcService
{
2018-12-01 20:01:59 +00:00
private Dictionary<int, ServiceProcessRequest> _commands;
2018-12-01 20:01:59 +00:00
public override IReadOnlyDictionary<int, ServiceProcessRequest> Commands => _commands;
public ISession()
{
2018-12-01 20:01:59 +00:00
_commands = new Dictionary<int, ServiceProcessRequest>()
{
{ 0, SetPerformanceConfiguration },
{ 1, GetPerformanceConfiguration }
};
}
2018-12-01 20:01:59 +00:00
public long SetPerformanceConfiguration(ServiceCtx context)
{
2018-12-01 20:01:59 +00:00
PerformanceMode perfMode = (PerformanceMode)context.RequestData.ReadInt32();
PerformanceConfiguration perfConfig = (PerformanceConfiguration)context.RequestData.ReadInt32();
return 0;
}
2018-12-01 20:01:59 +00:00
public long GetPerformanceConfiguration(ServiceCtx context)
{
2018-12-01 20:01:59 +00:00
PerformanceMode perfMode = (PerformanceMode)context.RequestData.ReadInt32();
2018-12-01 20:01:59 +00:00
context.ResponseData.Write((uint)PerformanceConfiguration.PerformanceConfiguration1);
Logger.PrintStub(LogClass.ServiceApm, "Stubbed.");
return 0;
}
}
}