ChimeraTK-DeviceAccess
03.18.00
|
Accessor class to read and write 2D registers. More...
#include <ForwardDeclarations.h>
Public Member Functions | |
TwoDRegisterAccessor (boost::shared_ptr< NDRegisterAccessor< UserType >> _accessor) | |
Do not use this constructor directly. More... | |
TwoDRegisterAccessor () | |
Placeholder constructer, to allow late initialisation of the accessor, e.g. More... | |
std::vector< UserType > & | operator[] (size_t channel) |
Operator to access individual sequences/channels. More... | |
const std::vector< UserType > & | operator[] (size_t channel) const |
Const operator to access individual sequences/channels. More... | |
TwoDRegisterAccessor< UserType > & | operator= (const std::vector< std::vector< UserType >> &other) |
Assignment operator to assign the entire 2D array. More... | |
size_t | getNChannels () const |
Return the number of channels (formerly called sequences) More... | |
size_t | getNElementsPerChannel () const |
Return number of elements/samples per channel. More... | |
template<typename COOKED_TYPE > | |
COOKED_TYPE | getAsCooked (unsigned int channel, unsigned int sample) const |
Get the cooked values in case the accessor is a raw accessor (which does not do data conversion). More... | |
template<typename COOKED_TYPE > | |
void | setAsCooked (unsigned int channel, unsigned int sample, COOKED_TYPE value) |
Set the cooked values in case the accessor is a raw accessor (which does not do data conversion). More... | |
Friends | |
class | TransferGroup |
Accessor class to read and write 2D registers.
Definition at line 20 of file ForwardDeclarations.h.
ChimeraTK::TwoDRegisterAccessor< UserType >::TwoDRegisterAccessor | ( | boost::shared_ptr< NDRegisterAccessor< UserType >> | _accessor | ) |
Do not use this constructor directly.
Instead call Device::getTwoDRegisterAccessor().
Definition at line 69 of file TwoDRegisterAccessor.h.
ChimeraTK::TwoDRegisterAccessor< UserType >::TwoDRegisterAccessor |
Placeholder constructer, to allow late initialisation of the accessor, e.g.
in the open function.
Definition at line 78 of file TwoDRegisterAccessor.h.
COOKED_TYPE ChimeraTK::TwoDRegisterAccessor< UserType >::getAsCooked | ( | unsigned int | channel, |
unsigned int | sample | ||
) | const |
Get the cooked values in case the accessor is a raw accessor (which does not do data conversion).
This returns the converted data from the use buffer. It does not do any read or write transfer.
Definition at line 96 of file TwoDRegisterAccessor.h.
|
inline |
Return the number of channels (formerly called sequences)
Definition at line 41 of file TwoDRegisterAccessor.h.
|
inline |
Return number of elements/samples per channel.
Definition at line 44 of file TwoDRegisterAccessor.h.
TwoDRegisterAccessor< UserType > & ChimeraTK::TwoDRegisterAccessor< UserType >::operator= | ( | const std::vector< std::vector< UserType >> & | other | ) |
Assignment operator to assign the entire 2D array.
Definition at line 86 of file TwoDRegisterAccessor.h.
|
inline |
Operator to access individual sequences/channels.
Definition at line 32 of file TwoDRegisterAccessor.h.
|
inline |
Const operator to access individual sequences/channels.
Definition at line 35 of file TwoDRegisterAccessor.h.
void ChimeraTK::TwoDRegisterAccessor< UserType >::setAsCooked | ( | unsigned int | channel, |
unsigned int | sample, | ||
COOKED_TYPE | value | ||
) |
Set the cooked values in case the accessor is a raw accessor (which does not do data conversion).
This converts to raw and writes the data to the user buffer. It does not do any read or write transfer.
Definition at line 104 of file TwoDRegisterAccessor.h.
|
friend |
Definition at line 60 of file TwoDRegisterAccessor.h.