vengine  0.0.1
3D graphics engine
Loading...
Searching...
No Matches
PointLight.hpp
Go to the documentation of this file.
1///
2/// @file PointLight.hpp
3/// @brief This file contains the PointLightRenderSystem class
4/// @namespace ven
5///
6
7#pragma once
8
10
11namespace ven {
12
14 glm::vec4 position{};
15 glm::vec4 color{};
16 float radius;
17 };
18
19 ///
20 /// @class PointLightRenderSystem
21 /// @brief Class for point light system
22 /// @namespace ven
23 ///
25
26 public:
27
28 explicit PointLightRenderSystem(Device& device, const VkRenderPass renderPass, const VkDescriptorSetLayout globalSetLayout) : ARenderSystemBase(device) {
29 createPipelineLayout(globalSetLayout, sizeof(LightPushConstantData));
30 createPipeline(renderPass, std::string(SHADERS_BIN_PATH) + "vertex_point_light.spv", std::string(SHADERS_BIN_PATH) + "fragment_point_light.spv", true);
31 }
32
37
38 void render(const FrameInfo &frameInfo) const override;
39
40 }; // class PointLightRenderSystem
41
42} // namespace ven
This file contains the ARenderSystemBase class.
Abstract class for render system base.
Definition ABase.hpp:20
void createPipelineLayout(VkDescriptorSetLayout globalSetLayout, uint32_t pushConstantSize)
Definition base.cpp:3
void createPipeline(VkRenderPass renderPass, const std::string &shadersVertPath, const std::string &shadersFragPath, bool isLight)
Definition base.cpp:35
Class for device.
Definition Device.hpp:35
Class for point light system.
PointLightRenderSystem & operator=(PointLightRenderSystem &&)=delete
PointLightRenderSystem & operator=(const PointLightRenderSystem &)=delete
PointLightRenderSystem(PointLightRenderSystem &&)=delete
void render(const FrameInfo &frameInfo) const override
Definition pointLight.cpp:5
PointLightRenderSystem(Device &device, const VkRenderPass renderPass, const VkDescriptorSetLayout globalSetLayout)
PointLightRenderSystem(const PointLightRenderSystem &)=delete
static constexpr std::string_view SHADERS_BIN_PATH
Definition Shaders.hpp:13