定义空的CameraComponentManager/LightComponentManager
This commit is contained in:
parent
0e6546b514
commit
10d0c2c473
@ -17,6 +17,9 @@ class RenderTargetManager;
|
|||||||
|
|
||||||
class RenderModule;
|
class RenderModule;
|
||||||
|
|
||||||
|
class CameraComponentManager{/*现阶段测试使用*/};
|
||||||
|
class LightComponentManager{/*现阶段测试使用*/};
|
||||||
|
|
||||||
class RenderFramework:public io::WindowEvent
|
class RenderFramework:public io::WindowEvent
|
||||||
{
|
{
|
||||||
OSString app_name;
|
OSString app_name;
|
||||||
@ -39,6 +42,11 @@ protected:
|
|||||||
|
|
||||||
SwapchainModule * sc_module =nullptr;
|
SwapchainModule * sc_module =nullptr;
|
||||||
|
|
||||||
|
protected:
|
||||||
|
|
||||||
|
CameraComponentManager *camera_component_manager=nullptr;
|
||||||
|
LightComponentManager *light_component_manager =nullptr;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
Window * GetWindow ()const{return win;}
|
Window * GetWindow ()const{return win;}
|
||||||
@ -67,7 +75,13 @@ public:
|
|||||||
|
|
||||||
virtual bool Init(uint w,uint h);
|
virtual bool Init(uint w,uint h);
|
||||||
|
|
||||||
public:
|
public: // event
|
||||||
|
|
||||||
|
virtual void OnResize(uint w,uint h);
|
||||||
|
virtual void OnActive(bool);
|
||||||
|
virtual void OnClose();
|
||||||
|
|
||||||
|
public: // other
|
||||||
|
|
||||||
RenderList *CreateRenderList()
|
RenderList *CreateRenderList()
|
||||||
{
|
{
|
||||||
@ -76,12 +90,22 @@ public:
|
|||||||
|
|
||||||
TileFont *CreateTileFont(FontSource *fs,int limit_count=-1); ///<创建只使用一种字符的Tile字符管理对象
|
TileFont *CreateTileFont(FontSource *fs,int limit_count=-1); ///<创建只使用一种字符的Tile字符管理对象
|
||||||
|
|
||||||
public: // event
|
public: // ComponentManager
|
||||||
|
|
||||||
virtual void OnResize(uint w,uint h);
|
template<typename T> T *GetComponentManager()
|
||||||
virtual void OnActive(bool);
|
{
|
||||||
virtual void OnClose();
|
return COMPONENT_NAMESPACE::GetComponentManager<T>(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
template<> CameraComponentManager *GetComponentManager<CameraComponentManager>()
|
||||||
|
{
|
||||||
|
return camera_component_manager;
|
||||||
|
}
|
||||||
|
|
||||||
|
template<> LightComponentManager *GetComponentManager<LightComponentManager>()
|
||||||
|
{
|
||||||
|
return light_component_manager;
|
||||||
|
}
|
||||||
};//class RenderFramework
|
};//class RenderFramework
|
||||||
|
|
||||||
VK_NAMESPACE_END
|
VK_NAMESPACE_END
|
||||||
|
Loading…
x
Reference in New Issue
Block a user