Commit graph

9 commits

Author SHA1 Message Date
Light
271f3b2075 Framebuffer
- Added 'Framebuffer'
- Added an optional 'FrameBuffer' parameter to'Renderer::BeginScene'
- Added 'RenderCommand::DefaultTargetFramebuffer()'
- Added static 'GraphicsContext::GetSharedContext()'

- Fixed 'dxBlender' by changing 'DestBlendAlpha' from D3D11_BLEND_ZERO
       to D3D11_BLEND_ONE
- Fixed 'glRenderCommand::ClearBackBuffer()' by calling glClear before
      glClearColor

- 'Application::GameLoop' now updates the ui ._.
2021-07-15 15:46:28 +04:30
Light
57616d755c WindowResizeEvent | FlushScene
- 'Renderer' now receives 'WindowResizedEvent' and handle the
      'Framebuffer' and viewport stuff
- Added 'Renderer' now uses the new 'FlushScene' function to flush when
      the mapped vertex buffer is filled
- The viewport is now set by 'RenderCommand' via the 'Renderer' rather
      than the 'GraphicsConntext'

- 'Window' no longer sends 'WindowResizedEvent' to 'GraphicsContext'
- 'GraphicsContext' no longer receives 'OnWindowResize' events

- Note: Sending events should be done by the 'Application'
2021-07-14 00:17:30 +04:30
Light
2ab97d3863 Major Maintenance
- Major tidying
- Moved 'RendererProgram' classes out of the 'Renderer' class
- Moved 'RenderCommand' member variable out of 'GraphicsContext' and into
       the 'Renderer' class as a unique_ptr. results in 'Renderer' taking a
       windowHandle for construction
- Defined new macros for max quads in 'Renderer.h'
- Added the 'Stringifier' to 'Base.h'
- Added the 'ResourceManager' to the 'LightEngine.h'
- Application now logs the current file directory
- Fixed the forward declaration in GraphicsContext
- Fixed the debug break in Base.h
- Fixed 'dxShader' not logging compile errors
- 'glVertexLayout' now takes in a shared_ptr for 'VertexBuffer'
- 'glShader' now logs the shader compilation errors properly
- 'dxVertexLayout' now takes in a shared_ptr for 'Shader"
- Modified 'dxSharedContext' members to be private and made getters for them
- 'dxRenderCommand::SwapBuffers' now throws dxException for
       DXGI_ERROR_DEVICE_REMOD error
2021-07-01 19:25:46 +04:30
Light
f8b35c9572 Maintanance
- Some tidying
- dxGraphicsContext's constructor been split up into multiple Setup functions.
2021-06-21 18:08:25 +04:30
Light
0fc1896854 Handle DEVICE_REMOVED
- Added DXGI_ERROR_DEVICE_REMOVED handling in dxRenderCommand::SwapBuffers
2021-06-21 17:04:51 +04:30
Light
fcfe73923d Major changes
- Major tidying
- Some fixes
-
2021-06-19 15:12:42 +04:30
Light
bb604e9540 Major changes 2021-06-15 09:39:11 +04:30
Light3039
2f560239cb DirectX 2021-06-02 17:20:15 +04:30
Light3039
ce1aa29e0e DirectX Context 2021-06-02 09:07:45 +04:30