|
| | Renderer (const std::string &rendererName, VulkanState &vulkanState, const std::shared_ptr< VulkanDescriptorPool > &DescriptorPool, const std::shared_ptr< VulkanDevice > &device, const std::shared_ptr< RendererResourcePool > &rendererResourcePool, bool isLoadDefaultMaterial=true) |
| | Constructor Function. Init member variables.
|
| |
| virtual | ~Renderer ()=default |
| | Destructor Function. We destroy pipeline layout and free descriptors that holed by this renderer here.
|
| |
| | Renderer (const Renderer &)=delete |
| | Copy Constructor Function.
|
| |
| Renderer & | operator= (const Renderer &)=delete |
| | Copy Assignment Operation.
|
| |
| virtual void | OnSystemInitialize () |
| | This interface is called on render system is registered. Initialize the specific renderer's pipeline, render pass. framebuffer, descriptor, and so on...
|
| |
| virtual void | Render (TimeStep &ts, FrameInfo &frameInfo)=0 |
| | The interface is called every frame. Defines what data needs to be renderer and how to render.
|
| |
| virtual void | OnWindowResizeOver () |
| | This interface is called on Window resized over (registry by swapchain). If the specific renderer uses swapchain image attachment during CreateRenderPass(), this interface needs to override, callOnSlateResize here just will be fine.
|
| |
| virtual void | OnSlateResize () |
| |
| virtual void | OnMeshAddedWorld () |
| |
| void | RegistryMaterial (const std::string &materialName, const std::string &subPassName) |
| | Registry material to Specific Renderer.
|
| |
| void | RegistryDGCPipeline (const std::string &materialName, const std::string &subPassName, VulkanDeviceGeneratedCommandsNV *indirectPtr) |
| | Registry dgc pipeline to Specific Renderer.
|
| |
| template<typename T > |
| std::shared_ptr< VulkanDeviceGeneratedCommandsNV > | FillIndirectRenderData (const std::string &subPassName, std::shared_ptr< std::vector< uint32_t > > view) |
| | Fill in World RenderAble data to IndirectBuffer.
|
| |
| template<typename T > |
| std::shared_ptr< std::vector< uint32_t > > | GetEntityWithComponent (World *world) |
| | Get entities with component in world.
|
| |
| std::shared_ptr< RendererPass > & | GetPasses () |
| | Get RendererPass.
|
| |
| std::shared_ptr< Material > | GetDefaultMaterial (const std::string &subPassName) const |
| | Get default material using sub pass Name.
|
| |
| template<typename F > |
| void | IterStatistics (F &&func) |
| | Iterator the specific RenderPass Statistics in Renderer.
|
| |
| void | ResetRendererState () |
| | Reset Renderer State to disActive.
|
| |
|
| virtual void | CreateRendererPass ()=0 |
| | The interface is called during OnSystemInitialize(). Create specific render pass.
|
| |
| virtual void | CreateDescriptorSet ()=0 |
| | This interface is called during OnSystemInitialize(). Create all sub pass descriptorSet.
|
| |
| virtual void | CreateDeviceGeneratedCommandsLayout () |
| | This interface is called during OnSystemInitialize(). Create Device Generated Commands Layout.
|
| |
| virtual void | CreatePipeline (std::shared_ptr< Material > material, VkPipelineLayout &layout, std::shared_ptr< RendererSubPass > subPass)=0 |
| | Create Specific Material Pipeline.
|
| |
| void | CreateDefaultMaterial () |
| | Create Specific Renderer Default Material.
|
| |
| void | CreateDGCMaterial (const std::string &subPass, VulkanDeviceGeneratedCommandsNV *indirectPtr) |
| | Create Specific Renderer DGC Material.
|
| |
| VkPipelineLayout | CreatePipelineLayout (const std::vector< VkDescriptorSetLayout > &rowSetLayouts, const std::shared_ptr< RendererSubPass > &subPass) const |
| | Create Pipeline Layout with material's descriptorset and renderer's descriptor set.
|
| |
| virtual void | CreateDeviceGeneratedCommandsPipeline (const std::string &pipelineName, const std::string &materialName, VkPipelineLayout &layout, std::shared_ptr< RendererSubPass > subPass, VulkanDeviceGeneratedCommandsNV *indirectPtr) |
| | Create device generated command Pipeline.
|
| |
| template<typename F > |
| std::future< VkCommandBuffer > | SubmitCmdsParallel (VkCommandBuffer primaryCmdBuffer, uint32_t subPass, F &&func) |
| | Submit a group of commands to secondary command buffer, and execute all of them.
|
| |
| template<typename T , typename F > |
| void | IterWorldComp (FrameInfo &frameInfo, F func) |
| | Iterator the specific Component in World.
|
| |
| template<typename T , typename F > |
| void | IterWorldCompWithBreak (FrameInfo &frameInfo, F func) |
| | Iterator the specific Component in World With break.
|
| |
| template<typename T , typename F > |
| void | IterWorldCompWithRange (FrameInfo &frameInfo, const std::vector< uint32_t > &ranges, F func) |
| | Iterator the specific Component in World With range.
|
| |
| template<typename T , typename F > |
| void | IterWorldCompWithRange (FrameInfo &frameInfo, const std::vector< uint32_t > &ranges, uint32_t floor, uint32_t ceil, F func) |
| | Iterator the specific Component in World With range.
|
| |
| template<typename T , typename F > |
| void | IterWorldCompWithBreakWithRange (FrameInfo &frameInfo, const std::vector< uint32_t > &ranges, F func) |
| | Iterator the specific Component in World With break With range.
|
| |
| template<typename T , typename F > |
| void | IterWorldCompWithBreakWithRange (FrameInfo &frameInfo, const std::vector< uint32_t > &ranges, uint32_t floor, uint32_t ceil, F func) |
| | Iterator the specific Component in World With break With range.
|
| |
| std::tuple< glm::mat4, glm::mat4, unsigned int, float > | GetActiveCameraMatrix (FrameInfo &frameInfo) |
| | Get The activated camera entity's view matrix and projection matrix.
|
| |
| void | GetDirectionalLight (FrameInfo &frameInfo, std::array< SpicesShader::DirectionalLight, SpicesShader::DIRECTIONALLIGHT_BUFFER_MAXNUM > &dLightBuffer) |
| | Get DirectionalLightComponent's render data in World.
|
| |
| void | GetDirectionalLightMatrix (FrameInfo &frameInfo, std::array< glm::mat4, MAX_DIRECTIONALLIGHT_NUM > &directionalLight) |
| |
| void | GetPointLight (FrameInfo &frameInfo, std::array< SpicesShader::PointLight, SpicesShader::POINTLIGHT_BUFFER_MAXNUM > &pLightBuffer) |
| | Get PointLightComponent's render data in World.
|
| |
Renderer Class. This class defines the basic behaves of renderer. When we add an new Renderer, we need inherit from this.
Definition at line 56 of file Renderer.h.