OGRE小记

1,entity是没有getPosition的
2,node的默认position是原点
3,材质脚本中定义的程序段中的source文件名后缀必须与定义的shader文件类型匹配。
如:
vertex_program Ogre/CelShadingVP1 hlsl
{
    source Example_CelShading1.hlsl
    entry_point main_vp
    target vs_2_0

注意target是hlsl中独占,cg中是profile,且参数不同
4,Plugin_CgProgramManager_d.dll 插件一定要有cg.dll配合
5,OGRE不支持的中文路径用下面解决:
setlocale(LC_ALL, "chinese-simplified"); 
记得读取完资源要还原
6,    Ogre::ResourceGroupManager::getSingleton().initialiseAllResourceGroups()一定要在rendersystem初始化完毕才能调用。也就是在root的createRenderWindow 之后
7,想要你的OIS中的mouse何keboard响应你得记得在frameStarted 中每次去capture;
记得在            
mKeyboard = static_cast<OIS::Keyboard*>(mInputManager->createInputObject(OIS::OISKeyboard, true));
mMouse = static_cast<OIS::Mouse*>(mInputManager->createInputObject(OIS::OISMouse, true));
之后
mMouse->setEventCallback(this);
mKeyboard->setEventCallback(this); 
posted on 2011-02-24 17:03  minggoddess  阅读(381)  评论(0编辑  收藏  举报