Rename *_verbose
functions to idiomatic x*
This commit is contained in:
@@ -40,7 +40,7 @@ void parse_args(int argc, char *argv[], struct Options *options) {
|
||||
#define TILE_SIZE 16
|
||||
|
||||
void transpose_tiles(uint8_t *tiles, int width, int size) {
|
||||
uint8_t *new_tiles = malloc_verbose(size);
|
||||
uint8_t *new_tiles = xmalloc(size);
|
||||
for (int i = 0; i < size; i++) {
|
||||
int j = i / TILE_SIZE * width * TILE_SIZE;
|
||||
j = (j / size) * TILE_SIZE + j % size + i % TILE_SIZE;
|
||||
@@ -91,7 +91,7 @@ void write_graphics(const char *filename, const uint8_t *tiles, long tiles_size,
|
||||
// Ensure space for a duplicate of tile 0 at the end
|
||||
max_size += TILE_SIZE;
|
||||
}
|
||||
uint8_t *data = malloc_verbose(max_size);
|
||||
uint8_t *data = xmalloc(max_size);
|
||||
|
||||
int num_tiles = 0;
|
||||
#define DATA_APPEND_TILES(tile, length) do { \
|
||||
@@ -119,7 +119,7 @@ void write_graphics(const char *filename, const uint8_t *tiles, long tiles_size,
|
||||
|
||||
void write_tilemap(const char *filename, const uint8_t *tiles, long tiles_size, int num_tiles_per_frame, bool girafarig) {
|
||||
int size = tiles_size / TILE_SIZE;
|
||||
uint8_t *data = malloc_verbose(size);
|
||||
uint8_t *data = xmalloc(size);
|
||||
|
||||
int num_tiles = num_tiles_per_frame;
|
||||
// Copy the first frame directly
|
||||
|
Reference in New Issue
Block a user