diff --git a/apps/openmw/CMakeLists.txt b/apps/openmw/CMakeLists.txt index 6322c4080..675c377a0 100644 --- a/apps/openmw/CMakeLists.txt +++ b/apps/openmw/CMakeLists.txt @@ -16,7 +16,7 @@ set(GAME_HEADER source_group(game FILES ${GAME} ${GAME_HEADER}) set(GAMEREND - mwrender/render_manager.cpp + mwrender/rendering_manager.cpp mwrender/mwscene.cpp mwrender/cellimp.cpp mwrender/interior.cpp @@ -25,7 +25,7 @@ set(GAMEREND mwrender/player.cpp ) set(GAMEREND_HEADER - mwrender/render_manager.hpp + mwrender/rendering_manager.hpp mwrender/cell.hpp mwrender/cellimp.hpp mwrender/mwscene.hpp diff --git a/apps/openmw/mwrender/render_manager.cpp b/apps/openmw/mwrender/render_manager.cpp deleted file mode 100644 index 4212c0cec..000000000 --- a/apps/openmw/mwrender/render_manager.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "render_manager.hpp" diff --git a/apps/openmw/mwrender/render_manager.hpp b/apps/openmw/mwrender/render_manager.hpp deleted file mode 100644 index 67b2fb93f..000000000 --- a/apps/openmw/mwrender/render_manager.hpp +++ /dev/null @@ -1,9 +0,0 @@ -#ifndef _GAME_RENDER_MANAGER_H -#define _GAME_RENDER_MANAGER_H - -namespace MWRender -{ - -} - -#endif diff --git a/apps/openmw/mwrender/rendering_manager.cpp b/apps/openmw/mwrender/rendering_manager.cpp new file mode 100644 index 000000000..66d178606 --- /dev/null +++ b/apps/openmw/mwrender/rendering_manager.cpp @@ -0,0 +1 @@ +#include "rendering_manager.hpp" diff --git a/apps/openmw/mwrender/rendering_manager.hpp b/apps/openmw/mwrender/rendering_manager.hpp new file mode 100644 index 000000000..19ea73f5c --- /dev/null +++ b/apps/openmw/mwrender/rendering_manager.hpp @@ -0,0 +1,43 @@ +#ifndef _GAME_RENDERING_MANAGER_H +#define _GAME_RENDERING_MANAGER_H + +#include "../mwworld/ptr.hpp" +#include +#include + +namespace MWRender +{ + +class RenderingManager { + public: + + void removeCell (MWWorld::Ptr::CellStore *store); // TODO do we want this? + + void addObject (const MWWorld::Ptr& ptr, MWWorld::Ptr::CellStore *store); + void removeObject (const MWWorld::Ptr& ptr, MWWorld::Ptr::CellStore *store); + + void moveObject (const MWWorld::Ptr& ptr, const Ogre::Vector3& position); + void scaleObject (const MWWorld::Ptr& ptr, const Ogre::Vector3& scale); + void rotateObject (const MWWorld::Ptr& ptr, const::Ogre::Quaternion& orientation); + void moveObjectToCell (const MWWorld::Ptr& ptr, const Ogre::Vector3& position, MWWorld::Ptr::CellStore *store); + + void setPhysicsDebugRendering (bool); + bool getPhysicsDebugRendering() const; + + void update (float duration); + void skyEnable (); + void skyDisable (); + void skySetHour (double hour); + void skySetDate (int day, int month); + int skyGetMasserPhase() const; + int skyGetSecundaPhase() const; + void skySetMoonColour (bool red); + + private: + + +}; + +} + +#endif diff --git a/apps/openmw/mwworld/scene.cpp b/apps/openmw/mwworld/scene.cpp index d9ce68dcd..a6d06a75c 100644 --- a/apps/openmw/mwworld/scene.cpp +++ b/apps/openmw/mwworld/scene.cpp @@ -152,9 +152,9 @@ namespace MWWorld Scene::~Scene() { - for (CellRenderCollection::iterator iter (mActiveCells.begin()); + /*for (CellRenderCollection::iterator iter (mActiveCells.begin()); iter!=mActiveCells.end(); ++iter) - delete iter->second; + delete iter->second;*/ } bool Scene::hasCellChanged() const diff --git a/apps/openmw/mwworld/world.cpp b/apps/openmw/mwworld/world.cpp index 2a89b1f42..abb1cf5ba 100644 --- a/apps/openmw/mwworld/world.cpp +++ b/apps/openmw/mwworld/world.cpp @@ -320,7 +320,7 @@ namespace MWWorld delete mPlayer; delete mSkyManager; delete mGlobalVariables; - delete mWorldScene; + //delete mWorldScene; delete mPhysics; }