diff --git a/src/DotRecast.Recast.Demo/DemoLog.cs b/src/DotRecast.Recast.Demo/DemoLog.cs deleted file mode 100644 index 29c4b3a..0000000 --- a/src/DotRecast.Recast.Demo/DemoLog.cs +++ /dev/null @@ -1,27 +0,0 @@ -using System.Collections.Generic; -using System.Runtime.CompilerServices; -using Serilog; -using Silk.NET.OpenGL; - -namespace DotRecast.Recast.Demo; - -public static class DemoLog -{ - private static readonly ILogger Logger = Log.ForContext(typeof(DemoLog)); - private static HashSet messages = new(); - - public static void LogIfGlError(GL gl, [CallerMemberName] string method = "", [CallerFilePath] string file = "", [CallerLineNumber] int line = 0) - { - var err = gl.GetError(); - if (err == GLEnum.NoError) - return; - - var s = $"{method}() err({err}) in {file}:{line}"; - if (messages.Contains(s)) - return; - - messages.Add(s); - Logger.Error(s); - } - -} \ No newline at end of file