From a644055a4d8fd84bf8cafb562f5cf0de4da974ee Mon Sep 17 00:00:00 2001 From: Ac_K Date: Thu, 20 May 2021 01:17:14 +0200 Subject: [PATCH] Call it in static constructor --- Ryujinx.Graphics.Nvdec.H264/FFmpegContext.cs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Ryujinx.Graphics.Nvdec.H264/FFmpegContext.cs b/Ryujinx.Graphics.Nvdec.H264/FFmpegContext.cs index 31f37ca00..17de1a03a 100644 --- a/Ryujinx.Graphics.Nvdec.H264/FFmpegContext.cs +++ b/Ryujinx.Graphics.Nvdec.H264/FFmpegContext.cs @@ -16,8 +16,6 @@ namespace Ryujinx.Graphics.Nvdec.H264 public FFmpegContext() { - SetRootPath(); - _logFunc = Log; // Redirect log output @@ -32,7 +30,12 @@ namespace Ryujinx.Graphics.Nvdec.H264 _packet = ffmpeg.av_packet_alloc(); } - private void SetRootPath() + static FFmpegContext() + { + SetRootPath(); + } + + private static void SetRootPath() { if (OperatingSystem.IsLinux()) {