PixelBullet  0.0.1
A C++ game engine
Loading...
Searching...
No Matches
render_frame_context.h
1#pragma once
2
3#include "pixelbullet/graphics/commands/command_buffer.h"
4
5#include <cstdint>
6#include <string_view>
7
8namespace pixelbullet
9{
10class Descriptor;
11class Graphics;
12class RenderDevice;
13class RenderTarget2D;
14
16{
17public:
18 const RenderDevice& GetRenderDevice() const;
19 const CommandBuffer& GetCommandBuffer() const;
20 uint32_t GetImageIndex() const;
21 uint32_t GetImageCount() const;
22 const Descriptor* GetAttachment(std::string_view name) const;
23 const RenderTarget2D* GetRenderTarget(std::string_view name) const;
24
25private:
26 friend class Graphics;
27
28 RenderFrameContext(const RenderDevice& render_device, const CommandBuffer& command_buffer, uint32_t image_index,
29 uint32_t image_count) noexcept;
30
31 const RenderDevice* render_device_ = nullptr;
32 const CommandBuffer* command_buffer_ = nullptr;
33 uint32_t image_index_ = 0;
34 uint32_t image_count_ = 1;
35};
36} // namespace pixelbullet
Class that represents a command buffer.
Definition command_buffer.h:17
Definition descriptor.h:75
Module that manages the Vulkan instance_, Surface, Window and the renderpass structure.
Definition graphics.h:36
Definition render_device.h:15
Definition render_frame_context.h:16
Definition render_target.h:37