J
jayxsjf
Unregistered / Unconfirmed
GUEST, unregistred user!
我按照此结构来读取U律WAVE文件头
TWavHeader = record //定义一个Wav文件头格式
rId : longint;
rLen : longint;
wId : longint;
fId : longint;
fLen : longint;
wFormatTag : word;
nChannels : word;
nSamplesPerSec : longint;
nAvgBytesPerSec : longint;
nBlockAlign : word;
wBitsPerSample : word;
cbSize: WORD;
fact: LongInt;
unknown1 :WORD; //=4;
unknown2: WORD;
datasize_raw : longint;
dId : longint;
wSampleLength : longint;
end;
但是读出来的总少读了2个字节,我写了一段代码来写个新文件头,结果写入了60个字节,但是这个结构就是58个字节呀,也就是多写了2个字节。真是郁闷,有谁知道是什么原因呀,先谢谢了
TWavHeader = record //定义一个Wav文件头格式
rId : longint;
rLen : longint;
wId : longint;
fId : longint;
fLen : longint;
wFormatTag : word;
nChannels : word;
nSamplesPerSec : longint;
nAvgBytesPerSec : longint;
nBlockAlign : word;
wBitsPerSample : word;
cbSize: WORD;
fact: LongInt;
unknown1 :WORD; //=4;
unknown2: WORD;
datasize_raw : longint;
dId : longint;
wSampleLength : longint;
end;
但是读出来的总少读了2个字节,我写了一段代码来写个新文件头,结果写入了60个字节,但是这个结构就是58个字节呀,也就是多写了2个字节。真是郁闷,有谁知道是什么原因呀,先谢谢了