I have q question about using ruby/dl for win32 dll

I’d like to access some function in win32 dll

Sample dll’s source is like the belows.

– part of source –

#define TESTDLL extern “C”

TESTDLL float _stdcall AddNum(float a, int b);
TESTDLL int _stdcall MulNum(int a, int b);

Firstly, I succeed accessing functions with “Win32API”

But, I met the limitation of accessing ‘float’ or ‘string’ variable,
so I’d like to access functions using "ruby/dl’

Please let me know the ways and samples.

Thank you for reading my questions.

Then, Thank you in advance.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs