forked from MeloNX/MeloNX
add option to enable debug logs
This commit is contained in:
parent
f4d7678ae4
commit
f1c523ca69
@ -40,13 +40,13 @@ namespace LibRyujinx
|
||||
}
|
||||
|
||||
[UnmanagedCallersOnly(EntryPoint = "Java_org_ryujinx_android_RyujinxNative_initialize")]
|
||||
public static JBoolean JniInitialize(JEnvRef jEnv, JObjectLocalRef jObj, JStringLocalRef jpath)
|
||||
public static JBoolean JniInitialize(JEnvRef jEnv, JObjectLocalRef jObj, JStringLocalRef jpath, JBoolean enableDebugLogs)
|
||||
{
|
||||
var path = GetString(jEnv, jpath);
|
||||
|
||||
Ryujinx.Common.SystemInfo.SystemInfo.IsBionic = true;
|
||||
|
||||
var init = Initialize(path);
|
||||
var init = Initialize(path, enableDebugLogs);
|
||||
|
||||
AudioDriver = new OboeHardwareDeviceDriver();
|
||||
|
||||
@ -376,7 +376,7 @@ namespace LibRyujinx
|
||||
{
|
||||
var safeHandle = new SafeFileHandle(descriptor, false);
|
||||
|
||||
return new FileStream(safeHandle, FileAccess.Read);
|
||||
return new FileStream(safeHandle, FileAccess.ReadWrite);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -57,7 +57,7 @@ namespace LibRyujinx
|
||||
return res;
|
||||
}
|
||||
|
||||
public static bool Initialize(string? basePath)
|
||||
public static bool Initialize(string? basePath, bool enableDebugLogs = false)
|
||||
{
|
||||
if (SwitchDevice != null)
|
||||
{
|
||||
@ -73,7 +73,7 @@ namespace LibRyujinx
|
||||
|
||||
SwitchDevice = new SwitchDevice();
|
||||
|
||||
Logger.SetEnable(LogLevel.Debug, false);
|
||||
Logger.SetEnable(LogLevel.Debug, enableDebugLogs);
|
||||
Logger.SetEnable(LogLevel.Stub, false);
|
||||
Logger.SetEnable(LogLevel.Info, true);
|
||||
Logger.SetEnable(LogLevel.Warning, true);
|
||||
|
Loading…
x
Reference in New Issue
Block a user