summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenton Woods <denton.woods@gmail.com>2015-03-01 05:06:48 -0600
committerDenton Woods <denton.woods@gmail.com>2015-03-01 05:06:48 -0600
commit0bba767db1ebfd810e76ab9e21b1af50a4646657 (patch)
tree7701318765a25c7e2953ec7ec036794d7700e67b
parent1f0d82bd29356e8e88ec162e4b6d4d7df30e70a3 (diff)
parent724194d7a9a91221a564579f64bdd6f0abd64219 (diff)
downloaddevil-0bba767db1ebfd810e76ab9e21b1af50a4646657.tar.gz
Merge pull request #17 from max96at/master
Fixed deprecated libpng API usage.
-rw-r--r--DevIL/src-IL/src/il_icon.c2
-rw-r--r--DevIL/src-IL/src/il_png.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/DevIL/src-IL/src/il_icon.c b/DevIL/src-IL/src/il_icon.c
index 2ccb1a30..fd9475dc 100644
--- a/DevIL/src-IL/src/il_icon.c
+++ b/DevIL/src-IL/src/il_icon.c
@@ -525,7 +525,7 @@ ILboolean ico_readpng_get_image(ICOIMAGE *Icon, ILdouble display_exponent)
// Expand low-bit-depth grayscale images to 8 bits
if (ico_color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8) {
- png_set_gray_1_2_4_to_8(ico_png_ptr);
+ png_set_expand_gray_1_2_4_to_8(ico_png_ptr);
}
// Expand RGB images with transparency to full alpha channels
diff --git a/DevIL/src-IL/src/il_png.c b/DevIL/src-IL/src/il_png.c
index da9517d5..28665082 100644
--- a/DevIL/src-IL/src/il_png.c
+++ b/DevIL/src-IL/src/il_png.c
@@ -104,7 +104,7 @@ ILboolean iIsValidPng()
Read = iread(Signature, 1, 8);
iseek(-Read, IL_SEEK_CUR);
- return png_check_sig(Signature, 8);
+ return png_sig_cmp(Signature, 0, 8);
}
@@ -277,7 +277,7 @@ ILboolean readpng_get_image(ILdouble display_exponent)
// Expand low-bit-depth grayscale images to 8 bits
if (png_color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8) {
- png_set_gray_1_2_4_to_8(png_ptr);
+ png_set_expand_gray_1_2_4_to_8(png_ptr);
}
// Expand RGB images with transparency to full alpha channels