Trying to implement image mapping.

Something not working yet.
This commit is contained in:
Godzil
2020-03-05 09:48:37 +00:00
parent d6ae062f7f
commit 6a2c5a77ae
5 changed files with 132 additions and 0 deletions

View File

@@ -68,3 +68,10 @@ bool Canvas::SaveAsPNG(const char *filename)
return ret == 0;
}
Canvas::Canvas(const char *pngfile)
{
uint32_t ret = lodepng_decode24_file(&this->bitmap, &this->width, &this->height, pngfile);
if(ret){ printf("error %u: %s\n", ret, lodepng_error_text(ret));}
printf("%p - %d - %d\n", this->bitmap, this->width, this->height);
}