GD is an open source code library for the dynamic creation of images byprogrammers.
GD is written in C, and "wrappers" are available for Perl, PHP and otherlanguages. GD can read and write many different image formats. GD is commonlyused to generate charts, graphics, thumbnails, and most anything else, on thefly.
The most common applications of GD involve website development, although itcan be used with any standalone application!
The library was originally developed by Thomas Boutell and is now maintainedby many contributors (see the CONTRIBUTORS file) under theumbrella of PHP.net.
If you like to contribute, report bugs, see how to contribute document
For security related issues, please contact us at security@libgd.org
Support available in or using issues.
We also have a mailing list. To subscribe to any mailing list, send an email to gd-devel-subscribe@lists.php.net. Then emails can be sent to gd-devel@lists.php.net.
Please visit our homepage for more details.
GD has support for:
libheif
has AV1 decoding.Besides that, GD depends on some external libraries, which are all optionaland disabled by default:
CI means whether we have an automatic CI for this platform. If someone has CI for these platforms or any other platforms not listed here and would like to add them to our automatic CI, please get in touch with us, it will much appreciated!
Platform | Support | CI |
---|---|---|
Linux x64 | ✓ | ✓ |
Linux x86 | ✓ | ✓ |
Linux ARM64 | ✓ | ✓ |
Windows x86 | ✓ | ✓ |
Windows x64 | ✓ | ✓ |
Windows arm64 | ✓ | x |
macOS x64 | ✓ | ✓ |
macOS M1 | ✓ | x |
S390 | ✓ | x |
It is also known to work on almost all variations of *BSD, Solaris, etc. We don't have CI nor environment to test them. However many progamming languages binding do test libgd on these platforms.
It should compile with all C99 and C++ compliant compilers, either using CMake or the configure script.
We do have CI using:
最近跟着导师做项目,要求使用C语言编程,达到的目标是将字符串转为jpg格式的图片,在网上翻帖子的时候看到libgd这个库正好可以满足我的使用需求,先将其使用学习过程记录如下。 参考内容博客地址:http://elkpi.com/topics/libgd-notes.html libgd官网网址:https://libgd.github.io/
近日帮朋友安装GD库一直失败,安装所需要的依赖库很多。本来放弃了,今天发现自己想要circos画图,也需要GD模块。在此记录自己的安装过程,以防下次安装碰到安装问题。 按照以下步骤按照依赖库就可以,报错信息一般都是上一步的库未安装。 GD依赖库-zlib wget http://www.zlib.net/zlib-1.2.11.tar.gz tar zxvf zlib-1.2.11.tar.gz
今天安装启动nginx的时候报这个错误:error while loading shared libraries: libgd.so.2: cannot open shared object,网上查了相关资料,解决了,在此记录下,也让后面遇到这个问题的朋友能快速解决。 先说解决办法,帮助着急解决问题的朋友,这个是因为缺失gd库,把他装上就可以了。 安装办法: 1、直接yum install gd最
最近由于项目需要jpg进行压缩,查了相关资料,发现php的代码中使用了压缩图片使用libgd库,于是下载进行编译,因为历史问题,需要编译成32位的库,这个可就把我搞死了,他的源码中有cmake和automake方式,直接编译成的属于64位平台。于是我在cmake命令上面直接加上了如下命令: SET(CMAKE_CXX_FLAGS "-g -m32 -w -std=gnu++98" 编译的时候是通过
根据报错提示,是libgd.so.2类库文件加载失败。这种情况要么对应lib没有安装,要么安装位置没到正确位置。通过ldd命令查一下nginx依赖的类库文件: ldd /usr/local/nginx/sbin/nginx linux-vdso.so.1 => (0x00007fffd5fb6000) libpthread.so.0 => /lib64/libpthread.so.0 (