1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-13 19:40:20 +03:00

free image buffer after dump

This commit is contained in:
Raphael Coeffic 2021-04-13 12:53:03 +02:00
parent ddaeff7f65
commit c61e85d212

View file

@ -52,6 +52,7 @@ void dumpImage(const std::string& filename, const BitmapBuffer* dc)
uint8_t * img = (uint8_t *)malloc(pixels * 3);
convert_RGB565_to_RGB888(img, dc->getPixelPtr(0,0), pixels);
stbi_write_png(fullpath.c_str(), dc->width(), dc->height(), 3, img, stride);
free(img);
}
bool checkScreenshot_colorlcd(const BitmapBuffer* dc, const char* test)