Initial commit: Final state of the master project
This commit is contained in:
47
Research/scene/Octree/NodeSmall.h
Normal file
47
Research/scene/Octree/NodeSmall.h
Normal file
@@ -0,0 +1,47 @@
|
||||
#pragma once
|
||||
#include <vector>
|
||||
#include "../../inc/glm/glm.hpp"
|
||||
#include "../../core/Defines.h"
|
||||
#include "Root.h"
|
||||
|
||||
class NodeSmall {
|
||||
public:
|
||||
NodeSmall(Root* root, unsigned8 level = 0) {}
|
||||
~NodeSmall() {}
|
||||
|
||||
//Node* GetChild(ChildIndex index);
|
||||
//bool HasChild(ChildIndex index);
|
||||
//void SetChild(ChildIndex index, Node* child);
|
||||
//// Returns the number of direct children this node has (e.g. the number of "1" in the childmask)
|
||||
//unsigned8 GetChildCount();
|
||||
//unsigned8 GetLevel();
|
||||
//// Returns the number of leaf voxels in this octree (if it wasn't compressed)
|
||||
//virtual unsigned long long GetLeafVoxelCount();
|
||||
|
||||
//// Returns true if this node is smaller than the other node. Used for sorting
|
||||
//virtual bool Compare(Node* node);
|
||||
//// Returns true if this node is equal to the other node
|
||||
//virtual bool Equals(Node* node);
|
||||
|
||||
//// Recursively set the level of the current node
|
||||
//void SetLevel(unsigned8 level);
|
||||
|
||||
//ChildMask GetChildmask();
|
||||
|
||||
//virtual void WriteProperties(std::ostream& file);
|
||||
//virtual void ReadProperties(std::istream& file);
|
||||
//virtual void CopyProperties(Node* source);
|
||||
protected:
|
||||
|
||||
//Node* AddChild(ChildIndex index);
|
||||
//// Adds the the given to the tree at the given coordinate. The node should specify at which level it needs to be added. If a node already exists at the given coordinate,
|
||||
//// false is returned
|
||||
//Node* AddNode(glm::uvec3 coordinates, unsigned8 level);
|
||||
|
||||
Root* mRoot; // the tree to which this node belongs
|
||||
|
||||
ChildMask mChildMask;
|
||||
std::vector<Node*> mChildren; // index of children, NULL if leaf node
|
||||
unsigned8 mLevel; // the level of the current node, where the root has level 0
|
||||
private:
|
||||
};
|
||||
Reference in New Issue
Block a user