Page 1 of 1

libpng mismatch

PostPosted: Sat Jan 07, 2012 08:31
by benajamin
When I start the game I get a whole bunch of errors like:
Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
LOAD PNG: Internal PNG create read struct failure
: /home/watts/minetest/celeron55-minetest-569156b/data/clienttextures/menubg.png
Could not load texture: /home/watts/minetest/celeron55-minetest-569156b/bin/../data/clienttextures/menubg.png
libpng warning: Application built with libpng-1.4.5 but running with 1.5.6
LOAD PNG: Internal PNG create read struct failure
: /home/watts/minetest/celeron55-minetest-569156b/data/clienttextures/menulogo.png
libpng warning: Application built with libpng-1.4.5 but running with 1.5.6
LOAD PNG: Internal PNG create read struct failure
: /home/watts/minetest/celeron55-minetest-569156b/data/clienttextures/menulogo.png
Could not load texture: /home/watts/minetest/celeron55-minetest-569156b/bin/../data/clienttextures/menulogo.png
libpng warning: Application built with libpng-1.4.5 but running with 1.5.6
LOAD PNG: Internal PNG create read struct failure
: /home/watts/minetest/celeron55-minetest-569156b/data/clienttextures/menubg.png
libpng warning: Application built with libpng-1.4.5 but running with 1.5.6


And then when I start playing, I don't get any textures (all blocks are weird plain colours). The libpng website says:
Portability Note

The libpng 1.5.x series continues the evolution of the libpng API, finally hiding the contents of the venerable and hoary png_struct and png_info data structures inside private (i.e., non-installed) header files. Instead of direct struct-access, applications should be using the various png_get_xxx() and png_set_xxx() accessor functions, which have existed for almost as long as libpng itself. (Apps that compiled against libpng 1.4 without warnings about deprecated features should happily compile against 1.5, too.)


This might be describing the issue.

PostPosted: Sat Jan 07, 2012 10:16
by celeron55
This is probably due to your Minetest and Irrlicht builds using different libpng versions or something similar.

So, either downgrade your system's libpng or upgrade your system's irrlicht. Somehow.

PostPosted: Sat Jan 07, 2012 11:39
by benajamin
I'm running Gentoo Linux and I had done a big update this week, so that might be how I had compiled the two with different versions of libpng. I recompiled both irrlicht and minetest and now the textures work properly. I guess my mistake was assuming that irrlicht had been recompiled after the libpng upgrade. Thanks for your help!

BTW, I really like what you're doing with minetest and look forward to seeing how it will develop further. Congratulations of some great work!