summaryrefslogtreecommitdiff
path: root/drivers/png/png_driver_common.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/png/png_driver_common.cpp')
-rw-r--r--drivers/png/png_driver_common.cpp3
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/png/png_driver_common.cpp b/drivers/png/png_driver_common.cpp
index 3f9c824e93..68faff30fc 100644
--- a/drivers/png/png_driver_common.cpp
+++ b/drivers/png/png_driver_common.cpp
@@ -59,7 +59,6 @@ static bool check_error(const png_image &image) {
}
Error png_to_image(const uint8_t *p_source, size_t p_size, Ref<Image> p_image) {
-
png_image png_img;
zeromem(&png_img, sizeof(png_img));
png_img.version = PNG_IMAGE_VERSION;
@@ -121,7 +120,6 @@ Error png_to_image(const uint8_t *p_source, size_t p_size, Ref<Image> p_image) {
}
Error image_to_png(const Ref<Image> &p_image, Vector<uint8_t> &p_buffer) {
-
Ref<Image> source_image = p_image->duplicate();
if (source_image->is_compressed())
@@ -179,7 +177,6 @@ Error image_to_png(const Ref<Image> &p_image, Vector<uint8_t> &p_buffer) {
ERR_FAIL_COND_V_MSG(check_error(png_img), FAILED, png_img.message);
}
if (!success) {
-
// buffer was big enough, must be some other error
ERR_FAIL_COND_V(compressed_size <= png_size_estimate, FAILED);