![]() |
Zivid C++ API 2.15.0+5fcc365b-1
|
Choose how to sample colors for the point cloud. The rgb
option gives a 2D image with full colors. The grayscale
option gives a grayscale (r=g=b) 2D image, which can be acquired faster than full colors. The disabled
option gives no colors and can allow for even faster captures.
More...
#include <Zivid/Settings.h>
Public Types | |
enum class | ValueType { rgb , disabled , grayscale } |
The type of the underlying value. More... | |
Public Member Functions | |
Color ()=default | |
Default constructor. | |
constexpr | Color (ValueType value) |
Constructor. | |
ValueType | value () const |
Get the value. | |
bool | hasValue () const |
Check if the value is set. | |
void | reset () |
Reset the node to unset state. | |
std::string | toString () const |
Get the value as string. | |
bool | operator== (const Color &other) const |
Comparison operator. | |
bool | operator!= (const Color &other) const |
Comparison operator. | |
Static Public Member Functions | |
static std::set< ValueType > | validValues () |
All valid values of Color. | |
Static Public Attributes | |
static constexpr DataModel::NodeType | nodeType = DataModel::NodeType::leafValue |
The type of this node. | |
static constexpr const char * | path { "Sampling/Color" } |
The full path for this value. | |
static constexpr const char * | name { "Color" } |
The name of this value. | |
static constexpr const char * | description |
The description for this value. | |
static const Color | rgb |
rgb | |
static const Color | disabled |
disabled | |
static const Color | grayscale |
grayscale | |
Friends | |
struct | DataModel::Detail::Befriend< Color > |
std::ostream & | operator<< (std::ostream &stream, const Color::ValueType &value) |
Operator to serialize ValueType to a stream. | |
std::ostream & | operator<< (std::ostream &stream, const Color &value) |
Operator to serialize the value to a stream. | |
Choose how to sample colors for the point cloud. The rgb
option gives a 2D image with full colors. The grayscale
option gives a grayscale (r=g=b) 2D image, which can be acquired faster than full colors. The disabled
option gives no colors and can allow for even faster captures.
The grayscale
option is not available on all camera models.
This setting is deprecated as of SDK 2.14. This setting will be removed in the next SDK major version (SDK 3.0). The recommended way to do a 2D+3D capture is to set a Settings2D
object in the Settings/Color
field. Tip: If you want to convert an existing settings.yml file to the recommended API, you can import the .yml file into Zivid Studio and then re-export it to .yml.
|
strong |
|
default |
Default constructor.
|
inlineexplicitconstexpr |
Constructor.
bool Zivid::Settings::Sampling::Color::hasValue | ( | ) | const |
Check if the value is set.
|
inline |
Comparison operator.
|
inline |
Comparison operator.
void Zivid::Settings::Sampling::Color::reset | ( | ) |
Reset the node to unset state.
std::string Zivid::Settings::Sampling::Color::toString | ( | ) | const |
Get the value as string.
|
inlinestatic |
All valid values of Color.
ValueType Zivid::Settings::Sampling::Color::value | ( | ) | const |
Get the value.
If this object does not contain a value (see hasValue) then this method throws an exception.
|
friend |
|
friend |
Operator to serialize the value to a stream.
|
friend |
Operator to serialize ValueType to a stream.
|
staticconstexpr |
The description for this value.
|
static |
disabled
|
static |
grayscale
|
staticconstexpr |
The name of this value.
|
staticconstexpr |
The type of this node.
|
staticconstexpr |
The full path for this value.
|
static |
rgb