![]() |
Zivid C++ API 2.6.1+6cec8609-3
Defining the Future of 3D Machine Vision
|
Information about camera connection state, temperatures, etc. More...
#include <Zivid/CameraState.h>
Classes | |
class | Available |
Flag if camera is physically connected to the computer, but not connected in software. When the camera is in this state, you can call connect(). More... | |
class | Connected |
Flag if camera is connected in software More... | |
class | Temperature |
Current temperature(s) More... | |
Public Member Functions | |
CameraState () | |
Default constructor More... | |
CameraState (const std::string &fileName) | |
Construct CameraState by loading from file More... | |
template<typename... Args> | |
CameraState (Args &&...args) | |
Constructor taking variadic number of arguments More... | |
template<typename... Args> | |
void | set (Args &&...args) |
Set multiple arguments More... | |
template<typename... Args> | |
CameraState | copyWith (Args &&...args) const |
Returns a copy of this object with the given argument(s) set to the new value(s) More... | |
const Available & | isAvailable () const |
Get Available More... | |
Available & | isAvailable () |
Get Available More... | |
CameraState & | set (const Available &value) |
Set Available More... | |
const Connected & | isConnected () const |
Get Connected More... | |
Connected & | isConnected () |
Get Connected More... | |
CameraState & | set (const Connected &value) |
Set Connected More... | |
const Temperature & | temperature () const |
Get Temperature More... | |
Temperature & | temperature () |
Get Temperature More... | |
CameraState & | set (const Temperature &value) |
Set Temperature More... | |
CameraState & | set (const Temperature::DMD &value) |
Set Temperature::DMD More... | |
CameraState & | set (const Temperature::General &value) |
Set Temperature::General More... | |
CameraState & | set (const Temperature::LED &value) |
Set Temperature::LED More... | |
CameraState & | set (const Temperature::Lens &value) |
Set Temperature::Lens More... | |
CameraState & | set (const Temperature::PCB &value) |
Set Temperature::PCB More... | |
template<typename T , typename std::enable_if< std::is_same< T, CameraState::Available >::value, int >::type = 0> | |
const CameraState::Available & | get () const |
template<typename T , typename std::enable_if< std::is_same< T, CameraState::Connected >::value, int >::type = 0> | |
const CameraState::Connected & | get () const |
template<typename T , typename std::enable_if< std::is_same< T, CameraState::Temperature >::value, int >::type = 0> | |
const CameraState::Temperature & | get () const |
template<typename T , typename std::enable_if< std::is_same< T, CameraState::Temperature::DMD >::value, int >::type = 0> | |
const CameraState::Temperature::DMD & | get () const |
template<typename T , typename std::enable_if< std::is_same< T, CameraState::Temperature::General >::value, int >::type = 0> | |
const CameraState::Temperature::General & | get () const |
template<typename T , typename std::enable_if< std::is_same< T, CameraState::Temperature::LED >::value, int >::type = 0> | |
const CameraState::Temperature::LED & | get () const |
template<typename T , typename std::enable_if< std::is_same< T, CameraState::Temperature::Lens >::value, int >::type = 0> | |
const CameraState::Temperature::Lens & | get () const |
template<typename T , typename std::enable_if< std::is_same< T, CameraState::Temperature::PCB >::value, int >::type = 0> | |
const CameraState::Temperature::PCB & | get () const |
template<size_t i, typename std::enable_if< i==0, int >::type = 0> | |
const CameraState::Available & | get () const |
template<size_t i, typename std::enable_if< i==1, int >::type = 0> | |
const CameraState::Connected & | get () const |
template<size_t i, typename std::enable_if< i==2, int >::type = 0> | |
const CameraState::Temperature & | get () const |
template<typename F > | |
void | forEach (const F &f) const |
Run the given function on each direct member with the value of the member as parameter More... | |
template<typename F > | |
void | forEach (const F &f) |
Run the given function on each direct member with the value of the member as parameter More... | |
bool | operator== (const CameraState &other) const |
Equality operator More... | |
bool | operator!= (const CameraState &other) const |
Inequality operator More... | |
std::string | toString () const |
Get the value as string More... | |
void | save (const std::string &fileName) const |
Save to the given file More... | |
void | load (const std::string &fileName) |
Load from the given file More... | |
Static Public Attributes | |
static constexpr DataModel::NodeType | nodeType = DataModel::NodeType::group |
The type of this node More... | |
static constexpr const char * | path { "" } |
The full path for this value More... | |
static constexpr const char * | name { "CameraState" } |
The name of this value More... | |
static constexpr const char * | description |
The description for this value More... | |
static constexpr size_t | version { 2 } |
Friends | |
struct | DataModel::Detail::Befriend< CameraState > |
std::ostream & | operator<< (std::ostream &stream, const CameraState &value) |
Operator to send the value as string to a stream More... | |
Information about camera connection state, temperatures, etc.
Zivid::CameraState::CameraState | ( | ) |
Default constructor
|
explicit |
Construct CameraState by loading from file
|
inlineexplicit |
Constructor taking variadic number of arguments
One or more descendant types can be provided. All types not provided will be set to their default value. The result is the same as default constructing CameraState
then invoking set(args)
.
The provided arguments must be descendants of CameraState
. These types can be provided:
|
inline |
Returns a copy of this object with the given argument(s) set to the new value(s)
Creates a copy of this CameraState object, then invokes set(args)
on the copy, and finally returns the copy. This method does not modify the original object.
The provided arguments must be descendants of CameraState
. These types can be provided:
|
inline |
Run the given function on each direct member with the value of the member as parameter
|
inline |
Run the given function on each direct member with the value of the member as parameter
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
void Zivid::CameraState::load | ( | const std::string & | fileName | ) |
Load from the given file
bool Zivid::CameraState::operator!= | ( | const CameraState & | other | ) | const |
Inequality operator
bool Zivid::CameraState::operator== | ( | const CameraState & | other | ) | const |
Equality operator
void Zivid::CameraState::save | ( | const std::string & | fileName | ) | const |
Save to the given file
|
inline |
Set multiple arguments
The method invokes set(arg)
with each of the provided arguments.
The provided arguments must be descendants of CameraState
. These types can be provided:
|
inline |
Set Available
|
inline |
Set Connected
|
inline |
Set Temperature
|
inline |
Set Temperature::DMD
|
inline |
|
inline |
Set Temperature::LED
|
inline |
|
inline |
Set Temperature::PCB
|
inline |
Get Temperature
|
inline |
Get Temperature
std::string Zivid::CameraState::toString | ( | ) | const |
Get the value as string
|
friend |
|
friend |
Operator to send the value as string to a stream
|
staticconstexpr |
The description for this value
|
staticconstexpr |
The name of this value
|
staticconstexpr |
The type of this node
|
staticconstexpr |
The full path for this value
|
staticconstexpr |