又一个VC改DElphi的问题! ( 积分: 30 )

  • 主题发起人 主题发起人 xiaohedou
  • 开始时间 开始时间
X

xiaohedou

Unregistered / Unconfirmed
GUEST, unregistred user!
VC这样的结构怎样改为delphi?
typedef struct tagPROGRAM_TABLE
{
unsigned short//类型? unProgramNo;
unsigned short ucNumVideoStream:4;
unsigned short ucNumAudioStream:6;
unsigned short ucNumSubTitle:6;
unsigned int //类型? unMAPPID:13;
float //类型? unPCRPID:13;
unsigned int ucVerNum:6;
struct tagPROGRAM_TABLE *pNext;
//这里不知怎样做?
}PROGRAM_TABLE,far *LP_PROGRAM_TABLE;
 
VC这样的结构怎样改为delphi?
typedef struct tagPROGRAM_TABLE
{
unsigned short//类型? unProgramNo;
unsigned short ucNumVideoStream:4;
unsigned short ucNumAudioStream:6;
unsigned short ucNumSubTitle:6;
unsigned int //类型? unMAPPID:13;
float //类型? unPCRPID:13;
unsigned int ucVerNum:6;
struct tagPROGRAM_TABLE *pNext;
//这里不知怎样做?
}PROGRAM_TABLE,far *LP_PROGRAM_TABLE;
 
unsigned short 是无符号的16位整型
unsigned int 是无符号的整型
float 是双精度(浮点)
但是我C学的菜了点,不知道怎么改成 object pascal
 
对应
byte
word
real
type
pNext=^tagPROGRAM_TABLE;
tagPROGRAM_TABLE = record
...
...
Next:pNext;
//这样就行了,
end;
...
 
自己搞定
 
来如风,谢谢。你多次帮助!同时也感谢wjames的支持
 
type pNext=^tagPROGRAM_TABLE;
tagPROGRAM_TABLE = record
...
Next:pNext;
//这样就行了,
end;

不行!tagPROGRAM_TABLE没定义啊!
 
自己改了,用;两个结构体过渡
 
多人接受答案了。
 
后退
顶部