aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/facade/SDLContext.h
diff options
context:
space:
mode:
authorheavydemon21 <nielsstunnebrink1@gmail.com>2024-11-20 14:06:54 +0100
committerheavydemon21 <nielsstunnebrink1@gmail.com>2024-11-20 14:06:54 +0100
commit3344e0df01435be903e38ccbd3b9cee608d574e7 (patch)
tree949a3a2d28ce143621f9da90aaea5361d95f9074 /src/crepe/facade/SDLContext.h
parent158022890cb9abd308a6a445588cc2fca8d84e67 (diff)
implemented feedback
Diffstat (limited to 'src/crepe/facade/SDLContext.h')
-rw-r--r--src/crepe/facade/SDLContext.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/crepe/facade/SDLContext.h b/src/crepe/facade/SDLContext.h
index 287ad5d..718c40f 100644
--- a/src/crepe/facade/SDLContext.h
+++ b/src/crepe/facade/SDLContext.h
@@ -124,9 +124,10 @@ private:
* \param transform Reference to the Transform for positioning.
* \param camera Reference to the Camera for view adjustments.
*/
- void draw(const Sprite & sprite, const Transform & transform, const Camera & camera);
+ void draw(const Sprite & sprite, const Transform & transform, const Camera & camera) const;
- void draw_particle(const Sprite & sprite, const Vector2 & pos, const double & angle, const double & scale, const Camera & camera);
+ void draw_particle(const Sprite & sprite, const Vector2 & pos, const double & angle,
+ const double & scale, const Camera & camera) const;
//! Clears the screen, preparing for a new frame.
void clear_screen();
@@ -147,7 +148,7 @@ private:
* \param sprite Reference to the sprite to calculate the rectangle
* \return sdl rectangle to draw a src image
*/
- SDL_Rect get_src_rect(const Sprite & sprite);
+ SDL_Rect get_src_rect(const Sprite & sprite) const;
/**
* \brief calculates the sqaure size of the image for an destination
*
@@ -158,7 +159,8 @@ private:
* on the camera
* \return sdl rectangle to draw a dst image to draw on the screen
*/
- SDL_Rect get_dst_rect(const Sprite & sprite, const Vector2 & pos, const double & scale, const Camera & cam);
+ SDL_Rect get_dst_rect(const Sprite & sprite, const Vector2 & pos, const double & scale,
+ const Camera & cam) const;
private:
//! sdl Window