imagefill

(PHP 4, PHP 5, PHP 7)

imagefill锟斤拷锟斤拷锟斤拷锟�

说锟斤拷

imagefill ( resource $image , int $x , int $y , int $color ) : bool

imagefill() 锟斤拷 image 图锟斤拷锟斤拷锟斤拷锟� x锟斤拷y锟斤拷图锟斤拷锟斤拷锟较斤拷为 0, 0锟斤拷锟斤拷锟斤拷 color 锟斤拷色执锟斤拷锟斤拷锟斤拷锟斤拷洌拷锟斤拷锟� x, y 锟斤拷锟斤拷色锟斤拷同锟斤拷锟斤拷锟节的点都锟结被锟斤拷洌╋拷锟�

Example #1 imagefill() 锟斤拷锟斤拷

<?php

$im 
imagecreatetruecolor(100100);

// 锟斤拷锟斤拷锟斤拷锟斤拷为锟斤拷色
$red imagecolorallocate($im25500);
imagefill($im00$red);

header('Content-type: image/png');
imagepng($im);
imagedestroy($im);
?>

锟轿硷拷 imagecolorallocate()锟斤拷