Starting refactor now.

This commit is contained in:
2023-11-01 22:03:16 -05:00
parent c5cfc31436
commit d530210bed
18 changed files with 133 additions and 229 deletions

View File

@ -73,7 +73,7 @@ void Texture::setSize(
}
void Texture::fill(struct Color color) {
struct Color *pixels = (struct Color *)memoryAllocate(
auto pixels = memoryAllocate<struct Color>(
sizeof(struct Color) * this->width * this->height
);
this->buffer(pixels);
@ -81,7 +81,7 @@ void Texture::fill(struct Color color) {
}
void Texture::fill(uint8_t color) {
uint8_t *pixels = (uint8_t *)memoryAllocate(
auto pixels = memoryAllocate<uint8_t>(
sizeof(uint8_t) * this->width * this->height
);
this->buffer(pixels);