OSDN Git Service
(root)
/
sample-delphi
/
sample-DELPHI.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2576918
)
8bit 側の変更を完了
other
author
yamat0jp
<yamat0jp@yahoo.co.jp>
Fri, 18 May 2018 09:24:03 +0000
(18:24 +0900)
committer
yamat0jp
<yamat0jp@yahoo.co.jp>
Fri, 18 May 2018 09:24:03 +0000
(18:24 +0900)
effect.pas
patch
|
blob
|
history
diff --git
a/effect.pas
b/effect.pas
index
3b9e699
..
17792d1
100644
(file)
--- a/
effect.pas
+++ b/
effect.pas
@@
-24,9
+24,10
@@
begin
result := 0;
try
s := TMemoryStream.Create;
- s.ReadBuffer(sp.pWav^, sp.sizeOfData);
+ s.Write(sp.pWav^, sp.sizeOfData);
+ s.Position := 0;
+ s.Read(Pointer(pCpy)^,sp.sizeOfData);
pMem := sp.pWav;
- pCpy := s.Memory;
i := sp.posOfData;
k := 8 * sp.sizeOfData / sp.bitsPerSample;
while i < k do
@@
-39,6
+40,8
@@
begin
except
result := -1;
end;
+ s.Free;
+ Finalize(pCpy);
end;
function effect16BitWav(const sp: SpParam): integer;