How to call the native code in Live Code
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
How to call the native code in Live Code
How to call the native code in Live Code
I wanna write an app which can run on both Mac OS and Window, but it may dependence native code , such as in Java we can call method in ".so" or ".dll" file by the JNI. Can Live Code call the native code as Java ?
Thanks
I wanna write an app which can run on both Mac OS and Window, but it may dependence native code , such as in Java we can call method in ".so" or ".dll" file by the JNI. Can Live Code call the native code as Java ?
Thanks
Re: How to call the native code in Live Code
Hi Devil (? come on
)
1. welcome to the forum!
2. Sorry, not sure what you are talking about?
What "native" code?
Best
Klaus

1. welcome to the forum!

2. Sorry, not sure what you are talking about?
What "native" code?
Best
Klaus
Re: How to call the native code in Live Code
Thanks for your reply.Klaus wrote:Hi Devil (? come on)
1. welcome to the forum!![]()
2. Sorry, not sure what you are talking about?
What "native" code?
Best
Klaus
sorry for my poor English.
Do you know JNI ? Java Language can call C\C++ function by JNI. So my Question is Can Live Code call C\C++ function, I've try my best to search it in the document, but failed at last.
-
- Posts: 86
- Joined: Tue May 15, 2012 5:56 pm
Re: How to call the native code in Live Code
You can take your C/C++ code and turn it into an external for LiveCode as I don't know of a way to directly interact with C/C++ code from within LiveCode. If you want to check out information on making an external then take a look at http://livecode.com/developers/guides/d ... externals/ or you can look at this entry in the LiveCode wiki http://livecode.wikia.com/wiki/Working_with_DLL
Re: How to call the native code in Live Code
CenturyMan1979 wrote:You can take your C/C++ code and turn it into an external for LiveCode as I don't know of a way to directly interact with C/C++ code from within LiveCode. If you want to check out information on making an external then take a look at
Thanks , I'll try it.
Have a nice day!
Re: How to call the native code in Live Code
Devil.
I would be interested to know what reason you might have to want to do this. Is it for increased speed? Or access to low-level machine functionality not available "natively" in LC?
Know that LC has the ability to maintain library functionality is several ways, and these do not necessarily require plug-ins.
Craig Newman
I would be interested to know what reason you might have to want to do this. Is it for increased speed? Or access to low-level machine functionality not available "natively" in LC?
Know that LC has the ability to maintain library functionality is several ways, and these do not necessarily require plug-ins.
Craig Newman
Re: How to call the native code in Live Code
Hi Devil,
not sure whether could fit your needs but maybe you want to take a look at the "do" in the dictionary, it works with "active scripting" languages such as VBScript.
not sure whether could fit your needs but maybe you want to take a look at the "do" in the dictionary, it works with "active scripting" languages such as VBScript.
do statementList [as alternateLanguageName] [in caller]
statementList - A LiveCode statement, a container with one or more statements, or a string that evaluates to a statement.
alternateLanguageName - On Mac OS and OS X systems, the alternateLanguageName is a script language (such as AppleScript) supported under the Open Scripting Architecture. On Windows systems, the alternateLanguageName is an "active scripting" language (such as VBScript) supported by the Windows Scripting Host. The available languages are returned by the alternateLanguages function. If you specify an alternateLanguageName, the statementList must be written in the specified language.
Re: How to call the native code in Live Code
Hi, dunbarx,dunbarx wrote:Devil.
I would be interested to know what reason you might have to want to do this. Is it for increased speed? Or access to low-level machine functionality not available "natively" in LC?
Know that LC has the ability to maintain library functionality is several ways, and these do not necessarily require plug-ins.
Craig Newman
Thanks for your reply.
My team has a c library for "Image Processing", we want to the library work with LC both on Windows and Mac.
Re: How to call the native code in Live Code
Mag wrote:Hi Devil,
not sure whether could fit your needs but maybe you want to take a look at the "do" in the dictionary, it works with "active scripting" languages such as VBScript.
do statementList [as alternateLanguageName] [in caller]
statementList - A LiveCode statement, a container with one or more statements, or a string that evaluates to a statement.
alternateLanguageName - On Mac OS and OS X systems, the alternateLanguageName is a script language (such as AppleScript) supported under the Open Scripting Architecture. On Windows systems, the alternateLanguageName is an "active scripting" language (such as VBScript) supported by the Windows Scripting Host. The available languages are returned by the alternateLanguages function. If you specify an alternateLanguageName, the statementList must be written in the specified language.
Thanks for your help , I'll have a try.