中⽂详解GD库函数⼤全
GetImageSize
作⽤:取得图⽚的⼤⼩[即长与宽]  ⽤法:array GetImageSize(string filename, array [imageinfo]);
ImageArc
作⽤:画弧线⽤法:int ImageArc(int im, int cx, int cy, int w, int h, int s, int e, int col);
ImageChar
作⽤:写出横向字符⽤法:int ImageChar(int im, int font, int x, int y, string c, int col);
ImageCharUp
作⽤:写出竖式字符⽤法:int ImageCharup(int im, int font, int x, int y, string c, int col);
ImageColorAllocate
作⽤:匹配颜⾊⽤法:int ImageColorAllocate(int im, int red, int green, int blue);
ImageColorTransparent
作⽤:指定透明背景⾊⽤法:int ImageColorTransparent(int im, int [col]);
ImageCopyResized
作⽤:复制新图并调整⼤⼩⽤法:int ImageCopyResized(int dst_im, int src_im, int dstX, int dstY, int srcX, int srcY, int dstW, int dstH, int srcW, int srcH);
ImageCreate
作⽤:建⽴新图⽤法:int ImageCreate(int x_size, int y_size);
resized
ImageDashedLine
作⽤:绘虚线⽤法:int ImageDashedLine(int im, int x1, int y1, int x2, int y2, int col);
ImageDestroy 作⽤:结束图形⽤法解释:int ImageDestroy(int im);
ImageFill
作⽤:图形着⾊⽤法:int ImageFill(int im, int x, int y, int col);
ImageFilledPolygon作⽤:多边形区域着⾊⽤法:int ImageFilledPolygon(int im, array points, int num_points, int col); ImageFilledRectangle作⽤:矩形区域着⾊⽤法:int ImageFilledRectangle(int im, int x1, int y1, int x2, int y2, int col); ImageFillToBorder作⽤:指定颜⾊区域内着⾊⽤法:int ImageFillToBorder(int im, int x, int y, int border, int col);
ImageFontHeight
作⽤:取得字型的⾼度⽤法:int ImageFontHeight(int font);
ImageFontWidth作⽤:取得字型的宽度⽤法:int ImageFontWidth(int font);
ImageInterlace作⽤:使⽤交错式显⽰与否⽤法:int ImageInterlace(int im, int [interlace]);
ImageLine作⽤:绘实线⽤法:int ImageLine(int im, int x1, int y1, int x2, int y2, int col);
ImageLoadFont作⽤:载⼊点阵字型⽤法:int ImageLoadFont(string file);
ImagePolygon作⽤:绘多边形⽤法:int ImagePolygon(int im, array points, int num_points, int col);
ImageRectangle作⽤:绘矩形⽤法:int ImageRectangle(int im, int x1, int y1, int x2, int y2, int col);
ImageSetPixel作⽤:绘点⽤法:int ImageSetPixel(int im, int x, int y, int col); ImageString 作⽤:绘横式字符串⽤法:int ImageString(int im, int font, int x, int y, string s, int col);
ImageStringUp作⽤:绘直式字符串⽤法:int ImageStringUp(int im, int font, int x, int y, string s, int col);
ImageSX
作⽤:取得图⽚的宽度⽤法:int ImageSX(int im);
ImageSY
作⽤:取得图⽚的⾼度⽤法:int ImageSY(int im);
ImageTTFBBox
作⽤:计算 TTF ⽂字所占区域⽤法:array ImageTTFBBox(int size, int angle, string fontfile, string text);
ImageTTFText作⽤:写 TTF ⽂字到图中⽤法:array ImageTTFText(int im, int size, int angle, int x, int y, int col, string fontfile, string text); ImageColorAt 作⽤:取得图中指定点颜⾊的索引值⽤法:int ImageColorAt(int im, int x, int y);
ImageColorClosest
作⽤:计算⾊表中与指定颜⾊最接近者⽤法:int ImageColorClosest(int im, int red, int green, int blue);
ImageColorExact
作⽤:计算⾊表上指定颜⾊索引值⽤法:int ImageColorExact(int im, int red, int green, int blue);
ImageColorResolve
作⽤:计算⾊表上指定或最接近颜⾊的索引值⽤法:int ImageColorResolve(int im, int red, int green, int blue);
ImageColorSet
作⽤:设定⾊表上指定索引的颜⾊⽤法:boolean ImageColorSet(int im, int index, int red, int green, int blue);  ImageColorsForIndex 作⽤:取得⾊表上指定索引的颜⾊⽤法:array ImageColorsForIndex(int im, int index);
ImageColorsTotal
作⽤:计算图的颜⾊数⽤法:int ImageColorsTotal(int im); ImagePSLoadFont 作⽤:载⼊ PostScript 字型⽤法:int ImagePSLoadFont(string filename);
ImagePSFreeFont
作⽤:卸下 PostScript 字型⽤法:void ImagePSFreeFont(int fontindex);
ImagePSEncodeFont
作⽤:PostScript 字型转成向量字⽤法:int ImagePSEncodeFont(string encodingfile);
ImagePSText作⽤:写 PostScript ⽂字到图中⽤法:array ImagePSText(int image, string text, int font, int size, int foreground, int background, int x, int y, int space, int tightness, float angle, int antialias_steps);
ImagePSBBox作⽤:计算 PostScript ⽂字所占区域⽤法: array ImagePSBBox(string text, int font, int size, int space, int width, float angle);
ImageCreateFromPNG作⽤:取出 PNG 图型⽤法:int ImageCreateFromPng(string filename);
ImagePNG作⽤:建⽴ PNG 图型⽤法:int ImagePng(int im, string [filename]);
ImageCreateFromGIF作⽤:取出 GIF 图型⽤法:int ImageCreateFromGif(string filename);
ImageGIF作⽤:建⽴ GIF 图型⽤法:int ImageGif(int im, string [filename]);

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。