arsa  2.7
Public Types | Public Member Functions | List of all members
Effekseer::CustomAlignedAllocator< T > Struct Template Reference

#include <Effekseer.h>

Public Types

using value_type = T
 

Public Member Functions

 CustomAlignedAllocator ()
 
template<class U >
 CustomAlignedAllocator (const CustomAlignedAllocator< U > &)
 
T * allocate (std::size_t n)
 
void deallocate (T *p, std::size_t n)
 

Detailed Description

template<class T>
struct Effekseer::CustomAlignedAllocator< T >

Definition at line 776 of file Effekseer.h.

Member Typedef Documentation

◆ value_type

template<class T >
using Effekseer::CustomAlignedAllocator< T >::value_type = T

Definition at line 778 of file Effekseer.h.

Constructor & Destructor Documentation

◆ CustomAlignedAllocator() [1/2]

template<class T >
Effekseer::CustomAlignedAllocator< T >::CustomAlignedAllocator ( )
inline

Definition at line 780 of file Effekseer.h.

780 {}

◆ CustomAlignedAllocator() [2/2]

template<class T >
template<class U >
Effekseer::CustomAlignedAllocator< T >::CustomAlignedAllocator ( const CustomAlignedAllocator< U > &  )
inline

Definition at line 782 of file Effekseer.h.

782 {}

Member Function Documentation

◆ allocate()

template<class T >
T* Effekseer::CustomAlignedAllocator< T >::allocate ( std::size_t  n)
inline

Definition at line 784 of file Effekseer.h.

784 { return reinterpret_cast<T*>(GetAlignedMallocFunc()(sizeof(T) * n, 16)); }
GLdouble n
AlignedMallocFunc GetAlignedMallocFunc()
get an allocator

◆ deallocate()

template<class T >
void Effekseer::CustomAlignedAllocator< T >::deallocate ( T *  p,
std::size_t  n 
)
inline

Definition at line 785 of file Effekseer.h.

785 { GetAlignedFreeFunc()(p, sizeof(T) * n); }
GLdouble n
GLfloat GLfloat p
AlignedFreeFunc GetAlignedFreeFunc()
get a deallocator

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