ULRE/inc/hgl/graph/RenderList.h

44 lines
1.3 KiB
C
Raw Normal View History

2019-05-25 00:50:04 +08:00
#ifndef HGL_GRAPH_RENDER_LIST_INCLUDE
#define HGL_GRAPH_RENDER_LIST_INCLUDE
#include<hgl/graph/VK.h>
#include<hgl/graph/SceneNode.h>
#include<hgl/graph/MaterialRenderMap.h>
#include<hgl/graph/VKArrayBuffer.h>
2023-03-25 15:47:08 +08:00
#include<hgl/graph/VKMaterial.h>
2019-05-25 00:50:04 +08:00
namespace hgl
{
namespace graph
{
2021-04-30 18:56:20 +08:00
/**
* <br>
2023-05-07 01:07:26 +08:00
* 使使Clear()
2021-04-30 18:56:20 +08:00
*/
2019-05-25 00:50:04 +08:00
class RenderList
{
2023-05-07 01:07:26 +08:00
protected:
2023-03-22 21:19:23 +08:00
2023-03-24 22:14:43 +08:00
GPUDevice * device;
2023-05-07 01:07:26 +08:00
uint renderable_count; ///<可渲染对象数量
MaterialRenderMap mrl_map; ///<按材质分类的渲染列表
protected:
2023-05-07 01:07:26 +08:00
virtual bool ExpendNode(SceneNode *);
2019-05-25 00:50:04 +08:00
public:
RenderList(GPUDevice *);
virtual ~RenderList()=default;
2023-05-07 01:07:26 +08:00
virtual bool Expend(SceneNode *); ///<展开场景树到渲染列表
2023-03-24 22:14:43 +08:00
2023-05-07 01:07:26 +08:00
virtual bool Render(RenderCmdBuffer *); ///<渲染所有对象
2023-05-07 01:07:26 +08:00
virtual void Clear(); ///<彻底清理
};//class RenderList
2019-05-25 00:50:04 +08:00
}//namespace graph
}//namespace hgl
#endif//HGL_GRAPH_RENDER_LIST_INCLUDE