Skip to content

HelloTriangleRt

#include <hello_triangle_rt.h>

Inherits from KDGpuExample::SimpleExampleEngineLayer, KDGpuExample::ExampleEngineLayer, KDGpuExample::EngineLayer, KDFoundation::Object

Public Functions

Name
HelloTriangleRt()

Protected Functions

Name
void createRayTracingPipeline()
void createShaderBindingTable()
void createAccelerationStructures()
void createBindGroups()
virtual void initializeScene() override
virtual void cleanupScene() override
virtual void updateScene() override
[1]
virtual void render() override
[2]
virtual void resize() override
[1]

Additional inherited members

Public Functions inherited from KDGpuExample::SimpleExampleEngineLayer

Name
SimpleExampleEngineLayer() =default
~SimpleExampleEngineLayer() override

Protected Functions inherited from KDGpuExample::SimpleExampleEngineLayer

Name
virtual void update() override
void event(KDFoundation::EventReceiver * target, KDFoundation::Event * ev) override

Public Functions inherited from KDGpuExample::ExampleEngineLayer

Name
ExampleEngineLayer()
~ExampleEngineLayer() override
KDGpuKDGui::View * window()

Protected Functions inherited from KDGpuExample::ExampleEngineLayer

Name
virtual void drawImGuiOverlay(ImGuiContext * ctx)
virtual void renderImGuiOverlay(RenderPassCommandRecorder * recorder, uint32_t inFlightIndex =0, RenderPass * currentRenderPass =nullptr, int lastSubpassIndex =0)
void registerImGuiOverlayDrawFunction(const std::function< void(ImGuiContext *)> & func)
void clearImGuiOverlayDrawFunctions()
void recreateImGuiOverlay()
virtual void onAttached() override
virtual void onDetached() override
virtual void update() override
void event(KDFoundation::EventReceiver * target, KDFoundation::Event * ev) override
virtual void recreateSwapChain()
void recreateDepthTexture()
void recreateSampleDependentResources()
void uploadBufferData(const BufferUploadOptions & options)
void uploadTextureData(const TextureUploadOptions & options)
void releaseStagingBuffers()

Protected Attributes inherited from KDGpuExample::ExampleEngineLayer

Name
std::shared_ptr< spdlog::logger > m_logger
std::unique_ptr< GraphicsApi > m_api
std::unique_ptr< KDGpuKDGui::View > m_window
Extent2D m_swapchainExtent
KDBindings::Property< SampleCountFlagBits > m_samples
TextureUsageFlags m_swapchainUsageFlags
std::vector< SampleCountFlagBits > m_supportedSampleCounts
Instance m_instance
Surface m_surface
Device m_device
Queue m_queue
PresentMode m_presentMode
Swapchain m_swapchain
std::vector< TextureView > m_swapchainViews
Texture m_depthTexture
TextureView m_depthTextureView
std::unique_ptr< ImGuiItem > m_imguiOverlay
std::vector< std::function< void(ImGuiContext *)> > m_imGuiOverlayDrawFunctions
uint32_t m_currentSwapchainImageIndex
uint32_t m_inFlightIndex
std::array< GpuSemaphore, MAX_FRAMES_IN_FLIGHT > m_presentCompleteSemaphores
std::array< GpuSemaphore, MAX_FRAMES_IN_FLIGHT > m_renderCompleteSemaphores
TextureUsageFlags m_depthTextureUsageFlags
std::vector< UploadStagingBuffer > m_stagingBuffers
Format m_swapchainFormat
Format m_depthFormat
CompositeAlphaFlagBits m_compositeAlpha
bool m_showSurfaceCapabilities
std::string m_capabilitiesString

Public Functions inherited from KDGpuExample::EngineLayer

Name
~EngineLayer() override
const Engine * engine() const
Engine * engine()

Protected Functions inherited from KDGpuExample::EngineLayer

Name
virtual void onAttached()
virtual void onDetached()
virtual void update()

Friends inherited from KDGpuExample::EngineLayer

Name
class Engine

Public Functions Documentation

function HelloTriangleRt

1
HelloTriangleRt()

Protected Functions Documentation

function createRayTracingPipeline

1
void createRayTracingPipeline()

function createShaderBindingTable

1
void createShaderBindingTable()

function createAccelerationStructures

1
void createAccelerationStructures()

function createBindGroups

1
void createBindGroups()

function initializeScene

1
virtual void initializeScene() override

Reimplements: KDGpuExample::ExampleEngineLayer::initializeScene

[11]

function cleanupScene

1
virtual void cleanupScene() override

Reimplements: KDGpuExample::ExampleEngineLayer::cleanupScene

function updateScene

1
virtual void updateScene() override

[1]

Reimplements: KDGpuExample::ExampleEngineLayer::updateScene

function render

1
virtual void render() override

[2]

Reimplements: KDGpuExample::ExampleEngineLayer::render

[13]

[13]

function resize

1
virtual void resize() override

[1]

Reimplements: KDGpuExample::ExampleEngineLayer::resize


Updated on 2024-09-08 at 00:13:08 +0000