#pragma once

#include <SDL3/SDL.h>
#include <iostream>
#include <thread>
#include <utils.hpp>

namespace Game::Renderer {
    typedef struct {
        float camX;
        float camY;
        int screenW;
        int screenH;
    } RendererConfig;

    class Renderer {
        public:
            Renderer();
            DISABLE_COPY_AND_MOVE(Renderer);
            ~Renderer();

            bool init(SDL_Window* window);
            void renderFrame();
            void destroy();

            SDL_Renderer* getSDLRenderer() { return mRenderer; }

        private:
            void mClear();
            void mPresent();

            SDL_Renderer* mRenderer;
    };
}