Castor3D 0.16.0
Multiplatform 3D engine
Classes | Public Types | Public Member Functions | List of all members
castor3d::GpuBufferBuddyAllocatorTraits Struct Reference

#include <GpuBufferBuddyAllocator.hpp>

Classes

struct  Block
 

Public Types

using PointerType = VkDeviceSize
 

Public Member Functions

 GpuBufferBuddyAllocatorTraits (size_t size)
 Constructor.
 
size_t getSize () const
 
PointerType getPointer (uint32_t offset) const
 Creates a memory block.
 
size_t getOffset (PointerType pointer) const
 Retrieves the offset from a memory block.
 
Block getNull () const
 
bool isNull (PointerType pointer) const
 

Member Typedef Documentation

◆ PointerType

Constructor & Destructor Documentation

◆ GpuBufferBuddyAllocatorTraits()

castor3d::GpuBufferBuddyAllocatorTraits::GpuBufferBuddyAllocatorTraits ( size_t size)
inlineexplicit

Constructor.

Parameters
[in]sizeThe allocator size.

Member Function Documentation

◆ getNull()

Block castor3d::GpuBufferBuddyAllocatorTraits::getNull ( ) const
inline
Returns
The null memory block.

Referenced by isNull().

Here is the caller graph for this function:

◆ getOffset()

size_t castor3d::GpuBufferBuddyAllocatorTraits::getOffset ( PointerType pointer) const
inline

Retrieves the offset from a memory block.

Parameters
[in]pointerThe memory block.
Returns
The offset.

◆ getPointer()

PointerType castor3d::GpuBufferBuddyAllocatorTraits::getPointer ( uint32_t offset) const
inline

Creates a memory block.

Parameters
[in]offsetThe block memory offset.
Returns
The block.

◆ getSize()

size_t castor3d::GpuBufferBuddyAllocatorTraits::getSize ( ) const
inline
Returns
The allocator size.

◆ isNull()

bool castor3d::GpuBufferBuddyAllocatorTraits::isNull ( PointerType pointer) const
inline
Returns
The null memory block.

References castor3d::GpuBufferBuddyAllocatorTraits::Block::data, and getNull().

Here is the call graph for this function:

The documentation for this struct was generated from the following file: