Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Simple C++ bindings for Lua
C++ C Lua
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
Test
.gitignore
LICENSE
README.md
lcbBaseObject.h
lcbBridgeConfig.h
lcbException.h
lcbHybridObject.h
lcbHybridObjectWithProperties.h
lcbRawObject.h
lcbRawObjectWithProperties.h
lcbTypeChecks.h

README.md

LuaCppBridge51 is a library to expose C++ classes to Lua. You pick a class from the library to derive from, add the desired methods, properties, etc and register it into Lua. It is a very simple wrapper that does not aim to expose already existing C++ classes. There are lots of libraries for that (Simple Lua Binder, LuaBind, OOLua, etc).

LuaCppBridge51 builds on ideas from binding classes using Lunar and Lua Technical Note 5. It builds on Lunar, adding the following:

  • allows you to define properties, by means of getter/setter methods in C++.
  • retrieve Lua instances from C++ callbacks

The following were already present in Lunar:

  • add new class methods from Lua
  • simple inheritance (make a C++ class inherit from a "class" in Lua, or viceversa)

More detailed documentation is available on the wiki

Something went wrong with that request. Please try again.