<?xml version="1.0" encoding="utf-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: Problems with GD: Solved</title>
	<atom:link href="http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/</link>
	<description>The weblog of Joshua Eichorn, AJAX, PHP and Open Source</description>
	<pubDate>Sun, 12 Oct 2008 01:22:02 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.2</generator>
		<item>
		<title>By: Dan</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-561411</link>
		<dc:creator>Dan</dc:creator>
		<pubDate>Sat, 30 Aug 2008 08:25:03 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-561411</guid>
		<description>Thanks, great help!

Pierre, I didn't care reading all your flaming, I don't like it...</description>
		<content:encoded><![CDATA[<p>Thanks, great help!</p>
<p>Pierre, I didn&#8217;t care reading all your flaming, I don&#8217;t like it&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: joeri</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-467362</link>
		<dc:creator>joeri</dc:creator>
		<pubDate>Wed, 14 May 2008 12:21:16 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-467362</guid>
		<description>Suddenly the tone changed... what happend?

Im an artists myself and find the terms used by GD about opacity very confussing.

imagesavealpha($im,true);

save??? what to disc? preserve the alpha? Yeah why not? 
Just let me load a 24 or 32 bit image and leave me alone with commands about what to do with the channels... Dooh... what next? 
imagesavered($im,true); imagesaveblue($im,true); imagesavegreen($im,true); 

imagealphablending($im,true);
can't GD adopt terms Gimp and Photoshop use?

Forget about imagealphablending, just give me composite tools.

$newimage= imagecomposite($img_under, $img_over, GD_DEFAULT );
( just a 32bit image over a 32bit image, thank you very much )
and why not add:
$newimage= imagecomposite($img_under, $img_over, GD_ADD );
$newimage= imagecomposite($img_under, $img_over, GD_MULTIPLY );
$newimage= imagecomposite($img_under, $img_over, GD_MASK, $img_mask );

Reading the Manual does not change GD not giving expected behavior, it only changes my expectations. There is a difference.
Its not a bug, so sorry for not filing it Pierre.</description>
		<content:encoded><![CDATA[<p>Suddenly the tone changed&#8230; what happend?</p>
<p>Im an artists myself and find the terms used by GD about opacity very confussing.</p>
<p>imagesavealpha($im,true);</p>
<p>save??? what to disc? preserve the alpha? Yeah why not?<br />
Just let me load a 24 or 32 bit image and leave me alone with commands about what to do with the channels&#8230; Dooh&#8230; what next?<br />
imagesavered($im,true); imagesaveblue($im,true); imagesavegreen($im,true); </p>
<p>imagealphablending($im,true);<br />
can&#8217;t GD adopt terms Gimp and Photoshop use?</p>
<p>Forget about imagealphablending, just give me composite tools.</p>
<p>$newimage= imagecomposite($img_under, $img_over, GD_DEFAULT );<br />
( just a 32bit image over a 32bit image, thank you very much )<br />
and why not add:<br />
$newimage= imagecomposite($img_under, $img_over, GD_ADD );<br />
$newimage= imagecomposite($img_under, $img_over, GD_MULTIPLY );<br />
$newimage= imagecomposite($img_under, $img_over, GD_MASK, $img_mask );</p>
<p>Reading the Manual does not change GD not giving expected behavior, it only changes my expectations. There is a difference.<br />
Its not a bug, so sorry for not filing it Pierre.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pierre</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-5109</link>
		<dc:creator>Pierre</dc:creator>
		<pubDate>Tue, 11 Oct 2005 20:36:02 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-5109</guid>
		<description>I do not know the quality of the original images, but with imagemagic you can select different filters/interpolation methods, some are slower but if the quality is one of the goal.

For GD itself, the current implementation (a generic one, not bad neither good ;) ) is not going to change that soon but in php6, not sure if I will keep GD2 or not for this kind of tasks.

I have some patches to add some features to the existing GD, giving either better quality or faster processing, if needed but not free...</description>
		<content:encoded><![CDATA[<p>I do not know the quality of the original images, but with imagemagic you can select different filters/interpolation methods, some are slower but if the quality is one of the goal.</p>
<p>For GD itself, the current implementation (a generic one, not bad neither good <img src='http://blog.joshuaeichorn.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> ) is not going to change that soon but in php6, not sure if I will keep GD2 or not for this kind of tasks.</p>
<p>I have some patches to add some features to the existing GD, giving either better quality or faster processing, if needed but not free&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joshua Eichorn</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-5108</link>
		<dc:creator>Joshua Eichorn</dc:creator>
		<pubDate>Tue, 11 Oct 2005 20:14:26 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-5108</guid>
		<description>I made a couple more changes while you were sending that last message Pierre.  Mainly about quality on resize, so hopefully you will keep that in mind in php6 as well.  It would be nice to be able to make the speed quality trade-off on those operations as long as its still the same copy call.</description>
		<content:encoded><![CDATA[<p>I made a couple more changes while you were sending that last message Pierre.  Mainly about quality on resize, so hopefully you will keep that in mind in php6 as well.  It would be nice to be able to make the speed quality trade-off on those operations as long as its still the same copy call.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pierre</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-5107</link>
		<dc:creator>Pierre</dc:creator>
		<pubDate>Tue, 11 Oct 2005 20:08:34 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-5107</guid>
		<description>Now we agree, the BC problems in GD force me to keep the default behaviors as they were. That makes the code slighty longer than what it should be (and, per se, harder to read).

Stay tuned to php6, that will change :)</description>
		<content:encoded><![CDATA[<p>Now we agree, the BC problems in GD force me to keep the default behaviors as they were. That makes the code slighty longer than what it should be (and, per se, harder to read).</p>
<p>Stay tuned to php6, that will change <img src='http://blog.joshuaeichorn.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pierre</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-5106</link>
		<dc:creator>Pierre</dc:creator>
		<pubDate>Tue, 11 Oct 2005 19:06:27 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-5106</guid>
		<description>What you are missing is that in both cases alpha is preserved. You have a background color but the glasses are still transparent (check it, the inside color has the alpha component set to 100%).

What does that mean?

If you copy this image, let say, on a face, and set the alpha blending mode to true, you will get a nice glasses on this face. something like:
http://blog.thepimp.net/alpha.png (sorry, only (c)less photo with a face I found :)

That just prooved that alpha is a) preserved and b) works with imagecopyresampled. To set or unset the alpha blending, see imagealphablending (http://de.php.net/imagealphablending).


A blog is not a way to report bugs or ask questions. You expect one to answer you because you were ranting here, fine. Do not expect me to answer you anymore here, but bugs.php.net or ask php-general if you have problems to understand how gd works, or me if you have my mail (Greg should have it ;).</description>
		<content:encoded><![CDATA[<p>What you are missing is that in both cases alpha is preserved. You have a background color but the glasses are still transparent (check it, the inside color has the alpha component set to 100%).</p>
<p>What does that mean?</p>
<p>If you copy this image, let say, on a face, and set the alpha blending mode to true, you will get a nice glasses on this face. something like:<br />
<a href="http://blog.thepimp.net/alpha.png" rel="nofollow">http://blog.thepimp.net/alpha.png</a> (sorry, only (c)less photo with a face I found <img src='http://blog.joshuaeichorn.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>That just prooved that alpha is a) preserved and b) works with imagecopyresampled. To set or unset the alpha blending, see imagealphablending (http://de.php.net/imagealphablending).</p>
<p>A blog is not a way to report bugs or ask questions. You expect one to answer you because you were ranting here, fine. Do not expect me to answer you anymore here, but bugs.php.net or ask php-general if you have problems to understand how gd works, or me if you have my mail (Greg should have it ;).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joshua Eichorn</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-5105</link>
		<dc:creator>Joshua Eichorn</dc:creator>
		<pubDate>Tue, 11 Oct 2005 18:48:52 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-5105</guid>
		<description>Well lets see your calling me arrogant but yet you seem to imply im missing some thing simple to make this work.  And instead of at least pointing me to the manual page that has this info, you give a tip of the day.

Well lets see, I made a transparent color and then filled the background with it.  There is no imagebackground function so how else do you make a 100% transparent canvas.</description>
		<content:encoded><![CDATA[<p>Well lets see your calling me arrogant but yet you seem to imply im missing some thing simple to make this work.  And instead of at least pointing me to the manual page that has this info, you give a tip of the day.</p>
<p>Well lets see, I made a transparent color and then filled the background with it.  There is no imagebackground function so how else do you make a 100% transparent canvas.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pierre</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-5104</link>
		<dc:creator>Pierre</dc:creator>
		<pubDate>Tue, 11 Oct 2005 18:28:43 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-5104</guid>
		<description>What I am saying is that one has to know what he is talking about before arguing, blogging and making noises without being of a single help to the GD developers (me included).

The purpose of this post is nothing else that noises and arrogance as usual, if you were asking me instead you will get you answer. So yes, I think you should learn the topic and read the manual, it is not complete? not clear enough? report a bug, if I have time and motivation, I may help you.

Have a nice day


(tip of the day, having 100% alpha transparency does not mean that this color is the background color)</description>
		<content:encoded><![CDATA[<p>What I am saying is that one has to know what he is talking about before arguing, blogging and making noises without being of a single help to the GD developers (me included).</p>
<p>The purpose of this post is nothing else that noises and arrogance as usual, if you were asking me instead you will get you answer. So yes, I think you should learn the topic and read the manual, it is not complete? not clear enough? report a bug, if I have time and motivation, I may help you.</p>
<p>Have a nice day</p>
<p>(tip of the day, having 100% alpha transparency does not mean that this color is the background color)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joshua Eichorn</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-5103</link>
		<dc:creator>Joshua Eichorn</dc:creator>
		<pubDate>Tue, 11 Oct 2005 18:19:55 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-5103</guid>
		<description>So are you saying the default behavior is purposly broken in that case, and I just need to set a flag to make it treat things correctly.  Or GD is broken and I need to file a bug report.

Really the purpose of this post is too find out which so I can either leave a note in the manual explaining how to get the expected results or file a useful bug report.  I'm sorry if the original post didn't make that clear.</description>
		<content:encoded><![CDATA[<p>So are you saying the default behavior is purposly broken in that case, and I just need to set a flag to make it treat things correctly.  Or GD is broken and I need to file a bug report.</p>
<p>Really the purpose of this post is too find out which so I can either leave a note in the manual explaining how to get the expected results or file a useful bug report.  I&#8217;m sorry if the original post didn&#8217;t make that clear.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pierre</title>
		<link>http://blog.joshuaeichorn.com/archives/2005/10/11/problems-with-gd/#comment-5102</link>
		<dc:creator>Pierre</dc:creator>
		<pubDate>Tue, 11 Oct 2005 18:04:18 +0000</pubDate>
		<guid isPermaLink="false">http://blog.joshuaeichorn.com/?p=194#comment-5102</guid>
		<description>sorry we do not have this makeBrokenGDWorkLikeIWouldExpect flag, we do not have bug reports from you neither. but I have one thing for you, could help:
RTFM</description>
		<content:encoded><![CDATA[<p>sorry we do not have this makeBrokenGDWorkLikeIWouldExpect flag, we do not have bug reports from you neither. but I have one thing for you, could help:<br />
RTFM</p>
]]></content:encoded>
	</item>
</channel>
</rss>
