By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,998 Members | 2,837 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,998 IT Pros & Developers. It's quick & easy.

maximum size for imagecreatetruecolor()??

P: n/a
there seems to be a maximum size (in px) for images created with
imagecreatetruecolor (somewhere between 4000 px and 4500 px). if the
image is bigger than that size, the browser doesn't display it but
reports errors in the image.

is this maximum size inbuilt into php?

or

does it depend on my server config and if yes how can i read it?
tia, micha

Jul 17 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
ch*********@web.de wrote:
there seems to be a maximum size (in px) for images created with
imagecreatetruecolor (somewhere between 4000 px and 4500 px). if the
image is bigger than that size, the browser doesn't display it but
reports errors in the image.

is this maximum size inbuilt into php?

or

does it depend on my server config and if yes how can i read it?
tia, micha


A full-colour 4096x4096 image occupies 48 MB (or 64 MB it it has an alpha
channel). My guess is this problem is not so much to do with a maximum image
size but rather the amount of memory allocated to the running of your
website. Either talk to your web hosts about getting it increased, or stop
using such enormous images.

--
phil [dot] ronan @ virgin [dot] net
http://vzone.virgin.net/phil.ronan/
Jul 17 '05 #2

P: n/a

Philip Ronan wrote:
ch*********@web.de wrote:
there seems to be a maximum size (in px) for images created with
imagecreatetruecolor (somewhere between 4000 px and 4500 px). if the image is bigger than that size, the browser doesn't display it but
reports errors in the image.

is this maximum size inbuilt into php?

or

does it depend on my server config and if yes how can i read it?
tia, micha

A full-colour 4096x4096 image occupies 48 MB (or 64 MB it it has an

alpha channel). My guess is this problem is not so much to do with a maximum image size but rather the amount of memory allocated to the running of your
website. Either talk to your web hosts about getting it increased, or stop using such enormous images.

--
phil [dot] ronan @ virgin [dot] net
http://vzone.virgin.net/phil.ronan/

yes, that occurred to me after posting. i had not thought about memory
at all, just followed the manuals recommendation to use
imagecreatetruecolor() instead of imagecreate(), even if i don't really
need true color images. works fine now with imagecreate.

thnaks, micha

Jul 17 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.