不好意思,昨晚写错了,应该是这样的(已在原帖修改)
当然要写成函数了。应该是2的n次方n为0-7(即1, 2, 4, 8, 16, 32, 64, 128),当然Delphi习惯用十六进制表示的
function GetStatus: string;
var
NewTemp: Integer;
begin
Newtemp:=lobyte(MP4_ClientIsSupport());
//如果是低八位的话,不用lobyte也行
if Newtemp and 1 = 1 then
Result := ' SUPPORT_DDRAW'
else
Result := ' Not SUPPORT_DDRAW';
if Newtemp and 2 = 2 then
Result := ' SUPPORT_BLT'
else
Result := ' Not SUPPORT_BLT';
if Newtemp and 4 = 4 then
Result := ' SUPPORT_BLTFOURCC'
else
Result := 'Not SUPPORT_BLTFOURCC';
if Newtemp and 1288 = 128 then
Result := 'SUPPORT_CPU'
else
Result := 'Not SUPPORT_CPU';
end;
Label1.Caption := GetStatus;