Added layer system
This commit is contained in:
parent
7b268efa6a
commit
bb055a48d2
4 changed files with 49 additions and 2 deletions
27
include/lol/Layer.hpp
Normal file
27
include/lol/Layer.hpp
Normal file
|
@ -0,0 +1,27 @@
|
|||
#pragma once
|
||||
|
||||
#include <string>
|
||||
|
||||
namespace lol
|
||||
{
|
||||
class CameraBase;
|
||||
|
||||
class Layer
|
||||
{
|
||||
public:
|
||||
Layer(const std::string& debugName);
|
||||
virtual ~Layer();
|
||||
|
||||
virtual void OnAttach() {}
|
||||
virtual void OnDetach() {}
|
||||
|
||||
virtual void OnUpdate() {}
|
||||
virtual void OnRender(CameraBase& camera) {}
|
||||
|
||||
inline const std::string& GetDebugName() { return debugName; }
|
||||
|
||||
private:
|
||||
std::string debugName;
|
||||
};
|
||||
|
||||
}
|
|
@ -7,4 +7,5 @@
|
|||
#include <lol/Texture.hpp>
|
||||
#include <lol/Image.hpp>
|
||||
#include <lol/Camera.hpp>
|
||||
#include <lol/util/BoundingBox.hpp>
|
||||
#include <lol/util/BoundingBox.hpp>
|
||||
#include <lol/Layer.hpp>
|
Loading…
Add table
Add a link
Reference in a new issue