Scenenode flip

actorid
Jason Hooks 13 years ago
parent a0947cd432
commit 4dc59dfbdd

@ -8,7 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwrender/cellimp.hpp"
namespace MWClass
{

@ -8,7 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"

@ -8,7 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"

@ -8,7 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"

@ -8,7 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"

@ -7,8 +7,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwrender/cellimp.hpp"
namespace MWClass
{
void Container::insertObjectRendering (const MWWorld::Ptr& ptr, MWRender::RenderingInterface& renderingInterface) const

@ -9,7 +9,6 @@
#include "../mwworld/actiontalk.hpp"
#include "../mwworld/environment.hpp"
#include "../mwrender/cellimp.hpp"
#include "../mwmechanics/mechanicsmanager.hpp"
@ -25,6 +24,7 @@ namespace MWClass
void Creature::insertObjectRendering (const MWWorld::Ptr& ptr, MWRender::RenderingInterface& renderingInterface) const
{
/*
ESMS::LiveCellRef<ESM::Creature, MWWorld::RefData> *ref =
ptr.get<ESM::Creature>();
@ -36,11 +36,12 @@ namespace MWClass
MWRender::Creatures creatures = renderingInterface.getCreatures();
//creatures.insertBegin(ptr, ptr.getRefData().isEnabled(), false);
//creatures.insertMesh(ptr, "meshes\\" + model);
}
}*/
}
void Creature::insertObject(const MWWorld::Ptr& ptr, MWWorld::PhysicsSystem& physics, MWWorld::Environment& environment) const
{
/*
ESMS::LiveCellRef<ESM::Creature, MWWorld::RefData> *ref =
ptr.get<ESM::Creature>();
@ -49,7 +50,7 @@ namespace MWClass
assert (ref->base != NULL);
if(!model.empty()){
physics.insertActorPhysics(ptr);
}
}*/
}

@ -12,7 +12,6 @@
#include "../mwworld/environment.hpp"
#include "../mwworld/world.hpp"
#include "../mwrender/cellimp.hpp"
#include "../mwrender/objects.hpp"
#include <iostream>

@ -8,7 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"

@ -10,8 +10,6 @@
#include "../mwworld/nullaction.hpp"
#include "../mwworld/environment.hpp"
#include "../mwrender/cellimp.hpp"
#include "../mwsound/soundmanager.hpp"
#include "containerutil.hpp"

@ -8,7 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"
namespace MWClass

@ -8,8 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"
namespace MWClass

@ -11,8 +11,6 @@
#include "../mwworld/environment.hpp"
#include "../mwworld/world.hpp"
#include "../mwrender/cellimp.hpp"
#include "../mwmechanics/mechanicsmanager.hpp"
#include <OgreSceneNode.h>
@ -34,6 +32,7 @@ namespace MWClass
void Npc::insertObjectRendering (const MWWorld::Ptr& ptr, MWRender::RenderingInterface& renderingInterface) const
{
/*
ESMS::LiveCellRef<ESM::NPC, MWWorld::RefData> *ref =
ptr.get<ESM::NPC>();
@ -45,11 +44,13 @@ namespace MWClass
MWRender::Npcs npcs = renderingInterface.getNPCs();
//npcs.insertBegin(ptr, ptr.getRefData().isEnabled(), false);
//npcs.insertMesh(ptr, "meshes\\" + model);
}
}*/
}
void Npc::insertObject(const MWWorld::Ptr& ptr, MWWorld::PhysicsSystem& physics, MWWorld::Environment& environment) const
{
/*
ESMS::LiveCellRef<ESM::NPC, MWWorld::RefData> *ref =
ptr.get<ESM::NPC>();
@ -58,7 +59,7 @@ namespace MWClass
assert (ref->base != NULL);
if(!model.empty()){
physics.insertActorPhysics(ptr);
}
}*/
}

@ -8,7 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"

@ -8,8 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"
namespace MWClass

@ -8,7 +8,6 @@
#include "../mwworld/ptr.hpp"
#include "../mwworld/actiontake.hpp"
#include "../mwrender/cellimp.hpp"
#include "containerutil.hpp"

@ -23,8 +23,11 @@ bool Objects::lightOutQuadInLin = false;
int Objects::uniqueID = 0;
void Objects::setMwRoot(Ogre::SceneNode* root){
mwRoot = root;
}
void Objects::insertBegin (const MWWorld::Ptr& ptr, bool enabled, bool static_){
Ogre::SceneNode* root = mRend.getScene()->getRootSceneNode();
Ogre::SceneNode* root = mwRoot;
Ogre::SceneNode* cellnode;
if(mCellSceneNodes.find(ptr.getCell()) == mCellSceneNodes.end())
{

@ -13,6 +13,7 @@ class Objects{
OEngine::Render::OgreRenderer &mRend;
std::map<MWWorld::Ptr::CellStore *, Ogre::SceneNode *> mCellSceneNodes;
std::map<MWWorld::Ptr::CellStore *, Ogre::StaticGeometry*> mSG;
Ogre::SceneNode* mwRoot;
bool isStatic;
static int uniqueID;
static bool lightConst;
@ -38,6 +39,7 @@ public:
void deleteObject (const std::string& handle);
void removeCell(const MWWorld::Ptr& ptr);
void buildStaticGeometry(ESMS::CellStore<MWWorld::RefData> &cell);
void setMwRoot(Ogre::SceneNode* root);
/// insert a light related to the most recent insertBegin call.

@ -45,6 +45,7 @@ RenderingManager::RenderingManager (OEngine::Render::OgreRenderer& _rend, const
SceneNode *rt = rend.getScene()->getRootSceneNode();
mwRoot = rt->createChildSceneNode();
mwRoot->pitch(Degree(-90));
objects.setMwRoot(mwRoot);
//used to obtain ingame information of ogre objects (which are faced or selected)
mRaySceneQuery = rend.getScene()->createRayQuery(Ray());
@ -220,4 +221,6 @@ void RenderingManager::toggleLight()
setAmbientMode();
}
}

Loading…
Cancel
Save