Fixed screen matrix

This commit is contained in:
Maddy Thorson 2021-02-20 21:04:51 -08:00
parent bc2dfc73ce
commit 9a0303781f
2 changed files with 7 additions and 7 deletions

View File

@ -16,6 +16,8 @@ namespace Strawberry
ScreenWidth = screenWidth; ScreenWidth = screenWidth;
ScreenHeight = screenHeight; ScreenHeight = screenHeight;
WindowScale = windowScale; WindowScale = windowScale;
UpdateScreenMatrix();
} }
public void UpdateScreenMatrix() public void UpdateScreenMatrix()

View File

@ -146,16 +146,14 @@ namespace Strawberry.SDL2
delete gamepads; delete gamepads;
delete shader; delete shader;
ImGui.ImGuiImplOpenGL3.Shutdown();
ImGui.ImGuiImplSDL2.Shutdown();
ImGui.ImGui.DestroyContext();
GL.glDeleteProgram(glProgram); GL.glDeleteProgram(glProgram);
SDL.GL_DeleteContext(glContext); SDL.GL_DeleteContext(glContext);
SDL.DestroyWindow(window); SDL.DestroyWindow(window);
SDL.Quit(); SDL.Quit();
#if EDITOR
ImGui.ImGuiImplOpenGL3.Shutdown();
ImGui.ImGuiImplSDL2.Shutdown();
ImGui.ImGui.DestroyContext();
#endif
} }
static void* SdlGetProcAddress(StringView string) static void* SdlGetProcAddress(StringView string)
@ -194,8 +192,8 @@ namespace Strawberry.SDL2
public override void GameRenderEnd() public override void GameRenderEnd()
{ {
GL.glFlush();
GL.glUseProgram(0); GL.glUseProgram(0);
GL.glFlush();
} }
public override void RenderEnd() public override void RenderEnd()