summaryrefslogtreecommitdiff
path: root/ext/gd/tests/bug77943.phpt
blob: 1009b3e4b38d1f3cb15d71ed346c11692b1e9821 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
--TEST--
Bug #77943 (imageantialias($image, false); does not work)
--SKIPIF--
<?php
if (!extension_loaded('gd')) die('skip gd extension not available');
?>
--FILE--
<?php
require_once __DIR__ . '/func.inc';

$width = 400;
$height = 300;
$im = imagecreatetruecolor($width, $height);
$white = imagecolorallocate($im, 255, 255, 255);
$blue = imagecolorallocate($im, 0, 0, 255);

imageantialias($im, false);
imagefilledrectangle($im, 0, 0, $width-1, $height-1, $white);

imageline($im, 0, 0, $width, $height, $blue);
imagesetthickness($im, 3);
imageline($im, 10, 0, $width, $height-10, $blue);

test_image_equals_file(__DIR__ . '/bug77943.png', $im);
?>
===DONE===
--EXPECT--
The images are equal.
===DONE===