3#ifndef RENDERING_UTILS_H
4#define RENDERING_UTILS_H
struct anchore_point anchore_point
void render_full_anchored_image_file(const char *file, SDL_Renderer *renderer, SDL_Window *window, anchore_point anchore)
Renders an image file to the renderer using an anchore_point for positioning.
Definition RenderingUtils.c:49
SDL_Rect anchore_to_rect(SDL_Window *window, anchore_point anchore)
Converts an anchore_point to an SDL_Rect based on the window size.
Definition RenderingUtils.c:4
SDL_Rect get_surface_full_rect(SDL_Surface *surface)
Gets the full rectangle of an SDL_Surface.
Definition RenderingUtils.c:190
anchore_point rect_to_anchore(SDL_Rect rect)
Converts an SDL_Rect to an anchore_point.
Definition RenderingUtils.c:103
SDL_Rect to_positive_rect(SDL_Rect rect)
Converts an SDL_Rect to a positive SDL_Rect.
Definition RenderingUtils.c:131
anchore_point pixel_to_pourcent_anchore(SDL_Window *window, anchore_point anch)
Converts pixel-based anchore_point offsets to percentage-based offsets.
Definition RenderingUtils.c:158
Definition RenderingUtils.h:7
int down_offset
Definition RenderingUtils.h:15
double min_x
Definition RenderingUtils.h:8
double max_y
Definition RenderingUtils.h:11
int right_offset
Definition RenderingUtils.h:13
int up_offset
Definition RenderingUtils.h:14
int left_offset
Definition RenderingUtils.h:12
double min_y
Definition RenderingUtils.h:10
double aspect_ratio
Definition RenderingUtils.h:16
double max_x
Definition RenderingUtils.h:9