RAII aligned buffer with SIMD-friendly access. More...
#include <simd_buffer.hpp>
Public Member Functions | |
| AlignedBufferT ()=default | |
| AlignedBufferT (size_t num_samples) | |
| ~AlignedBufferT () | |
| AlignedBufferT (AlignedBufferT &&other) noexcept | |
| AlignedBufferT & | operator= (AlignedBufferT &&other) noexcept |
| AlignedBufferT (const AlignedBufferT &)=delete | |
| AlignedBufferT & | operator= (const AlignedBufferT &)=delete |
| SampleType * | data () |
| const SampleType * | data () const |
| size_t | size () const |
| bool | empty () const |
| SampleType & | operator[] (size_t i) |
| const SampleType & | operator[] (size_t i) const |
| SampleType * | begin () |
| SampleType * | end () |
| const SampleType * | begin () const |
| const SampleType * | end () const |
| void | clear () |
| Clear buffer to zero. | |
| void | resize (size_t new_size) |
| Resize (reallocates, does not preserve data). | |
| void | copy_from (const SampleType *src, size_t count) |
| Copy from raw pointer. | |
RAII aligned buffer with SIMD-friendly access.
RT contract: construction, destruction, move assignment, and resize() may allocate or free memory, except resize(size()) which is a no-op. clear(), copy_from(), element access, iteration, and same-size resize are allocation-free after storage has been allocated.
|
default |
|
inlineexplicit |
|
inline |
|
inlinenoexcept |
|
delete |
|
inline |
|
inline |
|
inline |
Clear buffer to zero.
|
inline |
Copy from raw pointer.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlinenoexcept |
|
delete |
|
inline |
|
inline |
|
inline |
Resize (reallocates, does not preserve data).
|
inline |