summaryrefslogtreecommitdiff
path: root/ext/gd/tests/imagefilledellipse_basic.phpt
blob: 8b3682bfa8524465b0852bb8f682c9385c6c3962 (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
--TEST--
Testing imagefilledellipse() of GD library
--SKIPIF--
<?php 
if (!extension_loaded("gd")) die("skip GD not present");
?>
--FILE--
<?php

$image = imagecreatetruecolor(100, 100);

$white = imagecolorallocate($image, 0xFF, 0xFF, 0xFF);

//create an ellipse and fill it with white color    
imagefilledellipse($image, 50, 50, 40, 30, $white);

ob_start();
imagegd($image);
$img = ob_get_contents();
ob_end_clean();

echo md5(base64_encode($img));
?>
--EXPECT--
233beffe003a41d3c9e788039e3191dd