Z
zxw
Unregistered / Unconfirmed
GUEST, unregistred user!
unit Unity1;
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs, DXSounds, Wave, DirectX, mmsystem;
type
TForm1 = class(TForm)
procedure FormCreate(Sender: TObject);
private
public
end;
var
Form1: TForm1;
Capture:IDirectSoundCapture;
DSCCaps:TDSCCaps;
HResult:Cardinal;
implementation
{$R *.DFM}
procedure TForm1.FormCreate(Sender: TObject);
var i:integer;
begin
DirectSoundCaptureCreate(nil,Capture,nil);
DSCCaps.dwSize:=SizeOf(TDSCCaps)
HResult:=Capture.GetCaps(DSCCaps);
if HResult=0 then
case DSCCaps.dwFormats of
.....
end;
end;
end.
背景:使用了从http://ils.wzptt.gx.cn/archie/directx.htm下载的
DelphiX.
问题:IDirectSoundCapture.GetCaps方法返回的结果在DSCCaps结构中,
DSCCaps结构的dwFlags成员表明了Drivers的可用性,根据MicroSoft在
DirectX6.1SDK中的定义,该成员的值只能是0(可用)或32(模拟可用),但
在我这儿返回个64,为么?哦?
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs, DXSounds, Wave, DirectX, mmsystem;
type
TForm1 = class(TForm)
procedure FormCreate(Sender: TObject);
private
public
end;
var
Form1: TForm1;
Capture:IDirectSoundCapture;
DSCCaps:TDSCCaps;
HResult:Cardinal;
implementation
{$R *.DFM}
procedure TForm1.FormCreate(Sender: TObject);
var i:integer;
begin
DirectSoundCaptureCreate(nil,Capture,nil);
DSCCaps.dwSize:=SizeOf(TDSCCaps)
HResult:=Capture.GetCaps(DSCCaps);
if HResult=0 then
case DSCCaps.dwFormats of
.....
end;
end;
end.
背景:使用了从http://ils.wzptt.gx.cn/archie/directx.htm下载的
DelphiX.
问题:IDirectSoundCapture.GetCaps方法返回的结果在DSCCaps结构中,
DSCCaps结构的dwFlags成员表明了Drivers的可用性,根据MicroSoft在
DirectX6.1SDK中的定义,该成员的值只能是0(可用)或32(模拟可用),但
在我这儿返回个64,为么?哦?