導航:首頁 > 編程語言 > php畫圖工具

php畫圖工具

發布時間:2024-02-23 07:11:15

php怎麼輸出背景透明的圖片

php可以使用GD庫或者ImageMagick工具生成png或者gif的背景透明圖片.推薦使用ImageMagick.
這里有範例 http://php.net/manual/en/imagick.examples-1.php
准備一張png圖片,放到php文件的目錄,運行看看效果.
<?php
/* Read the image */
$im = new Imagick("test.png");
/* Thumbnail the image */
$im->thumbnailImage(200, null);

/* Create a border for the image */
$im->borderImage(new ImagickPixel("white"), 5, 5);

/* Clone the image and flip it */
$reflection = $im->clone();
$reflection->flipImage();

/* Create gradient. It will be overlayed on the reflection */
$gradient = new Imagick();

/* Gradient needs to be large enough for the image and the borders */
$gradient->newPseudoImage($reflection->getImageWidth() + 10, $reflection->getImageHeight() + 10, "gradient:transparent-black");

/* Composite the gradient on the reflection */
$reflection->compositeImage($gradient, imagick::COMPOSITE_OVER, 0, 0);

/* Add some opacity. Requires ImageMagick 6.2.9 or later */
$reflection->setImageOpacity( 0.3 );

/* Create an empty canvas */
$canvas = new Imagick();

/* Canvas needs to be large enough to hold the both images */
$width = $im->getImageWidth() + 40;
$height = ($im->getImageHeight() * 2) + 30;
$canvas->newImage($width, $height, new ImagickPixel("black"));
$canvas->setImageFormat("png");

/* Composite the original image and the reflection on the canvas */
$canvas->compositeImage($im, imagick::COMPOSITE_OVER, 20, 10);
$canvas->compositeImage($reflection, imagick::COMPOSITE_OVER, 20, $im->getImageHeight() + 10);

/* Output the image*/
header("Content-Type: image/png");
echo $canvas;
?>

❷ 繪圖軟體有哪些

常用的制圖軟體有很多,主要有:
1、Photoshop。最強大的圖像處理軟體,以處理像素所構成的數字圖像為主。該軟體擁有眾多的編修與繪圖工具,使用方便,功能強大,可以高效地進行圖片處理工作。
2、Coreldraw。Coreldraw是一款以處理矢量文件為主的繪圖與排版軟體,主要用於商標設計、標志製作、模型繪制、插圖描畫、排版及分色輸出等諸多領域。在美術設計和商業設計領域十分受歡迎。
3、Adobe Illustrator。Adobe Illustrator與Coreldraw類似,也是一款用於處理矢量插畫的軟體。但不同的是,Adobe Illustrator廣泛應用於印刷出版、海報書籍排版等,主要是為線稿提供較高的精度和控制,適合各種出版物插圖的處理。
4、AutoCAD。AutoCAD是一款計算機輔助設計軟體,可以用於繪制二維制圖和基本三維設計。
5、ArcGIS。ArcGIS是一款地理信息系統軟體,可用於地理數據的存儲、顯示、制圖、分析等。

閱讀全文

與php畫圖工具相關的資料

熱點內容
蘋果解壓視頻在哪裡找 瀏覽:964
中國程序員發現最大程序漏洞 瀏覽:776
圖像數據加密解密 瀏覽:189
pdf金 瀏覽:511
湖北拼團商城源碼 瀏覽:198
為什麼說伺服器沒有響應 瀏覽:972
linux怎麼搭web伺服器 瀏覽:254
房產證加密收費嗎 瀏覽:154
slam演算法處理數據 瀏覽:269
如何判斷伺服器ip地址和版本號 瀏覽:966
python獲取html內容 瀏覽:771
北歐大神程序員 瀏覽:205
安卓手機怎麼拍出照片的質感 瀏覽:836
編譯後的病毒長什麼樣子 瀏覽:24
圍棋與程序員 瀏覽:262
加密和解密的單詞 瀏覽:986
我的世界td伺服器怎麼注冊 瀏覽:417
編譯器的堆空間 瀏覽:604
雲引擎雲伺服器 瀏覽:912
解壓視頻聲控吃冰義大利 瀏覽:409