GD.c
上传用户:qdrechuli
上传日期:2022-08-01
资源大小:917k
文件大小:34k
- /*
- * This file was generated automatically by xsubpp version 1.9508 from the
- * contents of GD.xs. Do not edit this file, edit GD.xs instead.
- *
- * ANY CHANGES MADE HERE WILL BE LOST!
- *
- */
- #line 1 "GD.xs"
- #include "EXTERN.h"
- #include "perl.h"
- #include "XSUB.h"
- #include "libgd/gd.h"
- #ifdef FCGI
- #include <fcgi_stdio.h>
- #else
- #ifdef USE_SFIO
- #include <config.h>
- #else
- #include <stdio.h>
- #endif
- #include <perlio.h>
- #endif
- /* Copyright 1995, 1996, Lincoln D. Stein. See accompanying README file for
- usage restrictions */
- static int
- not_here(s)
- char *s;
- {
- croak("%s not implemented on this architecture", s);
- return -1;
- }
- static double
- constant(name, arg)
- char *name;
- int arg;
- {
- errno = 0;
- switch (*name) {
- case 'A':
- break;
- case 'B':
- break;
- case 'C':
- break;
- case 'D':
- break;
- case 'E':
- break;
- case 'F':
- break;
- case 'G':
- break;
- case 'H':
- break;
- case 'I':
- break;
- case 'J':
- break;
- case 'K':
- break;
- case 'L':
- break;
- case 'M':
- break;
- case 'N':
- break;
- case 'O':
- break;
- case 'P':
- break;
- case 'Q':
- break;
- case 'R':
- break;
- case 'S':
- break;
- case 'T':
- break;
- case 'U':
- break;
- case 'V':
- break;
- case 'W':
- break;
- case 'X':
- break;
- case 'Y':
- break;
- case 'Z':
- break;
- case 'a':
- break;
- case 'b':
- break;
- case 'c':
- break;
- case 'd':
- break;
- case 'e':
- break;
- case 'f':
- break;
- case 'g':
- if (strEQ(name, "gdBrushed"))
- #ifdef gdBrushed
- return gdBrushed;
- #else
- goto not_there;
- #endif
- if (strEQ(name, "gdDashSize"))
- #ifdef gdDashSize
- return gdDashSize;
- #else
- goto not_there;
- #endif
- if (strEQ(name, "gdMaxColors"))
- #ifdef gdMaxColors
- return gdMaxColors;
- #else
- goto not_there;
- #endif
- if (strEQ(name, "gdStyled"))
- #ifdef gdStyled
- return gdStyled;
- #else
- goto not_there;
- #endif
- if (strEQ(name, "gdStyledBrushed"))
- #ifdef gdStyledBrushed
- return gdStyledBrushed;
- #else
- goto not_there;
- #endif
- if (strEQ(name, "gdTiled"))
- #ifdef gdTiled
- return gdTiled;
- #else
- goto not_there;
- #endif
- if (strEQ(name, "gdTransparent"))
- #ifdef gdTransparent
- return gdTransparent;
- #else
- goto not_there;
- #endif
- break;
- case 'h':
- break;
- case 'i':
- break;
- case 'j':
- break;
- case 'k':
- break;
- case 'l':
- break;
- case 'm':
- break;
- case 'n':
- break;
- case 'o':
- break;
- case 'p':
- break;
- case 'q':
- break;
- case 'r':
- break;
- case 's':
- break;
- case 't':
- break;
- case 'u':
- break;
- case 'v':
- break;
- case 'w':
- break;
- case 'x':
- break;
- case 'y':
- break;
- case 'z':
- break;
- }
- errno = EINVAL;
- return 0;
- not_there:
- errno = ENOENT;
- return 0;
- }
- typedef gdImagePtr GD__Image;
- typedef gdFontPtr GD__Font;
- typedef PerlIO * InputStream;
- extern gdFontPtr gdFontLarge;
- extern gdFontPtr gdFontSmall;
- extern gdFontPtr gdFontMediumBold;
- extern gdFontPtr gdFontTiny;
- #line 206 "GD.c"
- XS(XS_GD_constant)
- {
- dXSARGS;
- if (items != 2)
- Perl_croak(aTHX_ "Usage: GD::constant(name, arg)");
- {
- char * name = (char *)SvPV(ST(0),PL_na);
- int arg = (int)SvIV(ST(1));
- double RETVAL;
- dXSTARG;
- RETVAL = constant(name, arg);
- XSprePUSH; PUSHn((double)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_new)
- {
- dXSARGS;
- if (items < 0 || items > 3)
- Perl_croak(aTHX_ "Usage: GD::Image::new(packname="GD::Image", x=64, y=64)");
- {
- char * packname;
- int x;
- int y;
- GD__Image RETVAL;
- if (items < 1)
- packname = "GD::Image";
- else {
- packname = (char *)SvPV(ST(0),PL_na);
- }
- if (items < 2)
- x = 64;
- else {
- x = (int)SvIV(ST(1));
- }
- if (items < 3)
- y = 64;
- else {
- y = (int)SvIV(ST(2));
- }
- #line 212 "GD.xs"
- {
- gdImagePtr theImage;
- theImage = gdImageCreate(x,y);
- RETVAL = theImage;
- }
- #line 258 "GD.c"
- ST(0) = sv_newmortal();
- sv_setref_pv(ST(0), "GD::Image", (void*)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image__newFromGif)
- {
- dXSARGS;
- if (items < 1 || items > 2)
- Perl_croak(aTHX_ "Usage: GD::Image::_newFromGif(packname="GD::Image", filehandle)");
- {
- char * packname;
- InputStream filehandle = IoIFP(sv_2io(ST(1)));
- GD__Image RETVAL;
- if (items < 1)
- packname = "GD::Image";
- else {
- packname = (char *)SvPV(ST(0),PL_na);
- }
- #line 226 "GD.xs"
- RETVAL = gdImageCreateFromGif(filehandle);
- #line 282 "GD.c"
- ST(0) = sv_newmortal();
- sv_setref_pv(ST(0), "GD::Image", (void*)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image__newFromXbm)
- {
- dXSARGS;
- if (items < 1 || items > 2)
- Perl_croak(aTHX_ "Usage: GD::Image::_newFromXbm(packname="GD::Image", filehandle)");
- {
- char * packname;
- InputStream filehandle = IoIFP(sv_2io(ST(1)));
- GD__Image RETVAL;
- if (items < 1)
- packname = "GD::Image";
- else {
- packname = (char *)SvPV(ST(0),PL_na);
- }
- #line 236 "GD.xs"
- RETVAL = gdImageCreateFromXbm(filehandle);
- #line 306 "GD.c"
- ST(0) = sv_newmortal();
- sv_setref_pv(ST(0), "GD::Image", (void*)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image__newFromGd)
- {
- dXSARGS;
- if (items < 1 || items > 2)
- Perl_croak(aTHX_ "Usage: GD::Image::_newFromGd(packname="GD::Image", filehandle)");
- {
- char * packname;
- InputStream filehandle = IoIFP(sv_2io(ST(1)));
- GD__Image RETVAL;
- if (items < 1)
- packname = "GD::Image";
- else {
- packname = (char *)SvPV(ST(0),PL_na);
- }
- #line 246 "GD.xs"
- RETVAL = gdImageCreateFromGd(filehandle);
- #line 330 "GD.c"
- ST(0) = sv_newmortal();
- sv_setref_pv(ST(0), "GD::Image", (void*)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_DESTROY)
- {
- dXSARGS;
- if (items != 1)
- Perl_croak(aTHX_ "Usage: GD::Image::DESTROY(image)");
- {
- GD__Image image;
- if (SvROK(ST(0))) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not a reference");
- #line 256 "GD.xs"
- {
- gdImageDestroy(image);
- }
- #line 355 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_gif)
- {
- dXSARGS;
- if (items != 1)
- Perl_croak(aTHX_ "Usage: GD::Image::gif(image)");
- {
- GD__Image image;
- SV * RETVAL;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 265 "GD.xs"
- {
- void* data;
- int size;
- data = gdImageGifPtr(image,&size);
- RETVAL = newSVpv((char*) data,size);
- free(data);
- }
- #line 383 "GD.c"
- ST(0) = RETVAL;
- sv_2mortal(ST(0));
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_gd)
- {
- dXSARGS;
- if (items != 1)
- Perl_croak(aTHX_ "Usage: GD::Image::gd(image)");
- {
- GD__Image image;
- SV * RETVAL;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 280 "GD.xs"
- {
- void* data;
- int size;
- data = gdImageGdPtr(image,&size);
- RETVAL = newSVpv((char*) data,size);
- free(data);
- }
- #line 413 "GD.c"
- ST(0) = RETVAL;
- sv_2mortal(ST(0));
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_transparent)
- {
- dXSARGS;
- if (items < 1)
- Perl_croak(aTHX_ "Usage: GD::Image::transparent(image, ...)");
- {
- GD__Image image;
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 295 "GD.xs"
- {
- int color;
- if (items > 1) {
- color=(int)SvIV(ST(1));
- gdImageColorTransparent(image,color);
- }
- RETVAL = gdImageGetTransparent(image);
- }
- #line 445 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_getBounds)
- {
- dXSARGS;
- if (items != 1)
- Perl_croak(aTHX_ "Usage: GD::Image::getBounds(image)");
- SP -= items;
- {
- GD__Image image;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 311 "GD.xs"
- {
- int sx,sy;
- sx = gdImageSX(image);
- sy = gdImageSY(image);
- EXTEND(sp,2);
- PUSHs(sv_2mortal(newSViv(sx)));
- PUSHs(sv_2mortal(newSViv(sy)));
- }
- #line 475 "GD.c"
- PUTBACK;
- return;
- }
- }
- XS(XS_GD__Image_rgb)
- {
- dXSARGS;
- if (items != 2)
- Perl_croak(aTHX_ "Usage: GD::Image::rgb(image, color)");
- SP -= items;
- {
- GD__Image image;
- int color = (int)SvIV(ST(1));
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 326 "GD.xs"
- {
- int r,g,b;
- r = gdImageRed(image,color);
- g = gdImageGreen(image,color);
- b = gdImageBlue(image,color);
- EXTEND(sp,3);
- PUSHs(sv_2mortal(newSViv(r)));
- PUSHs(sv_2mortal(newSViv(g)));
- PUSHs(sv_2mortal(newSViv(b)));
- }
- #line 510 "GD.c"
- PUTBACK;
- return;
- }
- }
- XS(XS_GD__Image_boundsSafe)
- {
- dXSARGS;
- if (items != 3)
- Perl_croak(aTHX_ "Usage: GD::Image::boundsSafe(image, x, y)");
- {
- GD__Image image;
- int x = (int)SvIV(ST(1));
- int y = (int)SvIV(ST(2));
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 344 "GD.xs"
- {
- RETVAL=gdImageBoundsSafe(image,x,y);
- }
- #line 538 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_getPixel)
- {
- dXSARGS;
- if (items != 3)
- Perl_croak(aTHX_ "Usage: GD::Image::getPixel(image, x, y)");
- {
- GD__Image image;
- int x = (int)SvIV(ST(1));
- int y = (int)SvIV(ST(2));
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 357 "GD.xs"
- {
- RETVAL=gdImageGetPixel(image,x,y);
- }
- #line 566 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_setPixel)
- {
- dXSARGS;
- if (items != 4)
- Perl_croak(aTHX_ "Usage: GD::Image::setPixel(image, x, y, color)");
- {
- GD__Image image;
- int x = (int)SvIV(ST(1));
- int y = (int)SvIV(ST(2));
- int color = (int)SvIV(ST(3));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 371 "GD.xs"
- {
- gdImageSetPixel(image,x,y,color);
- }
- #line 593 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_line)
- {
- dXSARGS;
- if (items != 6)
- Perl_croak(aTHX_ "Usage: GD::Image::line(image, x1, y1, x2, y2, color)");
- {
- GD__Image image;
- int x1 = (int)SvIV(ST(1));
- int y1 = (int)SvIV(ST(2));
- int x2 = (int)SvIV(ST(3));
- int y2 = (int)SvIV(ST(4));
- int color = (int)SvIV(ST(5));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 385 "GD.xs"
- {
- gdImageLine(image,x1,y1,x2,y2,color);
- }
- #line 621 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_dashedLine)
- {
- dXSARGS;
- if (items != 6)
- Perl_croak(aTHX_ "Usage: GD::Image::dashedLine(image, x1, y1, x2, y2, color)");
- {
- GD__Image image;
- int x1 = (int)SvIV(ST(1));
- int y1 = (int)SvIV(ST(2));
- int x2 = (int)SvIV(ST(3));
- int y2 = (int)SvIV(ST(4));
- int color = (int)SvIV(ST(5));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 399 "GD.xs"
- {
- gdImageDashedLine(image,x1,y1,x2,y2,color);
- }
- #line 649 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_openPolygon)
- {
- dXSARGS;
- if (items != 3)
- Perl_croak(aTHX_ "Usage: GD::Image::openPolygon(image, poly, color)");
- {
- GD__Image image;
- SV * poly = ST(1);
- int color = (int)SvIV(ST(2));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 410 "GD.xs"
- {
- dSP ;
- int length,count ;
- int x,y,i ;
- gdPointPtr polyptr;
- ENTER ;
- SAVETMPS ;
- PUSHMARK(sp) ;
- XPUSHs(poly) ;
- PUTBACK ;
- count = perl_call_method("length",G_SCALAR) ;
- SPAGAIN ;
- if (count != 1)
- croak("Didn't get a single result from GD::Poly::length() call.n");
- length = POPi ;
- PUTBACK ;
- FREETMPS ;
- LEAVE ;
- polyptr = (gdPointPtr)safemalloc(sizeof(gdPoint)*length);
- if (polyptr == NULL)
- croak("safemalloc() returned NULL in GD::Image::poly().n");
- for (i=0;i<length;i++) {
- ENTER ;
- SAVETMPS ;
- PUSHMARK(sp) ;
- XPUSHs(poly) ;
- XPUSHs(sv_2mortal(newSViv(i))) ;
- PUTBACK ;
- count = perl_call_method("getPt",G_ARRAY) ;
- SPAGAIN ;
- if (count != 2)
- croak("Didn't get a single result from GD::Poly::length() call.n");
- y = POPi ;
- x = POPi ;
- PUTBACK ;
- FREETMPS ;
- LEAVE ;
- polyptr[i].x = x;
- polyptr[i].y = y;
- }
- gdImageOpenPolygon(image,polyptr,length,color);
- safefree((char*) polyptr);
- }
- #line 719 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_filledPolygon)
- {
- dXSARGS;
- if (items != 3)
- Perl_croak(aTHX_ "Usage: GD::Image::filledPolygon(image, poly, color)");
- {
- GD__Image image;
- SV * poly = ST(1);
- int color = (int)SvIV(ST(2));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 466 "GD.xs"
- {
- dSP ;
- int length,count ;
- int x,y,i ;
- gdPointPtr polyptr;
- ENTER ;
- SAVETMPS ;
- PUSHMARK(sp) ;
- XPUSHs(poly) ;
- PUTBACK ;
- count = perl_call_method("length",G_SCALAR) ;
- SPAGAIN ;
- if (count != 1)
- croak("Didn't get a single result from GD::Poly::length() call.n");
- length = POPi ;
- PUTBACK ;
- FREETMPS ;
- LEAVE ;
- polyptr = (gdPointPtr)safemalloc(sizeof(gdPoint)*length);
- if (polyptr == NULL)
- croak("safemalloc() returned NULL in GD::Image::poly().n");
- for (i=0;i<length;i++) {
- ENTER ;
- SAVETMPS ;
- PUSHMARK(sp) ;
- XPUSHs(poly) ;
- XPUSHs(sv_2mortal(newSViv(i))) ;
- PUTBACK ;
- count = perl_call_method("getPt",G_ARRAY) ;
- SPAGAIN ;
- if (count != 2)
- croak("Didn't get a single result from GD::Poly::length() call.n");
- y = POPi ;
- x = POPi ;
- PUTBACK ;
- FREETMPS ;
- LEAVE ;
- polyptr[i].x = x;
- polyptr[i].y = y;
- }
- gdImageFilledPolygon(image,polyptr,length,color);
- safefree((char*) polyptr);
- }
- #line 789 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_rectangle)
- {
- dXSARGS;
- if (items != 6)
- Perl_croak(aTHX_ "Usage: GD::Image::rectangle(image, x1, y1, x2, y2, color)");
- {
- GD__Image image;
- int x1 = (int)SvIV(ST(1));
- int y1 = (int)SvIV(ST(2));
- int x2 = (int)SvIV(ST(3));
- int y2 = (int)SvIV(ST(4));
- int color = (int)SvIV(ST(5));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 525 "GD.xs"
- {
- gdImageRectangle(image,x1,y1,x2,y2,color);
- }
- #line 817 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_filledRectangle)
- {
- dXSARGS;
- if (items != 6)
- Perl_croak(aTHX_ "Usage: GD::Image::filledRectangle(image, x1, y1, x2, y2, color)");
- {
- GD__Image image;
- int x1 = (int)SvIV(ST(1));
- int y1 = (int)SvIV(ST(2));
- int x2 = (int)SvIV(ST(3));
- int y2 = (int)SvIV(ST(4));
- int color = (int)SvIV(ST(5));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 539 "GD.xs"
- {
- gdImageFilledRectangle(image,x1,y1,x2,y2,color);
- }
- #line 845 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_arc)
- {
- dXSARGS;
- if (items != 8)
- Perl_croak(aTHX_ "Usage: GD::Image::arc(image, cx, cy, w, h, s, e, color)");
- {
- GD__Image image;
- int cx = (int)SvIV(ST(1));
- int cy = (int)SvIV(ST(2));
- int w = (int)SvIV(ST(3));
- int h = (int)SvIV(ST(4));
- int s = (int)SvIV(ST(5));
- int e = (int)SvIV(ST(6));
- int color = (int)SvIV(ST(7));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 555 "GD.xs"
- {
- gdImageArc(image,cx,cy,w,h,s,e,color);
- }
- #line 875 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_fillToBorder)
- {
- dXSARGS;
- if (items != 5)
- Perl_croak(aTHX_ "Usage: GD::Image::fillToBorder(image, x, y, border, color)");
- {
- GD__Image image;
- int x = (int)SvIV(ST(1));
- int y = (int)SvIV(ST(2));
- int border = (int)SvIV(ST(3));
- int color = (int)SvIV(ST(4));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 568 "GD.xs"
- {
- gdImageFillToBorder(image,x,y,border,color);
- }
- #line 902 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_fill)
- {
- dXSARGS;
- if (items != 4)
- Perl_croak(aTHX_ "Usage: GD::Image::fill(image, x, y, color)");
- {
- GD__Image image;
- int x = (int)SvIV(ST(1));
- int y = (int)SvIV(ST(2));
- int color = (int)SvIV(ST(3));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 580 "GD.xs"
- {
- gdImageFill(image,x,y,color);
- }
- #line 928 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_setBrush)
- {
- dXSARGS;
- if (items != 2)
- Perl_croak(aTHX_ "Usage: GD::Image::setBrush(image, brush)");
- {
- GD__Image image;
- GD__Image brush;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- if (sv_derived_from(ST(1), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(1)));
- brush = INT2PTR(GD__Image,tmp);
- }
- else
- croak("brush is not of type GD::Image");
- #line 590 "GD.xs"
- {
- gdImageSetBrush(image,brush);
- }
- #line 959 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_setTile)
- {
- dXSARGS;
- if (items != 2)
- Perl_croak(aTHX_ "Usage: GD::Image::setTile(image, tile)");
- {
- GD__Image image;
- GD__Image tile;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- if (sv_derived_from(ST(1), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(1)));
- tile = INT2PTR(GD__Image,tmp);
- }
- else
- croak("tile is not of type GD::Image");
- #line 600 "GD.xs"
- {
- gdImageSetTile(image,tile);
- }
- #line 990 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_setStyle)
- {
- dXSARGS;
- if (items < 1)
- Perl_croak(aTHX_ "Usage: GD::Image::setStyle(image, ...)");
- {
- GD__Image image;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 609 "GD.xs"
- {
- int *style;
- int i;
- if (items < 2)
- return;
- style = (int*) safemalloc(sizeof(int)*(items-1));
- if (style == NULL)
- croak("malloc returned NULL at setStyle().n");
- for(i=1;i<items;i++) {
- style[i-1]=(int)SvIV(ST(i));
- }
- gdImageSetStyle(image,style,items-1);
- safefree((char*) style);
- }
- #line 1025 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_colorAllocate)
- {
- dXSARGS;
- if (items != 4)
- Perl_croak(aTHX_ "Usage: GD::Image::colorAllocate(image, r, g, b)");
- {
- GD__Image image;
- int r = (int)SvIV(ST(1));
- int g = (int)SvIV(ST(2));
- int b = (int)SvIV(ST(3));
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 633 "GD.xs"
- {
- RETVAL = gdImageColorAllocate(image,r,g,b);
- }
- #line 1053 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_colorClosest)
- {
- dXSARGS;
- if (items != 4)
- Perl_croak(aTHX_ "Usage: GD::Image::colorClosest(image, r, g, b)");
- {
- GD__Image image;
- int r = (int)SvIV(ST(1));
- int g = (int)SvIV(ST(2));
- int b = (int)SvIV(ST(3));
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 647 "GD.xs"
- {
- RETVAL = gdImageColorClosest(image,r,g,b);
- }
- #line 1082 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_colorExact)
- {
- dXSARGS;
- if (items != 4)
- Perl_croak(aTHX_ "Usage: GD::Image::colorExact(image, r, g, b)");
- {
- GD__Image image;
- int r = (int)SvIV(ST(1));
- int g = (int)SvIV(ST(2));
- int b = (int)SvIV(ST(3));
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 661 "GD.xs"
- {
- RETVAL = gdImageColorExact(image,r,g,b);
- }
- #line 1111 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_colorsTotal)
- {
- dXSARGS;
- if (items != 1)
- Perl_croak(aTHX_ "Usage: GD::Image::colorsTotal(image)");
- {
- GD__Image image;
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 672 "GD.xs"
- {
- RETVAL = gdImageColorsTotal(image);
- }
- #line 1137 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_interlaced)
- {
- dXSARGS;
- if (items < 1)
- Perl_croak(aTHX_ "Usage: GD::Image::interlaced(image, ...)");
- {
- GD__Image image;
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 684 "GD.xs"
- {
- if (items > 1) {
- if (SvOK(ST(1)))
- gdImageInterlace(image,1);
- else
- gdImageInterlace(image,0);
- }
- RETVAL = gdImageGetInterlaced(image);
- }
- #line 1169 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Image_colorDeallocate)
- {
- dXSARGS;
- if (items != 2)
- Perl_croak(aTHX_ "Usage: GD::Image::colorDeallocate(image, color)");
- {
- GD__Image image;
- int color = (int)SvIV(ST(1));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- #line 702 "GD.xs"
- {
- gdImageColorDeallocate(image,color);
- }
- #line 1194 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_copy)
- {
- dXSARGS;
- if (items != 8)
- Perl_croak(aTHX_ "Usage: GD::Image::copy(destination, source, dstX, dstY, srcX, srcY, w, h)");
- {
- GD__Image destination;
- GD__Image source;
- int dstX = (int)SvIV(ST(2));
- int dstY = (int)SvIV(ST(3));
- int srcX = (int)SvIV(ST(4));
- int srcY = (int)SvIV(ST(5));
- int w = (int)SvIV(ST(6));
- int h = (int)SvIV(ST(7));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- destination = INT2PTR(GD__Image,tmp);
- }
- else
- croak("destination is not of type GD::Image");
- if (sv_derived_from(ST(1), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(1)));
- source = INT2PTR(GD__Image,tmp);
- }
- else
- croak("source is not of type GD::Image");
- #line 718 "GD.xs"
- {
- gdImageCopy(destination,source,dstX,dstY,srcX,srcY,w,h);
- }
- #line 1231 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_copyResized)
- {
- dXSARGS;
- if (items != 10)
- Perl_croak(aTHX_ "Usage: GD::Image::copyResized(destination, source, dstX, dstY, srcX, srcY, destW, destH, srcW, srcH)");
- {
- GD__Image destination;
- GD__Image source;
- int dstX = (int)SvIV(ST(2));
- int dstY = (int)SvIV(ST(3));
- int srcX = (int)SvIV(ST(4));
- int srcY = (int)SvIV(ST(5));
- int destW = (int)SvIV(ST(6));
- int destH = (int)SvIV(ST(7));
- int srcW = (int)SvIV(ST(8));
- int srcH = (int)SvIV(ST(9));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- destination = INT2PTR(GD__Image,tmp);
- }
- else
- croak("destination is not of type GD::Image");
- if (sv_derived_from(ST(1), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(1)));
- source = INT2PTR(GD__Image,tmp);
- }
- else
- croak("source is not of type GD::Image");
- #line 736 "GD.xs"
- {
- gdImageCopyResized(destination,source,dstX,dstY,srcX,srcY,destW,destH,srcW,srcH);
- }
- #line 1270 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_char)
- {
- dXSARGS;
- if (items != 6)
- Perl_croak(aTHX_ "Usage: GD::Image::char(image, font, x, y, c, color)");
- {
- GD__Image image;
- GD__Font font;
- int x = (int)SvIV(ST(2));
- int y = (int)SvIV(ST(3));
- char * c = (char *)SvPV(ST(4),PL_na);
- int color = (int)SvIV(ST(5));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- if (sv_derived_from(ST(1), "GD::Font")) {
- IV tmp = SvIV((SV*)SvRV(ST(1)));
- font = INT2PTR(GD__Font,tmp);
- }
- else
- croak("font is not of type GD::Font");
- #line 750 "GD.xs"
- {
- gdImageChar(image,font,x,y,*c,color);
- }
- #line 1305 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_charUp)
- {
- dXSARGS;
- if (items != 6)
- Perl_croak(aTHX_ "Usage: GD::Image::charUp(image, font, x, y, c, color)");
- {
- GD__Image image;
- GD__Font font;
- int x = (int)SvIV(ST(2));
- int y = (int)SvIV(ST(3));
- char * c = (char *)SvPV(ST(4),PL_na);
- int color = (int)SvIV(ST(5));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- if (sv_derived_from(ST(1), "GD::Font")) {
- IV tmp = SvIV((SV*)SvRV(ST(1)));
- font = INT2PTR(GD__Font,tmp);
- }
- else
- croak("font is not of type GD::Font");
- #line 764 "GD.xs"
- {
- gdImageCharUp(image,font,x,y,*c,color);
- }
- #line 1340 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_string)
- {
- dXSARGS;
- if (items != 6)
- Perl_croak(aTHX_ "Usage: GD::Image::string(image, font, x, y, s, color)");
- {
- GD__Image image;
- GD__Font font;
- int x = (int)SvIV(ST(2));
- int y = (int)SvIV(ST(3));
- char * s = (char *)SvPV(ST(4),PL_na);
- int color = (int)SvIV(ST(5));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- if (sv_derived_from(ST(1), "GD::Font")) {
- IV tmp = SvIV((SV*)SvRV(ST(1)));
- font = INT2PTR(GD__Font,tmp);
- }
- else
- croak("font is not of type GD::Font");
- #line 778 "GD.xs"
- {
- gdImageString(image,font,x,y,s,color);
- }
- #line 1375 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Image_stringUp)
- {
- dXSARGS;
- if (items != 6)
- Perl_croak(aTHX_ "Usage: GD::Image::stringUp(image, font, x, y, s, color)");
- {
- GD__Image image;
- GD__Font font;
- int x = (int)SvIV(ST(2));
- int y = (int)SvIV(ST(3));
- char * s = (char *)SvPV(ST(4),PL_na);
- int color = (int)SvIV(ST(5));
- if (sv_derived_from(ST(0), "GD::Image")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- image = INT2PTR(GD__Image,tmp);
- }
- else
- croak("image is not of type GD::Image");
- if (sv_derived_from(ST(1), "GD::Font")) {
- IV tmp = SvIV((SV*)SvRV(ST(1)));
- font = INT2PTR(GD__Font,tmp);
- }
- else
- croak("font is not of type GD::Font");
- #line 792 "GD.xs"
- {
- gdImageStringUp(image,font,x,y,s,color);
- }
- #line 1410 "GD.c"
- }
- XSRETURN_EMPTY;
- }
- XS(XS_GD__Font_Small)
- {
- dXSARGS;
- if (items < 0 || items > 1)
- Perl_croak(aTHX_ "Usage: GD::Font::Small(packname="GD::Font")");
- {
- char * packname;
- GD__Font RETVAL;
- if (items < 1)
- packname = "GD::Font";
- else {
- packname = (char *)SvPV(ST(0),PL_na);
- }
- #line 803 "GD.xs"
- {
- RETVAL = gdFontSmall;
- }
- #line 1433 "GD.c"
- ST(0) = sv_newmortal();
- sv_setref_pv(ST(0), "GD::Font", (void*)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Font_Large)
- {
- dXSARGS;
- if (items < 0 || items > 1)
- Perl_croak(aTHX_ "Usage: GD::Font::Large(packname="GD::Font")");
- {
- char * packname;
- GD__Font RETVAL;
- if (items < 1)
- packname = "GD::Font";
- else {
- packname = (char *)SvPV(ST(0),PL_na);
- }
- #line 814 "GD.xs"
- {
- RETVAL = gdFontLarge;
- }
- #line 1458 "GD.c"
- ST(0) = sv_newmortal();
- sv_setref_pv(ST(0), "GD::Font", (void*)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Font_MediumBold)
- {
- dXSARGS;
- if (items < 0 || items > 1)
- Perl_croak(aTHX_ "Usage: GD::Font::MediumBold(packname="GD::Font")");
- {
- char * packname;
- GD__Font RETVAL;
- if (items < 1)
- packname = "GD::Font";
- else {
- packname = (char *)SvPV(ST(0),PL_na);
- }
- #line 825 "GD.xs"
- {
- RETVAL = gdFontMediumBold;
- }
- #line 1483 "GD.c"
- ST(0) = sv_newmortal();
- sv_setref_pv(ST(0), "GD::Font", (void*)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Font_Tiny)
- {
- dXSARGS;
- if (items < 0 || items > 1)
- Perl_croak(aTHX_ "Usage: GD::Font::Tiny(packname="GD::Font")");
- {
- char * packname;
- GD__Font RETVAL;
- if (items < 1)
- packname = "GD::Font";
- else {
- packname = (char *)SvPV(ST(0),PL_na);
- }
- #line 836 "GD.xs"
- {
- RETVAL = gdFontTiny;
- }
- #line 1508 "GD.c"
- ST(0) = sv_newmortal();
- sv_setref_pv(ST(0), "GD::Font", (void*)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Font_nchars)
- {
- dXSARGS;
- if (items != 1)
- Perl_croak(aTHX_ "Usage: GD::Font::nchars(font)");
- {
- GD__Font font;
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Font")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- font = INT2PTR(GD__Font,tmp);
- }
- else
- croak("font is not of type GD::Font");
- #line 847 "GD.xs"
- {
- RETVAL = font->nchars;
- }
- #line 1535 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Font_offset)
- {
- dXSARGS;
- if (items != 1)
- Perl_croak(aTHX_ "Usage: GD::Font::offset(font)");
- {
- GD__Font font;
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Font")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- font = INT2PTR(GD__Font,tmp);
- }
- else
- croak("font is not of type GD::Font");
- #line 858 "GD.xs"
- {
- RETVAL = font->offset;
- }
- #line 1561 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Font_width)
- {
- dXSARGS;
- if (items != 1)
- Perl_croak(aTHX_ "Usage: GD::Font::width(font)");
- {
- GD__Font font;
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Font")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- font = INT2PTR(GD__Font,tmp);
- }
- else
- croak("font is not of type GD::Font");
- #line 869 "GD.xs"
- {
- RETVAL = font->w;
- }
- #line 1587 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- XS(XS_GD__Font_height)
- {
- dXSARGS;
- if (items != 1)
- Perl_croak(aTHX_ "Usage: GD::Font::height(font)");
- {
- GD__Font font;
- int RETVAL;
- dXSTARG;
- if (sv_derived_from(ST(0), "GD::Font")) {
- IV tmp = SvIV((SV*)SvRV(ST(0)));
- font = INT2PTR(GD__Font,tmp);
- }
- else
- croak("font is not of type GD::Font");
- #line 880 "GD.xs"
- {
- RETVAL = font->h;
- }
- #line 1613 "GD.c"
- XSprePUSH; PUSHi((IV)RETVAL);
- }
- XSRETURN(1);
- }
- #ifdef __cplusplus
- extern "C"
- #endif
- XS(boot_GD)
- {
- dXSARGS;
- char* file = __FILE__;
- XS_VERSION_BOOTCHECK ;
- newXS("GD::constant", XS_GD_constant, file);
- newXSproto("GD::Image::new", XS_GD__Image_new, file, "$;$$");
- newXSproto("GD::Image::_newFromGif", XS_GD__Image__newFromGif, file, "$$");
- newXSproto("GD::Image::_newFromXbm", XS_GD__Image__newFromXbm, file, "$$");
- newXSproto("GD::Image::_newFromGd", XS_GD__Image__newFromGd, file, "$$");
- newXSproto("GD::Image::DESTROY", XS_GD__Image_DESTROY, file, "$");
- newXSproto("GD::Image::gif", XS_GD__Image_gif, file, "$");
- newXSproto("GD::Image::gd", XS_GD__Image_gd, file, "$");
- newXSproto("GD::Image::transparent", XS_GD__Image_transparent, file, "$;$");
- newXSproto("GD::Image::getBounds", XS_GD__Image_getBounds, file, "$");
- newXSproto("GD::Image::rgb", XS_GD__Image_rgb, file, "$$");
- newXSproto("GD::Image::boundsSafe", XS_GD__Image_boundsSafe, file, "$$$");
- newXSproto("GD::Image::getPixel", XS_GD__Image_getPixel, file, "$$$");
- newXSproto("GD::Image::setPixel", XS_GD__Image_setPixel, file, "$$$");
- newXSproto("GD::Image::line", XS_GD__Image_line, file, "$$$$$$");
- newXSproto("GD::Image::dashedLine", XS_GD__Image_dashedLine, file, "$$$$$$");
- newXSproto("GD::Image::openPolygon", XS_GD__Image_openPolygon, file, "$$$");
- newXSproto("GD::Image::filledPolygon", XS_GD__Image_filledPolygon, file, "$$$");
- newXSproto("GD::Image::rectangle", XS_GD__Image_rectangle, file, "$$$$$$");
- newXSproto("GD::Image::filledRectangle", XS_GD__Image_filledRectangle, file, "$$$$$$");
- newXSproto("GD::Image::arc", XS_GD__Image_arc, file, "$$$$$$$$");
- newXSproto("GD::Image::fillToBorder", XS_GD__Image_fillToBorder, file, "$$$$$");
- newXSproto("GD::Image::fill", XS_GD__Image_fill, file, "$$$$");
- newXSproto("GD::Image::setBrush", XS_GD__Image_setBrush, file, "$$");
- newXSproto("GD::Image::setTile", XS_GD__Image_setTile, file, "$$");
- newXSproto("GD::Image::setStyle", XS_GD__Image_setStyle, file, "$;$");
- newXSproto("GD::Image::colorAllocate", XS_GD__Image_colorAllocate, file, "$$$$");
- newXSproto("GD::Image::colorClosest", XS_GD__Image_colorClosest, file, "$$$$");
- newXSproto("GD::Image::colorExact", XS_GD__Image_colorExact, file, "$$$$");
- newXSproto("GD::Image::colorsTotal", XS_GD__Image_colorsTotal, file, "$");
- newXSproto("GD::Image::interlaced", XS_GD__Image_interlaced, file, "$;$");
- newXSproto("GD::Image::colorDeallocate", XS_GD__Image_colorDeallocate, file, "$$");
- newXSproto("GD::Image::copy", XS_GD__Image_copy, file, "$$$$$$$$");
- newXSproto("GD::Image::copyResized", XS_GD__Image_copyResized, file, "$$$$$$$$$$");
- newXSproto("GD::Image::char", XS_GD__Image_char, file, "$$$$$$");
- newXSproto("GD::Image::charUp", XS_GD__Image_charUp, file, "$$$$$$");
- newXSproto("GD::Image::string", XS_GD__Image_string, file, "$$$$$$");
- newXSproto("GD::Image::stringUp", XS_GD__Image_stringUp, file, "$$$$$$");
- newXSproto("GD::Font::Small", XS_GD__Font_Small, file, "$");
- newXSproto("GD::Font::Large", XS_GD__Font_Large, file, "$");
- newXSproto("GD::Font::MediumBold", XS_GD__Font_MediumBold, file, "$");
- newXSproto("GD::Font::Tiny", XS_GD__Font_Tiny, file, "$");
- newXSproto("GD::Font::nchars", XS_GD__Font_nchars, file, "$");
- newXSproto("GD::Font::offset", XS_GD__Font_offset, file, "$");
- newXSproto("GD::Font::width", XS_GD__Font_width, file, "$");
- newXSproto("GD::Font::height", XS_GD__Font_height, file, "$");
- XSRETURN_YES;
- }