GLBasic forum

Main forum => GLBasic - en => Topic started by: JohnnyB on 2019-May-19

Title: Can you use a DLL written in Fortran (or other languages than C/C++)?
Post by: JohnnyB on 2019-May-19
I am not sure at the moment how this "INLINE" stuff really works.
Title: Re: Can you use a DLL written in Fortran (or other languages than C/C++)?
Post by: Snoopy on 2019-May-19
(https://memegenerator.net/img/instances/43908614/can-you-do-it-yes-you-can.jpg)
Title: Re: Can you use a DLL written in Fortran (or other languages than C/C++)?
Post by: JohnnyB on 2019-May-19
great!
Title: Re: Can you use a DLL written in Fortran (or other languages than C/C++)?
Post by: dreamerman on 2019-May-20
It doesn't matter what programming language was used to make dll file, only what matters it that it should export functions with 'stdcall' calling convention, also 'cdecl' is supported without problems. (info about calling conventions: https://en.wikipedia.org/wiki/X86_calling_conventions) You can use DECLARE keyword to make direct use of dll functions in your code: http://www.glbasic.com/xmlhelp.php?lang=en&id=191&action=view
If you encounter problem with some specific dll and function just ask. GLB code is translated to c++, then compiled (so it doesn't have limitations present on other such tools), you can write direct c++ code to make use of some specific things not available directly on GLB itself ;)
Title: Re: Can you use a DLL written in Fortran (or other languages than C/C++)?
Post by: JohnnyB on 2019-May-20
That's good. I will use C++ or Fortran for complex calculations for my AI.
Title: Re: Can you use a DLL written in Fortran (or other languages than C/C++)?
Post by: Snoopy on 2019-May-28
Woah!, I just realized that it's my message with Obama's "Can you do it? ... Yes, you can!!!" that made me go from "Mr. Polyvector" to "Dr. Type" :D
It's cool!  :good: