Skip to content

KDGpuExample::XrCubeLayer

#include <xr_cube_layer.h>

Inherits from KDGpuExample::XrCompositorLayer

Public Functions

Name
XrCubeLayer(const XrCubeLayerOptions & options)
~XrCubeLayer() override
XrCubeLayer(const XrCubeLayer & ) =delete
XrCubeLayer & operator=(const XrCubeLayer & ) =delete
XrCubeLayer(XrCubeLayer && ) =default
XrCubeLayer & operator=(XrCubeLayer && ) =default

Protected Functions

Name
virtual void initialize() override
virtual void cleanup() override
virtual bool update(const KDXr::FrameState & frameState) override
void recreateSwapchains()
virtual void renderCube() =0
virtual KDXr::CompositionLayer * compositionLayer() override

Public Attributes

Name
KDBindings::Property< KDXr::Quaternion > orientation
KDBindings::Property< KDGpu::Extent2D > resolution
KDBindings::Property< KDXr::EyeVisibility > eyeVisibility

Protected Attributes

Name
KDGpu::Device * m_device
KDGpu::Queue * m_queue
KDXr::Session * m_session
KDGpu::Format m_colorSwapchainFormat
KDGpu::Format m_depthSwapchainFormat
KDGpu::SampleCountFlagBits m_samples
KDXr::SwapchainInfo m_colorSwapchain
KDXr::SwapchainInfo m_depthSwapchain
uint32_t m_currentColorImageIndex
uint32_t m_currentDepthImageIndex
KDXr::CubeLayer m_cubeLayer

Additional inherited members

Public Types inherited from KDGpuExample::XrCompositorLayer

Name
enum class uint32_t Type { Projection, Quad, Cylinder, Cube, Equirect, PassThrough}

Public Functions inherited from KDGpuExample::XrCompositorLayer

Name
virtual ~XrCompositorLayer()
XrCompositorLayer(const XrCompositorLayer & ) =delete
XrCompositorLayer(XrCompositorLayer && ) =default
Type type() const
void setReferenceSpace(const KDGpu::Handle< KDXr::ReferenceSpace_t > & referenceSpace)
KDGpu::Handle< KDXr::ReferenceSpace_t > referenceSpace() const
const XrExampleEngineLayer * engineLayer() const
XrExampleEngineLayer * engineLayer()
const Engine * engine() const
Engine * engine()

Protected Functions inherited from KDGpuExample::XrCompositorLayer

Name
XrCompositorLayer(Type type)
std::shared_ptr< spdlog::logger > logger() const
void uploadBufferData(const KDGpu::BufferUploadOptions & options)
void uploadTextureData(const KDGpu::TextureUploadOptions & options)

Protected Attributes inherited from KDGpuExample::XrCompositorLayer

Name
Type m_type
XrExampleEngineLayer * m_engineLayer
KDGpu::Handle< KDXr::ReferenceSpace_t > m_referenceSpace

Friends inherited from KDGpuExample::XrCompositorLayer

Name
class XrExampleEngineLayer

Public Functions Documentation

function XrCubeLayer

1
2
3
explicit XrCubeLayer(
    const XrCubeLayerOptions & options
)

function ~XrCubeLayer

1
~XrCubeLayer() override

function XrCubeLayer

1
2
3
XrCubeLayer(
    const XrCubeLayer & 
) =delete

function operator=

1
2
3
XrCubeLayer & operator=(
    const XrCubeLayer & 
) =delete

function XrCubeLayer

1
2
3
XrCubeLayer(
    XrCubeLayer && 
) =default

function operator=

1
2
3
XrCubeLayer & operator=(
    XrCubeLayer && 
) =default

Protected Functions Documentation

function initialize

1
virtual void initialize() override

Reimplements: KDGpuExample::XrCompositorLayer::initialize

function cleanup

1
virtual void cleanup() override

Reimplements: KDGpuExample::XrCompositorLayer::cleanup

function update

1
2
3
virtual bool update(
    const KDXr::FrameState & frameState
) override

Reimplements: KDGpuExample::XrCompositorLayer::update

function recreateSwapchains

1
void recreateSwapchains()

function renderCube

1
virtual void renderCube() =0

function compositionLayer

1
inline virtual KDXr::CompositionLayer * compositionLayer() override

Reimplements: KDGpuExample::XrCompositorLayer::compositionLayer

Public Attributes Documentation

variable orientation

1
KDBindings::Property< KDXr::Quaternion > orientation {};

variable resolution

1
KDBindings::Property< KDGpu::Extent2D > resolution { KDGpu::Extent2D{ 512, 512 } };

variable eyeVisibility

1
KDBindings::Property< KDXr::EyeVisibility > eyeVisibility { KDXr::EyeVisibility::Both };

Protected Attributes Documentation

variable m_device

1
KDGpu::Device * m_device { nullptr };

variable m_queue

1
KDGpu::Queue * m_queue { nullptr };

variable m_session

1
KDXr::Session * m_session { nullptr };

variable m_colorSwapchainFormat

1
KDGpu::Format m_colorSwapchainFormat { KDGpu::Format::UNDEFINED };

variable m_depthSwapchainFormat

1
KDGpu::Format m_depthSwapchainFormat { KDGpu::Format::UNDEFINED };

variable m_samples

1
KDGpu::SampleCountFlagBits m_samples { KDGpu::SampleCountFlagBits::Samples1Bit };

variable m_colorSwapchain

1
KDXr::SwapchainInfo m_colorSwapchain;

variable m_depthSwapchain

1
KDXr::SwapchainInfo m_depthSwapchain;

variable m_currentColorImageIndex

1
uint32_t m_currentColorImageIndex { 0 };

variable m_currentDepthImageIndex

1
uint32_t m_currentDepthImageIndex { 0 };

variable m_cubeLayer

1
KDXr::CubeLayer m_cubeLayer;

Updated on 2024-12-22 at 00:01:23 +0000