5#include <skia/include/core/SkCanvas.h>
6#include <skia/include/core/SkColorSpace.h>
7#include <skia/include/core/SkPaint.h>
8#include <skia/include/core/SkSurface.h>
9#include <skia/include/gpu/ganesh/GrBackendSurface.h>
10#include <skia/include/gpu/ganesh/GrDirectContext.h>
11#include <skia/include/gpu/ganesh/SkSurfaceGanesh.h>
12#include <skia/include/gpu/ganesh/gl/GrGLBackendSurface.h>
13#include <skia/include/gpu/ganesh/gl/GrGLDirectContext.h>
14#include <skia/include/gpu/ganesh/gl/GrGLInterface.h>
62 std::shared_ptr<business_logic::BlocksManager>
blocksManager);
97 const std::vector<components::UITextsRow>& rows)
override;
constexpr float CENTERED_TEXT_ROWS_MARGIN_HORIZONTAL_NORM_PERCENT
constexpr float CENTERED_TEXT_ROWS_MARGIN_VERTICAL_NORM_PERCENT
Class that provides a logger for the given class; automatically deduces the logger.
std::shared_ptr< spdlog::logger > logger
Class responsible for rendering the GUI using Skia and GLFW.
void render()
Renders the current frame.
SkiaRendererImpl(SkiaRendererImpl &&)=delete
void handleWindowResized(gui::window::WindowBase< SkCanvas > *window, float xScale, float yScale)
Handles window resize events.
SkiaRendererImpl(const SkiaRendererImpl &)=delete
std::shared_ptr< business_logic::BlocksManager > blocksManager
The blocks manager.
void reinitializeSurface()
Reinitializes the Skia surface using the current width and height.
SkiaRendererImpl & operator=(const SkiaRendererImpl &)=delete
void renderCenteredTextsRows(SkCanvas *canvas, const business_logic::geometry::Size2D &size, const std::vector< components::UITextsRow > &rows) override
Renders the texts on the canvas around the center horizontally, centered vertically.
sk_sp< GrDirectContext > grContext
The Skia context.
gui::window::WindowBase< SkCanvas > * window
The window.
~SkiaRendererImpl() override
Destructor.
SkiaRendererImpl & operator=(SkiaRendererImpl &&)=delete
sk_sp< SkSurface > skSurface
The Skia surface.
gui::renderer::delegate::UIRendererDelegate< SkCanvas > * uiRendererDelegatePtr
The UI renderer delegate.
The delegate for the UI renderer.
The abstract base class for implementing a window.
UI primitives and components to be rendered as part of the UI.
Color constants used for rendering entities.
The GUI renderer and renderer-supporting implementation module.
A basic struct representing a 2D size.