ChimeraTK-DeviceAccess
03.18.00
|
interface to an image that is mapped onto a 1D array of ValType More...
#include <MappedImage.h>
Public Member Functions | |
void | setShape (unsigned width, unsigned height, ImgFormat fmt) |
needs to be called after construction. More... | |
size_t | lengthForShape (unsigned width, unsigned height, ImgFormat fmt) |
unsigned char * | imgBody () |
returns pointer to image payload data More... | |
template<typename UserType , ImgOptions OPTIONS = ImgOptions::RowMajor> | |
ImgView< UserType, OPTIONS > | interpretedView () |
returns an ImgView object which can be used like a matrix. More... | |
Public Member Functions inherited from ChimeraTK::MappedStruct< ImgHeader > | |
MappedStruct (ChimeraTK::OneDRegisterAccessor< unsigned char > &accToData, InitData doInitData=InitData::No) | |
This keeps a reference to given OneDRegisterAccessor. More... | |
unsigned char * | data () |
returns pointer to data for header and struct content. More... | |
size_t | capacity () const |
capacity of used container More... | |
size_t | size () const |
currently used size More... | |
ImgHeader * | header () |
returns header, e.g. for setting meta data More... | |
void | initData () |
default initialize header and zero out data that follows More... | |
Protected Member Functions | |
void | formatsDefinition (ImgFormat fmt, unsigned &channels, unsigned &bytesPerPixel) |
Additional Inherited Members | |
Public Types inherited from ChimeraTK::MappedStruct< ImgHeader > | |
enum | InitData |
Protected Attributes inherited from ChimeraTK::MappedStruct< ImgHeader > | |
ChimeraTK::OneDRegisterAccessor< unsigned char > & | _accToData |
interface to an image that is mapped onto a 1D array of ValType
NOTE: MappedImage is based on MappedStruct concept, which is discouraged. Use DataConsistencyGroup of struct members instead if possible. MappedImage is currently in used by DoocsAdapter and DoocsBackend.
Definition at line 147 of file MappedImage.h.
|
inlineprotected |
Definition at line 215 of file MappedImage.h.
|
inline |
returns pointer to image payload data
Definition at line 156 of file MappedImage.h.
|
inline |
returns an ImgView object which can be used like a matrix.
The ImgView becomes invalid at next setShape call. It also becomes invalid when memory location of underlying MappedStruct changes.
Definition at line 161 of file MappedImage.h.
|
inline |
Definition at line 253 of file MappedImage.h.
|
inline |
needs to be called after construction.
corrupts all data. this throws logic_error if our buffer size is too small. Try lenghtForShape() to check that in advance
Definition at line 260 of file MappedImage.h.