Board index » delphi » Calling 'C' DLL's from Delphi 2.0
Mark Harrington
![]() Delphi Developer |
Mon, 16 Aug 1999 03:00:00 GMT
Calling 'C' DLL's from Delphi 2.0I posted to this newsgroup about two weeks ago with this query, thanks To refresh your memory, I am trying to call the following function: void nspdRealFft ( double * samples, int order, int flags) In Delphi, the function call is declared as: procedure nspdRealFft (var s: pointer; o, f : integer); I kept getting Access violation exceptions, or other run time errors. I compared, using Turbo De{*word*81} (TD32), the calls for the function from For a call from the C++ program, the stack is 0000 0001 - the value of the 'flags' parameter For a call from the Delphi program, the stack is 0000 0001 - the value of the 'flags' parameter This was using the delphi program fragment : type procedure nspdRealFft (var s: pointer; o, f : integer); procedure TForm1.Button1Click(Sender: TObject); As you can see, the parameters passed on the stack are in the correct What happens now is that the Delphi program creates another Access I am now uncertain as to how I am going to proceed from here. Any sort of help is more than welcome. If anyone wants a copy of my Thanks in advance, Mark Harrington To email me, please remove the _SPAM_ME_NOT_ field from my email address |