小弟在C++下有一个数据结构struct potrace_bitmapindex_s {
int fillcolor; //底色,也是填充色
  int w, h;              /* width and height, in pixels */
  unsigned char *map;     /* raw data, w*h BYTE */
  int *Pal; //索引表的指针
};想转化为Delphi下对应的数据结构,大家能不能帮瞎忙,另外问一下,有没有什么C++与Delphi数据项对应关系的文章?delphic++struct

解决方案 »

  1.   

    Delphi 与 C/C++ 数据类型对照表
    http://www.cnblogs.com/del/archive/2007/12/03/981563.html
      

  2.   

    porrace_bitmapindex_s = record
        fillcolor: integer;
        w, h: integer;
        map: uchar;
        pal: pinteger;
      end;
      

  3.   

    porrace_bitmapindex_s = record
        fillcolor: integer;
        w, h: integer;
        map: PUCHAR;
        pal: PInteger;
      end;
      

  4.   


    struct potrace_bitmapindex_s {
        int fillcolor;    //底色,也是填充色
      int w, h;              /* width and height, in pixels */
      unsigned char *map;     /* raw data, w*h BYTE */
      int *Pal;        //索引表的指针
    };
    type  
    potrace_bitmapindex_s=record
    fillcolor:integer;
    w:integer;
    h:integer;
    map:pchar;
    Pal:Pinteger;
    end;