dsaba Posted March 31, 2007 Share Posted March 31, 2007 Hey guys! I looked on php.net, googled, and searched these forums first BUT- I didn't find any really good documentation on what these functions do and what the difference is between them. I THINK that this function imagecreatefromgd() will do what imagecreatefromjpeg, gif, png...etc... except it will automatically recognize what type it is, jpeg, gif, etc... is that what it does? and what's the difference between imagecreatefromgd2 and imagecreatfromdg -thanks Link to comment https://forums.phpfreaks.com/topic/45020-solved-imagecreatefromgd-and-imagecreatefromgd2/ Share on other sites More sharing options...
Barand Posted March 31, 2007 Share Posted March 31, 2007 If you regulary use the same image (say as as a background image on which you overlay different text messages) then you can speed things up by saving the image as raw gd code and loading that instead. If you use "imagecreatefromjpeg()" it has to convert the image internally. You save as a raw gd image with imagegd(), or imagegd2() then use imagecreatefromgd() to load the file. If you saved with imagegd2(), load with imagecreatefromgd2() Link to comment https://forums.phpfreaks.com/topic/45020-solved-imagecreatefromgd-and-imagecreatefromgd2/#findComment-218576 Share on other sites More sharing options...
tarun Posted March 31, 2007 Share Posted March 31, 2007 Ive Been Wondering The Same Thing Aswell And Now I No Topic Solved? Link to comment https://forums.phpfreaks.com/topic/45020-solved-imagecreatefromgd-and-imagecreatefromgd2/#findComment-218586 Share on other sites More sharing options...
dsaba Posted March 31, 2007 Author Share Posted March 31, 2007 -thanks barand that clears things up but: how I do I save a raw gd image after I run the url through this function: imagecreatefromjpeg() i know i can save the variable in a session or a cookie, but as far as physically saving it? Link to comment https://forums.phpfreaks.com/topic/45020-solved-imagecreatefromgd-and-imagecreatefromgd2/#findComment-218709 Share on other sites More sharing options...
Barand Posted March 31, 2007 Share Posted March 31, 2007 Read my post http://www.php.net/imagegd Link to comment https://forums.phpfreaks.com/topic/45020-solved-imagecreatefromgd-and-imagecreatefromgd2/#findComment-218712 Share on other sites More sharing options...
dsaba Posted March 31, 2007 Author Share Posted March 31, 2007 no notes, it takes a while for your note to appear on all mirrors at php.net but i didn't know about that function, i guess its pretty obvious now huh? B -brilliant A - answers questions effectively R - read the question effectively A - answers the question effectively again if he didn't already N - need i say more? D - da man! *yeah i just realized i misunderstood you Link to comment https://forums.phpfreaks.com/topic/45020-solved-imagecreatefromgd-and-imagecreatefromgd2/#findComment-218714 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.