Monday, March 28, 2011

Lua COM Programming

Anyone know of any examples that shows COM programming via Lua? Could require a library.

I need to write some external scripts for Photoshop, so wondering if it's possible with Lua.

From stackoverflow
  • Have a look at Lua for Windows. It contains LuaCOM. I haven't tried it myself, though.

  • As gimpf said, take a look at LuaCOM. You can either get it from its official site, which is the latest version (1.4). Unzip it somewhere and take a look at the folder "Demo", which includes examples for:

    • ADO
    • Powerpoint
    • SAPI (Speech API)
    • WMI

    They are more like test cases than examples but you can get the idea.

  • You can roll your own system using CInvoke and some custom C/C++ code combined with Lua meta-tables.

    http://www.nongnu.org/cinvoke/

    From experience though I can't recommend this, it is pretty complicated and requires a lot of effort to get it right and make it bulletproof.

0 comments:

Post a Comment