diff src/sprite.c @ 46:b815621df3e3

core: remove all fixed width integers, closes #2460
author David Demelier <markand@malikania.fr>
date Wed, 15 Jan 2020 22:31:17 +0100
parents 607bd90aba63
children
line wrap: on
line diff
--- a/src/sprite.c	Wed Jan 15 22:31:17 2020 +0100
+++ b/src/sprite.c	Wed Jan 15 22:31:17 2020 +0100
@@ -23,7 +23,10 @@
 #include "texture.h"
 
 void
-sprite_init(struct sprite *sprite, struct texture *tex, uint8_t cellw, uint8_t cellh)
+sprite_init(struct sprite *sprite,
+            struct texture *tex,
+            unsigned int cellw,
+            unsigned int cellh)
 {
 	int w = 0;
 	int h = 0;
@@ -31,6 +34,7 @@
 	assert(sprite);
 	assert(tex);
 
+	/* TODO: use texture_get_size */
 	SDL_QueryTexture(tex->handle, NULL, NULL, &w, &h);
 
 	sprite->texture = tex;
@@ -41,7 +45,7 @@
 }
 
 void
-sprite_draw(struct sprite *sprite, uint16_t r, uint16_t c, int x, int y)
+sprite_draw(struct sprite *sprite, unsigned int r, unsigned int c, int x, int y)
 {
 	assert(sprite);