From 22252f9161d5adf6c9c1378a394671b08c18398f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20L=C3=BCbe=C3=9F?= Date: Wed, 25 Aug 2021 22:46:50 +0200 Subject: [PATCH] Application now has EffectLibrary field --- GlitchyEngine/src/Application.bf | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/GlitchyEngine/src/Application.bf b/GlitchyEngine/src/Application.bf index 46ed08b..239670c 100644 --- a/GlitchyEngine/src/Application.bf +++ b/GlitchyEngine/src/Application.bf @@ -11,6 +11,8 @@ namespace GlitchyEngine private Window _window ~ delete _; private RendererAPI _rendererApi ~ delete _; + private EffectLibrary _effectLibrary ~ delete _; + private bool _running = true; private LayerStack _layerStack = new LayerStack() ~ delete _; @@ -22,6 +24,8 @@ namespace GlitchyEngine public bool IsRunning => _running; public Window Window => _window; + public EffectLibrary EffectLibrary => _effectLibrary; + [Inline] public static Application Get() => s_Instance; @@ -39,8 +43,10 @@ namespace GlitchyEngine SamplerStateManager.Init(_window.Context); RenderCommand.RendererAPI = _rendererApi; - - Renderer.Init(_window.Context); + + _effectLibrary = new EffectLibrary(_window.Context); + + Renderer.Init(_window.Context, _effectLibrary); _imGuiLayer = new ImGuiLayer(); PushOverlay(_imGuiLayer);