1--TEST-- 2Testing imagefilltoborder() of GD library 3--CREDITS-- 4Ivan Rosolen <contato [at] ivanrosolen [dot] com> 5#testfest PHPSP on 2009-06-30 6--EXTENSIONS-- 7gd 8--FILE-- 9<?php 10// Create a image 11$image = imagecreatetruecolor( 100, 100 ); 12 13// Draw a rectangle 14imagefilledrectangle( $image, 0, 0, 100, 100, imagecolorallocate( $image, 255, 255, 255 ) ); 15 16// Draw an ellipse to fill with a black border 17imageellipse( $image, 50, 50, 50, 50, imagecolorallocate( $image, 0, 0, 0 ) ); 18 19// Fill border 20imagefilltoborder( $image, 50, 50, imagecolorallocate( $image, 0, 0, 0 ), imagecolorallocate( $image, 255, 0, 0 ) ); 21 22include_once __DIR__ . '/func.inc'; 23test_image_equals_file(__DIR__ . '/imagefilltoborder_basic.png', $image); 24 25?> 26--EXPECT-- 27The images are equal. 28