
Added ability to hold shift and skip the terrain generation when loading Added ability for the perlin terrain to save a raw image of the terrain to use as a cache
38 lines
1.1 KiB
C++
38 lines
1.1 KiB
C++
#pragma once
|
|
#include <list>
|
|
#include "SceneNode.h"
|
|
|
|
class SceneGraph : public SceneNode
|
|
{
|
|
public:
|
|
SceneGraph() : SceneNode(L"Root") {};
|
|
SceneGraph(wstring name) : SceneNode(name) {};
|
|
~SceneGraph(void) {};
|
|
|
|
bool Initialise(void);
|
|
void Update(FXMMATRIX& currentWorldTransformation);
|
|
void Render(void);
|
|
void Shutdown(void);
|
|
|
|
void Add(SceneNodePointer node);
|
|
void Remove(SceneNodePointer node);
|
|
SceneNodePointer Find(wstring name);
|
|
|
|
// Placeholder methods for possibly going up the graph to find the Root and Parent nodes
|
|
SceneNodePointer GetRootNode();
|
|
SceneNodePointer GetParent();
|
|
|
|
// Returns a scenegraphs first child element, useful if you dont know the names but know the structure
|
|
SceneNodePointer GetFirstChild();
|
|
|
|
// Method for returning a pointer to the child list, needed for the split mesh renderer mainly
|
|
list<SceneNodePointer>& GetChildren();
|
|
|
|
protected:
|
|
// Here you need to add whatever collection you are going to
|
|
// use to store the children of this scene graph
|
|
list<SceneNodePointer> _children;
|
|
};
|
|
|
|
typedef shared_ptr<SceneGraph> SceneGraphPointer;
|