aboutsummaryrefslogtreecommitdiff
path: root/include/ubox.h
diff options
context:
space:
mode:
authorJuan J. Martinez <jjm@usebox.net>2023-05-06 22:00:16 +0100
committerJuan J. Martinez <jjm@usebox.net>2023-05-06 22:00:16 +0100
commitc9f28c1ce3ffda9c407003a26adf903d810b681b (patch)
tree0387d4fa236b37519f33295352aceb1babb98700 /include/ubox.h
parent3a8be8c9949ac8c37822bed7cf407b46df6dbd0b (diff)
downloadubox-msx-lib-c9f28c1ce3ffda9c407003a26adf903d810b681b.tar.gz
ubox-msx-lib-c9f28c1ce3ffda9c407003a26adf903d810b681b.zip
Set tighter qualifiers for pointer parameters
This should prevent warnings when using source data from ROM.
Diffstat (limited to 'include/ubox.h')
-rw-r--r--include/ubox.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/include/ubox.h b/include/ubox.h
index b66c76e..842f2f4 100644
--- a/include/ubox.h
+++ b/include/ubox.h
@@ -193,7 +193,7 @@ uint8_t ubox_get_vsync_freq();
* All the tiles functions use an index in this tile set (usually via a `tile`
* parameter).
*/
-void ubox_set_tiles(uint8_t *tiles) __z88dk_fastcall;
+void ubox_set_tiles(const uint8_t *tiles) __z88dk_fastcall;
/**
* Sets the current color table for current tile set to the color table pointed
@@ -203,7 +203,7 @@ void ubox_set_tiles(uint8_t *tiles) __z88dk_fastcall;
* of the tiles table (8 rows, 8 bytes per tile). The colors will be loaded into
* the VDP in all three screen sections.
*/
-void ubox_set_tiles_colors(uint8_t *colors) __z88dk_fastcall;
+void ubox_set_tiles_colors(const uint8_t *colors) __z88dk_fastcall;
/**
* Puts a tile from current tile set on the screen. The tile is identified by
@@ -409,7 +409,7 @@ struct sprite_attr {
*
* See [ubox_set_sprite_pat16](#ubox_set_sprite_pat16) to set a 16x16 pixels pattern.
*/
-void ubox_set_sprite_pat8(uint8_t *data, uint8_t pattern);
+void ubox_set_sprite_pat8(const uint8_t *data, uint8_t pattern);
/**
* Sets the sprite pattern data pointed by `data` into pattern number
@@ -422,7 +422,7 @@ void ubox_set_sprite_pat8(uint8_t *data, uint8_t pattern);
* See [ubox_set_sprite_pat16_flip](#ubox_set_sprite_pat16_flip) to set a 16x16
* pixels pattern.
*/
-void ubox_set_sprite_pat8_flip(uint8_t *data, uint8_t pattern);
+void ubox_set_sprite_pat8_flip(const uint8_t *data, uint8_t pattern);
/**
* Sets the sprite attributes of sprite number `sprite` using the attributes
@@ -442,7 +442,7 @@ void ubox_set_sprite_pat8_flip(uint8_t *data, uint8_t pattern);
* table, it is recommended to use [ubox_write_vm](#ubox_write_vm). The sprite
* attribute table is in the memory address `0x1b00`.
*/
-void ubox_set_sprite_attr(struct sprite_attr *attr, uint8_t sprite);
+void ubox_set_sprite_attr(const struct sprite_attr *attr, uint8_t sprite);
/**
* Sets the sprite pattern data pointed by `data` into pattern number
@@ -455,7 +455,7 @@ void ubox_set_sprite_attr(struct sprite_attr *attr, uint8_t sprite);
*
* See [ubox_set_sprite_pat8](#ubox_set_sprite_pat8) to set a 8x8 pixels pattern.
*/
-void ubox_set_sprite_pat16(uint8_t *data, uint8_t pattern);
+void ubox_set_sprite_pat16(const uint8_t *data, uint8_t pattern);
/**
* Sets the sprite pattern data pointed by `data` into pattern number
@@ -469,7 +469,7 @@ void ubox_set_sprite_pat16(uint8_t *data, uint8_t pattern);
* See [ubox_set_sprite_pat8_flip](#ubox_set_sprite_pat8_flip) to set a 8x8
* pixels pattern.
*/
-void ubox_set_sprite_pat16_flip(uint8_t *data, uint8_t pattern);
+void ubox_set_sprite_pat16_flip(const uint8_t *data, uint8_t pattern);
// @Control functions
//