Lazarus
Installation => Windows (32/64) => Topic started by: tech-pro on November 11, 2007, 02:32:13 pm
-
My program is trying to make use of a third party Windows DLL that interfaces with the sound card and returns arrays of FFT data. I am unable to change the way the DLL works.
I have a Delphi example of how to use this DLL. When data is ready, the DLL sends a Windows message: MSG_DATARDY = WM_USER+1000;
In the Delphi example, the main form contains:
procedure FFTDataReady(var msg: TMessage); message MSG_DATARDY;
and there is a procedure FFTDataReady that then grabs the data and processes it. This procedure is never being called. Presumably there is a difference in the way Lazarus apps respond to messages. Can anyone help me out with this?
-
http://wiki.lazarus.freepascal.org/LCL_Defines#Win32_defines
You need to recompile LCL with PassWin32MessagesToLCL
-
Thank you. It is recompiling as I type.
Since this is not enabled by default, is there a downside to this (bearing in mind this setting will apply to every program I compile using Lazarus)?
It worked - once I did a clean build of LCL.
-
Yes there is a downside: it only works on windows
-
So does the DLL, so that is no big deal.