24 lines
498 B
C
24 lines
498 B
C
//
|
|
// Created by bruno on 1.6.2025.
|
|
//
|
|
|
|
#ifndef FACTORYGAME_ATLAS_H
|
|
#define FACTORYGAME_ATLAS_H
|
|
|
|
#define ATLAS_SIZE 512
|
|
#define TILE_SIZE 32
|
|
#define QUADRANT_SIZE 16
|
|
#define ATLAS_TILES_PER_ROW (ATLAS_SIZE / TILE_SIZE)
|
|
|
|
#include "SDL2/SDL.h"
|
|
|
|
extern SDL_Texture *atlasTexture;
|
|
|
|
SDL_Rect allocate_32x32(SDL_Texture *srcTexture, SDL_Renderer *renderer);
|
|
|
|
SDL_Rect allocate_16x16(SDL_Texture *srcTexture, SDL_Renderer *renderer);
|
|
|
|
void initAtlas(SDL_Renderer *renderer);
|
|
|
|
#endif //FACTORYGAME_ATLAS_H
|