Skip to content

Commit

Permalink
Add Canvas::renderContext
Browse files Browse the repository at this point in the history
  • Loading branch information
dancazarin committed Feb 17, 2025
1 parent 9a16ee8 commit 952d1eb
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions include/brisk/graphics/Canvas.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ class Canvas : protected RawCanvas {
*/
explicit Canvas(RenderContext& context);

using RawCanvas::renderContext;

/**
* @brief Constructs a Canvas object using an existing RawCanvas.
*
Expand Down
4 changes: 4 additions & 0 deletions include/brisk/graphics/RawCanvas.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,10 @@ class RawCanvas {
return m_state;
}

RenderContext& renderContext() {
return m_context;
}

protected:
friend class Canvas;
RenderContext& m_context;
Expand Down

0 comments on commit 952d1eb

Please sign in to comment.