主页:http://openil.sourceforge.net/about.php
(从官网上看,这个库好像年份久远啊,2009?)
编译好的库文件Developer's Image Library (DevIL) is a programmer's library to develop applications with very powerful image loading capabilities
DevIL can load, save, convert, manipulate, filter and display a wide variety of image formats.
Currently, DevIL can load .bmp, .cut, .dds, .doom, .exr, .hdr, .gif, .ico, .jp2, .jpg,.lbm, .mdl, .mng, .pal, .pbm, .pcd, .pcx, .pgm, .pic, .png, .ppm, .psd, .psp, .raw, .sgi, .tga and .tif files.
Formats supported for saving include .bmp, .dds, .h, .jpg, .pal, .pbm, .pcx, .pgm, .png, .ppm, .raw, .sgi, .tga and .tif.
DevIL 1.7.8 SDK for 32-bit Windows(1.48 MB)
DevIL 1.7.8 SDK for 64-bit Windows(1.63 MB)
源码和示例代码下载 https://github.com/DentonW/DevIL
从源码中编译(环境 - Win7 64bit MinGW gcc 6.1)
DevIL-master\DevIL>cmake -G "MinGW Makefiles" . -- Could NOT find Jasper (missing: JASPER_LIBRARIES JASPER_INCLUDE_DIR) -- Could NOT find Squish (missing: SQUISH_INSTALL_DIR SQUISH_CLIENT_EXECUTABLE SQUISH_SERVER_EXECUTABLE) -- Could NOT find LCMS (missing: LCMS_LIBRARIES LCMS_INCLUDE_DIR)
编译 IL、ILU 无误; 但 ILUT 编译失败,主要是以下几类问题:DevIL-master\DevIL>make
解决方法:CMakeFiles\ILUT.dir/objects.a(ilut_opengl.c.obj):ilut_opengl.c:(.text+0x17): und efined reference to `__imp_glEnable' CMakeFiles\ILUT.dir/objects.a(ilut_opengl.c.obj):ilut_opengl.c:(.text+0x8a5): un defined reference to `gluBuild2DMipmaps'
进入 \DevIL-master\DevIL\src-ILUT\CMakeFiles\ILUT.dir 目录,打开 linklibs.rsp 文件,追加两个参数:
-lopengl32 -lglu32
重新 make 即可