Added support for getting Vec* and Matrix objects from Lua stack and assigning them as OSG object properties.

This commit is contained in:
Robert Osfield
2013-09-27 13:04:04 +00:00
parent 43cb1b3a41
commit ff925f1d86
3 changed files with 224 additions and 42 deletions

View File

@@ -428,6 +428,9 @@ int main(int argc, char** argv)
osg::Vec3f pos(1.5,3.0,4.5);
presentation->setProperty("position",pos);
osg::Vec2f texcoord(0.5f,0.20f);
presentation->setProperty("texcoord",texcoord);
osg::ref_ptr<osg::ScriptEngine> luaScriptEngine = osgDB::readFile<osg::ScriptEngine>("ScriptEngine.lua");
if (luaScriptEngine.valid())
{