jQuery禁用鍵盤后退屏蔽F5刷新及禁用右鍵單擊
654
2024-03-13
(PHP 4, PHP 5)
imagefilledpolygon — 畫一多邊形并填充
$image
, array $points
, int $num_points
, int $color
)
imagefilledpolygon() 在 image
圖像中畫一個填充了的多邊形。
points
參數是一個按順序包含有多邊形各頂點的
x 和 y
坐標的數組。
num_points
參數是頂點的總數,必須大于 3。
Example #1 imagefilledpolygon() 例子
<?php
// 建立多邊形各頂點坐標的數組
$values = array(
40, 50, // Point 1 (x, y)
20, 240, // Point 2 (x, y)
60, 60, // Point 3 (x, y)
240, 20, // Point 4 (x, y)
50, 40, // Point 5 (x, y)
10, 10 // Point 6 (x, y)
);
// 創建圖像
$image = imagecreatetruecolor(250, 250);
// 設定顏色
$bg = imagecolorallocate($image, 200, 200, 200);
$blue = imagecolorallocate($image, 0, 0, 255);
// 畫一個多邊形
imagefilledpolygon($image, $values, 6, $blue);
// 輸出圖像
header('Content-type: image/png');
imagepng($image);
imagedestroy($image);
?>
#免責聲明#
本站[綠夏技術導航]提供的一切軟件、教程和內容信息僅限用于學習和研究目的;不得將上述內容用于商業或者非法用途,否則,一切后果請用戶自負。本站信息來自網絡收集整理,版權爭議與本站無關。您必須在下載后的24個小時之內,從您的電腦或手機中徹底刪除上述內容。如果您喜歡該程序或內容,請支持正版,購買注冊,得到更好的正版服務。我們非常重視版權問題,如有侵權請郵件[admin@lxwl520.com]與我們聯系進行刪除處理。敬請諒解!