看一下gd.h里面有没有定义这个函数吧,最近GD好象经常变的。

解决方案 »

  1.   

    gdImagePtr gdImageCreateTrueColor (int sx, int sy)
    {
        int i;
        gdImagePtr im;
        im = (gdImage *) gdMalloc(sizeof(gdImage));
        memset(im, 0, sizeof(gdImage));
        im->tpixels = (int **) safe_emalloc(sizeof(int *), sy, 0);
        im->AA_opacity = (unsigned char **) safe_emalloc(sizeof(unsigned char *), sy, 0);
        im->polyInts = 0;
        im->polyAllocated = 0;
        im->brush = 0;
        im->tile = 0;
        im->style = 0;
        for (i = 0; i < sy; i++) {
            im->tpixels[i] = (int *) gdCalloc(sx, sizeof(int));
            im->AA_opacity[i] = (unsigned char *) gdCalloc(sx, sizeof(unsigned char));
        }
        im->sx = sx;
        im->sy = sy;
        im->transparent = (-1);
        im->interlace = 0;
        im->trueColor = 1;
        /* 2.0.2: alpha blending is now on by default, and saving of alpha is
         * off by default. This allows font antialiasing to work as expected
         * on the first try in JPEGs -- quite important -- and also allows
         * for smaller PNGs when saving of alpha channel is not really
         * desired, which it usually isn't!
         */
        im->saveAlphaFlag = 0;
        im->alphaBlendingFlag = 1;
        im->thick = 1;
        im->AA = 0;
        im->AA_polygon = 0;
        im->cx1 = 0;
        im->cy1 = 0;
        im->cx2 = im->sx - 1;
        im->cy2 = im->sy - 1;
        return im;
    }
      

  2.   

    gd.h里面定义了gdImageCreateTrueColor()函数了...
      

  3.   

    linux环境下得,那儿有.dll啊?