renderpip/include/components/render.hpp

33 lines
476 B
C++
Raw Permalink Normal View History

2026-04-02 03:41:50 -04:00
/**
* @file render.hpp
* @brief Rendering-related components
*/
#pragma once
#include <SDL3/SDL.h>
#include <cstdint>
struct Color {
uint8_t r = 255;
uint8_t g = 255;
uint8_t b = 255;
uint8_t a = 255;
};
struct Sprite {
SDL_Texture* texture = nullptr;
SDL_FRect src_rect{};
int z_order = 0;
bool visible = true;
};
struct RectShape {
float width = 0.0f;
float height = 0.0f;
};
struct CircleShape {
float radius = 0.0f;
};