Skip to content

Commit

Permalink
Small startup improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
Pyrdacor committed Dec 26, 2023
1 parent c3da870 commit 5d767bd
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Ambermoon.net/GameWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1296,6 +1296,12 @@ void Window_Load()
ChangeFullscreenMode(true); // This will adjust the window
}

var gl = Silk.NET.OpenGL.GL.GetApi(GLContext);
gl.Viewport(new System.Drawing.Size(window.FramebufferSize.X, window.FramebufferSize.Y));
gl.ClearColor(System.Drawing.Color.Black);
gl.Clear(Silk.NET.OpenGL.ClearBufferMask.ColorBufferBit);
GLContext.SwapBuffers();

if (configuration.Width == null || configuration.Height == null)
{
var monitorSize = window.Monitor.Bounds.Size;
Expand Down

0 comments on commit 5d767bd

Please sign in to comment.