Class DeferredRasterizer#
Defined in File DeferredRasterizer.ixx
Class Documentation#
-
class DeferredRasterizer#
Public Functions
-
DeferredRasterizer()#
-
DeferredRasterizer(const DeferredRasterizer&) = delete#
-
DeferredRasterizer &operator=(const DeferredRasterizer&) = delete#
-
void shaderHotReload(std::span<const vk::DescriptorSetLayout> descriptor_set_layouts)#
-
inline vk::ImageView getGBufferNormal(uint32_t index) const#
-
inline vk::ImageView getGBufferAlbedo(uint32_t index) const#
-
inline vk::ImageView getGBufferMaterial(uint32_t index) const#
-
inline vk::ImageView getDepthBufferImageView() const#
-
void setPushConstant(PushConstantRasterizer push_constant)#
-
void recordCommands(vk::CommandBuffer &commandBuffer, uint32_t image_index, Kataglyphis::Scene *scene, std::span<const vk::DescriptorSet> descriptorSets, const std::optional<FrustumPlanes> &cameraFrustum = std::nullopt)#
cameraFrustumculls meshes whose world-space bounds fall entirely outside the view. Pass std::nullopt to draw everything - and note that the SHADOW pass must do exactly that: geometry behind or beside the camera still casts into view, so culling casters by the camera frustum deletes shadows rather than saving work.
-
inline unsigned int getMeshesDrawn() const#
Meshes drawn / considered by the most recent recordCommands call. Reset at the start of each call, so a frame that records nothing reports zeros rather than stale counts from the previous frame.
-
inline unsigned int getMeshesConsidered() const#
-
void recreateFrameResources()#
-
void destroyFramebuffers()#
-
void cleanUp()#
-
~DeferredRasterizer()#
Public Static Attributes
-
static vk::Format FINAL_FORMAT = vk::Format::eR16G16B16A16Sfloat#
-
static vk::Format GBUFFER_NORMAL_FORMAT = vk::Format::eR16G16B16A16Sfloat#
-
static vk::Format GBUFFER_ALBEDO_FORMAT = vk::Format::eR8G8B8A8Srgb#
-
static vk::Format GBUFFER_MATERIAL_FORMAT = vk::Format::eR16G16B16A16Sfloat#
-
DeferredRasterizer()#