renderiranje - nazaj na singlethreaded ker me SDL ne mara :(
This commit is contained in:
@@ -13,7 +13,7 @@ namespace Game::Renderer {
|
||||
~Renderer();
|
||||
|
||||
bool init(SDL_Window* window);
|
||||
void run(std::stop_token stoken);
|
||||
void renderFrame();
|
||||
void destroy();
|
||||
|
||||
SDL_Renderer* getSDLRenderer() { return mRenderer; }
|
||||
|
||||
@@ -4,16 +4,18 @@
|
||||
#include <SDL3_image/SDL_image.h>
|
||||
#include <string>
|
||||
#include <utils.hpp>
|
||||
#include <renderer/renderer.hpp>
|
||||
|
||||
namespace Game::Renderer {
|
||||
class Texture {
|
||||
public:
|
||||
Texture(std::string& path, Renderer* renderer, std::string id = "noname");
|
||||
Texture(const std::string& path, SDL_Renderer* renderer, std::string id = "noname");
|
||||
Texture(const Texture&);
|
||||
Texture& operator=(const Texture&);
|
||||
DISABLE_MOVE(Texture);
|
||||
~Texture();
|
||||
|
||||
SDL_Texture* getSDLTexture();
|
||||
std::string getId();
|
||||
private:
|
||||
SDL_Texture* mTex;
|
||||
std::string mId;
|
||||
|
||||
Reference in New Issue
Block a user