ID: 20785
User updated by: [EMAIL PROTECTED]
-Summary: ImageCreateTrueColor, ImageCreateFromJPEG can only
create 256 color images
Reported By: [EMAIL PROTECTED]
-Status: Feedback
+Status: Open
Bug Type: PDF related
Operating System: Linux
PHP Version: 4.2.3
New Comment:
Clarification: 256 color images can be created with
ImageCreate, however ImageCreateTrueColor and possibly
other calls intended to create images with more than 256 colors fails.
Previous Comments:
------------------------------------------------------------------------
[2002-12-03 05:31:54] [EMAIL PROTECTED]
Please try using this CVS snapshot:
http://snaps.php.net/php4-latest.tar.gz
For Windows:
http://snaps.php.net/win32/php4-win32-latest.zip
------------------------------------------------------------------------
[2002-12-03 05:26:57] [EMAIL PROTECTED]
As reported at
http://www.php.net/manual/en/function.pdf-open-memory-image.php
ImageCreateTrueColor and others does not work correctly when using
pdflib > 4.0.x and PHP > 4.2.x and reading the image from memory
(reading from
file seems to work though).
Excerpt from forum and configuration information below.
WORKS:
$im = ImageCreate(100, 100);
$pim = pdf_open_memory_image($pdf, $im);
DOES NOT WORK:
$im = ImageCreateTrueColor(100, 100);
$pim = pdf_open_memory_image($pdf, $im);
DOES NOT WORK:
$im = ImageCreateFromJPEG("file.jpg");
$pim = pdf_open_memory_image($pdf, $im);
-----------------------
PHP 4.2.3
GD 2.0.8
PDFLib 4.0.3 (compiled with default options)
Configure Options:
./configure \
--with-config-file-path=/etc \
--with-apxs=/usr/local/apache/bin/apxs \
--enable-versioning \
--enable-inline-optimization \
--enable-magic-quotes \
--enable-track-vars \
--with-xml --with-dom --with-xmlrpc \
--with-mysql=/usr \
--enable-sockets \
--with-ldap \
--with-imap=/usr/local --with-imap-ssl=/usr/local
\
--with-mm \
--enable-memory-limit \
--enable-bcmath \
--enable-sigchild \
--with-zlib=/usr \
--with-curl=/usr/local \
--with-dom=/usr/include/libxml2/libxml \
--enable-exif \
--enable-ftp \
--with-gettext=/usr/share \
--with-gd \
--with-ttf \
--with-freetype-dir=/usr/local/include/freetype2/freetype \
--enable-gd-imgstrttf \
--with-png-dir=/usr \
--with-jpeg-dir=/usr \
--with-tiff-lib=/usr \
--with-mcal=../libmcal \
--with-openssl \
--with-mcrypt --with-mhash \
--with-pspell \
--with-ming \
--with-pdflib
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=20785&edit=1