Hello,
I've a problem with osgLua.
Is it always maintained ?
For the moment, I just want to test the osgLua examples :
osg::Group* group = new osg::Group;
osg::Group* root = new osg::Group;
try {
group->addChild(root);
osg::ref_ptr<osgLua::Script> script = new osgLua::Script();
script->enable("osg");
script->set(root, "root");
script->loadFile("/home/julien/workspace/TestLua/src/test.lua");
} catch (osgLua::Exception & e) {
std::cout << e.what() << std::endl;
}
and the test.lua provided with osgLua :
local root2 = osg.Group()
local geode = osg.Geode()
local shape = osg.ShapeDrawable()
shape:setShape( osg.Sphere(osg.Vec3(0,0,0),15) )
geode:addDrawable(shape)
root:addChild(geode)
-- we will now load osgText from the script
osgLua.loadWrapper("osgText")
text = osgText.Text()
text:setCharacterSize(4)
text:setPosition(osg.Vec3(0,0,18))
text:setAxisAlignment(osgText.Text.AxisAlignment.SCREEN)
text:setAlignment(osgText.Text.AlignmentType.CENTER_BASE_LINE)
text:setText("Hi all from osgLua!")
text:setColor(osg.Vec4(0.9,0.8,0.2,1.0))
geode:addDrawable(text)
The result :
/TestLua/src/test.lua:9: [/home/julien/OSG/osgLua/src/osgLua/Value.cpp:260]
ype `PN3osg5GroupE' is declared but not defined
I have liked all the osg and osgLua libraries, I don't understand...
Someone has an idea ? Thank you
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org