Kanzi 4.0.0-beta2
gfx.hpp File Reference

Namespaces

namespace  kanzi
 
namespace  kanzi::gfx
 

Macros

#define KZ_LOG_CATEGORY_KZGFX
 

Functions

template<typename T >
span< Tkanzi::gfx::allocateCommandBufferCommands (const CommandBufferHandleGuard &handle, uint32_t count)
 Allocates typed command buffer memory.
 
KANZI_GFX_API span< byte > kanzi::gfx::allocateCommandBufferMemory (const CommandBufferHandleGuard &handle, uint32_t size)
 Allocates raw memory into a command buffer.
 
KANZI_GFX_API HandleGuard< BlendStateHandlekanzi::gfx::create (const BlendStateCreateInfo &info)
 Creates a blend state graphics object.
 
KANZI_GFX_API HandleGuard< BufferHandlekanzi::gfx::create (const BufferCreateInfo &info)
 Creates a buffer graphics object.
 
KANZI_GFX_API HandleGuard< CommandBufferHandlekanzi::gfx::create (const CommandBufferCreateInfo &info)
 Creates a command buffer graphics object.
 
KANZI_GFX_API HandleGuard< ComputePipelineHandlekanzi::gfx::create (const ComputePipelineCreateInfo &info)
 Creates a compute pipeline graphics object.
 
KANZI_GFX_API HandleGuard< ComputeResourceSetHandlekanzi::gfx::create (const ComputeResourceSetCreateInfo &info)
 Creates a compute resource set graphics object.
 
KANZI_GFX_API HandleGuard< DepthStencilStateHandlekanzi::gfx::create (const DepthStencilStateCreateInfo &info)
 Creates a depth stencil state graphics object.
 
KANZI_GFX_API HandleGuard< FrameBufferHandlekanzi::gfx::create (const FrameBufferCreateInfo &info)
 Creates a frame buffer graphics object.
 
KANZI_GFX_API HandleGuard< GpuFenceHandlekanzi::gfx::create (const GpuFenceCreateInfo &info)
 Creates a GPU fence graphics object.
 
KANZI_GFX_API HandleGuard< ImageHandlekanzi::gfx::create (const ImageCreateInfo &info)
 Creates an image graphics object.
 
KANZI_GFX_API HandleGuard< RasterStateHandlekanzi::gfx::create (const RasterStateCreateInfo &info)
 Creates a raster state graphics object.
 
KANZI_GFX_API HandleGuard< RenderPassHandlekanzi::gfx::create (const RenderPassCreateInfo &info)
 Creates a render pass graphics object.
 
KANZI_GFX_API HandleGuard< RenderPipelineHandlekanzi::gfx::create (const RenderPipelineCreateInfo &info)
 Creates a render pipeline graphics object.
 
KANZI_GFX_API HandleGuard< RenderResourceSetHandlekanzi::gfx::create (const RenderResourceSetCreateInfo &info)
 Creates a render resource set graphics object.
 
KANZI_GFX_API HandleGuard< SamplerHandlekanzi::gfx::create (const SamplerCreateInfo &info)
 Creates a sampler graphics object.
 
KANZI_GFX_API HandleGuard< ShaderHandlekanzi::gfx::create (const ShaderCreateInfo &info)
 Creates a shader graphics object.
 
KANZI_GFX_API HandleGuard< VertexInputStateHandlekanzi::gfx::create (const VertexInputStateCreateInfo &info)
 Creates a vertex input state graphics object.
 
KANZI_GFX_API BackendInformation kanzi::gfx::getBackendInformation ()
 Gets information about the current backend.
 
KANZI_GFX_API uint32_t kanzi::gfx::getDeviceProperty (DevicePropertyId property)
 Gets the value of a property for the current device.
 
KANZI_GFX_API FormatFeatureFlag kanzi::gfx::getFormatFeatures (Format format)
 Gets device feature flags for a format for the current backend and device.
 
KANZI_GFX_API AttachmentDescriptionSet kanzi::gfx::getFrameBufferAttachmentDescriptionSet (const FrameBufferHandleGuard &handle)
 Gets a default frame buffer attachment description set that is compatible with a frame buffer.
 
KANZI_GFX_API ObjectStatus kanzi::gfx::getStatus (const RenderPipelineHandleGuard &handle)
 Gets the status of a render pipeline graphics object.
 
KANZI_GFX_API ObjectStatus kanzi::gfx::getStatus (const ShaderHandleGuard &handle)
 Gets the status of a shader graphics object.
 
KANZI_GFX_API bool kanzi::gfx::initialize (const InitializationInfo &info)
 Initializes the Kanzi graphics library.
 
KANZI_GFX_API bool kanzi::gfx::isFeatureEnabled (FeatureId feature)
 Returns whether a graphics feature is supported by the current backend and device.
 
KANZI_GFX_API bool kanzi::gfx::isInitialized ()
 Returns whether the graphics library is initialized.
 
KANZI_GFX_API bool kanzi::gfx::isNativeTextureHandleTypeSupported (const gfx::NativeTextureHandle &handle)
 Returns whether a native handle type for texture is supported by the current backend.
 
KANZI_GFX_API bool kanzi::gfx::isShaderFormatSupported (ShaderFormat format)
 Returns whether a shader format is supported by the current backend and device.
 
KANZI_GFX_API span< byte > kanzi::gfx::mapBuffer (const BufferHandleGuard &handle, uint32_t offset=0, uint32_t size=limits::MaxBufferSize)
 Maps buffer memory into CPU-addressable memory for reading or writing.
 
KANZI_GFX_API span< const byte > kanzi::gfx::peekCommandBufferMemory (const CommandBufferHandleGuard &handle)
 Peeks at the currently allocated memory inside a command buffer.
 
KANZI_GFX_API void kanzi::gfx::processCommands (CommandBufferHandleGuard commands, TaskFn callback={})
 Notifies the backend to start processing the commands within a command buffer.
 
KANZI_GFX_API void kanzi::gfx::resetGpuFence (const GpuFenceHandleGuard &handle)
 Resets the state of a GPU fence so that it can be used again.
 
KANZI_GFX_API void kanzi::gfx::shutdown ()
 Shuts down the graphics library.
 
KANZI_GFX_API void kanzi::gfx::unmapBuffer (const BufferHandleGuard &handle)
 Unmaps buffer memory from CPU-addressable memory.
 
KANZI_GFX_API void kanzi::gfx::unmapBuffer (const BufferHandleGuard &handle, span< ByteRange > updatedRanges)
 Unmaps buffer memory from CPU-addressable memory.
 
KANZI_GFX_API void kanzi::gfx::updateSurfaceDimensions (const FrameBufferHandleGuard &handle, v2u32 dimensions)
 Updates the dimensions for a frame buffer that was created as an on-screen surface.
 
KANZI_GFX_API WaitResult kanzi::gfx::waitForGpuFence (const GpuFenceHandleGuard &handle, chrono::nanoseconds timeout)
 Blocks the current thread until the GPU fence has been signaled or the timeout occurs.
 

Macro Definition Documentation

◆ KZ_LOG_CATEGORY_KZGFX

#define KZ_LOG_CATEGORY_KZGFX