Re: [GD-DEVEL] trouble with antialiasing
| From: | Pierre | Date: | Sat, 27 Oct 2007 08:37:52 +0000 |
| Subject: | Re: [GD-DEVEL] trouble with antialiasing | ||
| References: | 1 | Groups: | php.gd.devel |
| Request: | Send a blank email to php-gd-devel+get-273@lists.php.net to get a copy of this message | ||
Hi Eric,
On 10/26/07, Eric Tucker <et@hexagon.tallmaple.com> wrote:
> Hi,
>
> I am having trouble getting even the most basic antialiasing to work.
> I copied the example right out of the manual and built it in as much
> isolation as possible, but am still getting a non-antialiased line.
> My test source file is included below, and I am building it with:
>
> gcc -lgd -o gtest gtest.c
>
> This is on Fedora Core 6, with gd-2.0.35-1.fc6 and
> gd-devel-2.0.35-1.fc6.
>
> I was able to get it to antialias by both (a) creating the image
> instead with gdImageCreateTrueColor(), and (b) changing the second
> 99 to a 49, thus making the line be at less than a 45-degree angle.
> But these seem arbitrary to me -- I was just thrashing around
> randomly -- and I don't see why the original code does not work.
>
> Am I missing something obvious here?
> im = gdImageCreate(100, 100);
im = gdImageCreateTrueColor(100,100);
Truecolor image has AA support.
Cheers,
--Pierrre