Describes the layout of data within memory regions.
More...
#include <DataLayout.hpp>
Describes the layout of data within memory regions.
Definition at line 18 of file DataLayout.hpp.
◆ InnerLayout
◆ DataLayout()
| mxl::lib::fabrics::ofi::DataLayout::DataLayout |
( |
InnerLayout | inner | ) |
|
|
privatenoexcept |
◆ asContinuous()
◆ asDiscrete()
◆ fromContinuous()
| DataLayout mxl::lib::fabrics::ofi::DataLayout::fromContinuous |
( |
std::size_t | sampleSize, |
|
|
std::size_t | channelCount, |
|
|
std::size_t | bufferLength ) |
|
staticnodiscardnoexcept |
Create a DataLayout representing audio data.
- Parameters
-
| sampleSize | The size of each audio sample in bytes. |
| channelCount | The number of audio channels. |
| bufferLength | The number of samples per channel. |
- Returns
- A DataLayout representing the specified audio layout.
Definition at line 45 of file DataLayout.cpp.
46 {
48 DataLayout::Continuous{.sampleSize = sampleSize, .channelCount = channelCount, .bufferLength = bufferLength}
49 };
50 }
DataLayout(InnerLayout) noexcept
◆ fromDiscrete()
Create a DataLayout representing video data.
- Parameters
-
| sliceSizes | The slice sizes of each planes in the video data layout. |
- See also
- MXL_MAX_PLANES_PER_GRAIN
- Parameters
-
| totalSlices | Total number of slices (e.g. video lines) per grain. |
- Returns
- A DataLayout representing the specified video layout.
Definition at line 15 of file DataLayout.cpp.
16 {
18 DataLayout::Discrete{.sliceSizes = sliceSizes, .totalSlices = totalSlices}
19 };
20 };
◆ isContinuous()
| bool mxl::lib::fabrics::ofi::DataLayout::isContinuous |
( |
| ) |
const |
|
nodiscardnoexcept |
Check if the DataLayout is of continuous type.
- Returns
- true if the DataLayout is of continuous type, false otherwise.
Definition at line 57 of file DataLayout.cpp.
58 {
59 return std::holds_alternative<Continuous>(
_inner);
60 }
◆ isDiscrete()
| bool mxl::lib::fabrics::ofi::DataLayout::isDiscrete |
( |
| ) |
const |
|
nodiscardnoexcept |
Check if the DataLayout is of discrete type.
- Returns
- true if the DataLayout is of discrete type, false otherwise.
Definition at line 52 of file DataLayout.cpp.
53 {
54 return std::holds_alternative<Discrete>(
_inner);
55 }
◆ _inner
The documentation for this class was generated from the following files: