Zivid C++ API 2.14.0+e4a0c4a9-1
Zivid::Settings::RegionOfInterest::Box Class Reference

Removes points outside the given three-dimensional box. More...

#include <Zivid/Settings.h>

Classes

class  Enabled
 Enable or disable box filter. More...
 
class  Extents
 Two points on the normal describing the direction and distance from the plane from which the normal is derived. More...
 
class  PointA
 A point such that the vector from PointO to PointA describes the first edge of the parallelogram. More...
 
class  PointB
 A point such that the vector from PointO to PointB describes the second edge of the parallelogram. More...
 
class  PointO
 The point at the intersection of two adjacent edges defining a parallelogram. More...
 

Public Types

using Descendants
 

Public Member Functions

 Box ()
 Default constructor.
 
template<typename... Args>
 Box (Args &&...args)
 Constructor taking variadic number of arguments.
 
template<typename... Args>
void set (Args &&...args)
 Set multiple arguments.
 
template<typename... Args>
Box copyWith (Args &&...args) const
 Returns a copy of this object with the given argument(s) set to the new value(s)
 
const EnabledisEnabled () const
 Get Enabled.
 
EnabledisEnabled ()
 Get Enabled.
 
Boxset (const Enabled &value)
 Set Enabled.
 
const Extentsextents () const
 Get Extents.
 
Extentsextents ()
 Get Extents.
 
Boxset (const Extents &value)
 Set Extents.
 
const PointApointA () const
 Get PointA.
 
PointApointA ()
 Get PointA.
 
Boxset (const PointA &value)
 Set PointA.
 
const PointBpointB () const
 Get PointB.
 
PointBpointB ()
 Get PointB.
 
Boxset (const PointB &value)
 Set PointB.
 
const PointOpointO () const
 Get PointO.
 
PointOpointO ()
 Get PointO.
 
Boxset (const PointO &value)
 Set PointO.
 
template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::Enabled >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::Enabledget () const
 
template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::Extents >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::Extentsget () const
 
template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::PointA >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::PointAget () const
 
template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::PointB >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::PointBget () const
 
template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::PointO >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::PointOget () const
 
template<size_t i, typename std::enable_if< i==0, int >::type = 0>
const Settings::RegionOfInterest::Box::Enabledget () const
 
template<size_t i, typename std::enable_if< i==1, int >::type = 0>
const Settings::RegionOfInterest::Box::Extentsget () const
 
template<size_t i, typename std::enable_if< i==2, int >::type = 0>
const Settings::RegionOfInterest::Box::PointAget () const
 
template<size_t i, typename std::enable_if< i==3, int >::type = 0>
const Settings::RegionOfInterest::Box::PointBget () const
 
template<size_t i, typename std::enable_if< i==4, int >::type = 0>
const Settings::RegionOfInterest::Box::PointOget () 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.
 
template<typename F >
void forEach (const F &f)
 Run the given function on each direct member with the value of the member as parameter.
 
bool operator== (const Box &other) const
 Equality operator.
 
bool operator!= (const Box &other) const
 Inequality operator.
 
std::string toString () const
 Get the value as string.
 

Static Public Attributes

static constexpr DataModel::NodeType nodeType = DataModel::NodeType::group
 The type of this node.
 
static constexpr const char * path { "RegionOfInterest/Box" }
 The full path for this value.
 
static constexpr const char * name { "Box" }
 The name of this value.
 
static constexpr const char * description
 The description for this value.
 

Friends

struct DataModel::Detail::Befriend< Box >
 
std::ostream & operator<< (std::ostream &stream, const Box &value)
 Operator to send the value as string to a stream.
 

Detailed Description

Removes points outside the given three-dimensional box.

Using this feature may significantly speed up acquisition and processing time, because one can avoid acquiring and processing data that is guaranteed to fall outside of the region of interest. The degree of speed-up depends on the size and shape of the box. Generally, a smaller box yields a greater speed-up.

The box is defined by three points: O, A and B. These points define two vectors, OA that goes from PointO to PointA, and OB that goes from PointO to PointB. This gives 4 points O, A, B and (O + OA + OB), that together form a parallelogram in 3D.

Two extents can be provided, to extrude the parallelogram along the surface normal vector of the parallelogram plane. This creates a 3D volume (parallelepiped). The surface normal vector is defined by the cross product OA x OB.

Member Typedef Documentation

◆ Descendants

Initial value:
std::tuple<
Settings::RegionOfInterest::Box::Enabled,
Settings::RegionOfInterest::Box::Extents,
Settings::RegionOfInterest::Box::PointA,
Settings::RegionOfInterest::Box::PointB,
Settings::RegionOfInterest::Box::PointO>

Constructor & Destructor Documentation

◆ Box() [1/2]

Zivid::Settings::RegionOfInterest::Box::Box ( )

Default constructor.

◆ Box() [2/2]

template<typename... Args>
Zivid::Settings::RegionOfInterest::Box::Box ( Args &&... args)
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 Box then invoking set(args).

The provided arguments must be descendants of Box. These types can be provided:

Member Function Documentation

◆ copyWith()

template<typename... Args>
Box Zivid::Settings::RegionOfInterest::Box::copyWith ( Args &&... args) const
inline

Returns a copy of this object with the given argument(s) set to the new value(s)

Creates a copy of this Box 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 Box. These types can be provided:

◆ extents() [1/2]

Extents & Zivid::Settings::RegionOfInterest::Box::extents ( )
inline

Get Extents.

◆ extents() [2/2]

const Extents & Zivid::Settings::RegionOfInterest::Box::extents ( ) const
inline

Get Extents.

◆ forEach() [1/2]

template<typename F >
void Zivid::Settings::RegionOfInterest::Box::forEach ( const F & f)
inline

Run the given function on each direct member with the value of the member as parameter.

◆ forEach() [2/2]

template<typename F >
void Zivid::Settings::RegionOfInterest::Box::forEach ( const F & f) const
inline

Run the given function on each direct member with the value of the member as parameter.

◆ get() [1/10]

template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::Enabled >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::Enabled & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ get() [2/10]

template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::Extents >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::Extents & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ get() [3/10]

template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::PointA >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::PointA & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ get() [4/10]

template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::PointB >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::PointB & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ get() [5/10]

template<typename T , typename std::enable_if< std::is_same< T, Settings::RegionOfInterest::Box::PointO >::value, int >::type = 0>
const Settings::RegionOfInterest::Box::PointO & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ get() [6/10]

template<size_t i, typename std::enable_if< i==0, int >::type = 0>
const Settings::RegionOfInterest::Box::Enabled & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ get() [7/10]

template<size_t i, typename std::enable_if< i==1, int >::type = 0>
const Settings::RegionOfInterest::Box::Extents & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ get() [8/10]

template<size_t i, typename std::enable_if< i==2, int >::type = 0>
const Settings::RegionOfInterest::Box::PointA & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ get() [9/10]

template<size_t i, typename std::enable_if< i==3, int >::type = 0>
const Settings::RegionOfInterest::Box::PointB & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ get() [10/10]

template<size_t i, typename std::enable_if< i==4, int >::type = 0>
const Settings::RegionOfInterest::Box::PointO & Zivid::Settings::RegionOfInterest::Box::get ( ) const
inline

◆ isEnabled() [1/2]

Enabled & Zivid::Settings::RegionOfInterest::Box::isEnabled ( )
inline

Get Enabled.

◆ isEnabled() [2/2]

const Enabled & Zivid::Settings::RegionOfInterest::Box::isEnabled ( ) const
inline

Get Enabled.

◆ operator!=()

bool Zivid::Settings::RegionOfInterest::Box::operator!= ( const Box & other) const

Inequality operator.

◆ operator==()

bool Zivid::Settings::RegionOfInterest::Box::operator== ( const Box & other) const

Equality operator.

◆ pointA() [1/2]

PointA & Zivid::Settings::RegionOfInterest::Box::pointA ( )
inline

Get PointA.

◆ pointA() [2/2]

const PointA & Zivid::Settings::RegionOfInterest::Box::pointA ( ) const
inline

Get PointA.

◆ pointB() [1/2]

PointB & Zivid::Settings::RegionOfInterest::Box::pointB ( )
inline

Get PointB.

◆ pointB() [2/2]

const PointB & Zivid::Settings::RegionOfInterest::Box::pointB ( ) const
inline

Get PointB.

◆ pointO() [1/2]

PointO & Zivid::Settings::RegionOfInterest::Box::pointO ( )
inline

Get PointO.

◆ pointO() [2/2]

const PointO & Zivid::Settings::RegionOfInterest::Box::pointO ( ) const
inline

Get PointO.

◆ set() [1/6]

template<typename... Args>
void Zivid::Settings::RegionOfInterest::Box::set ( Args &&... args)
inline

Set multiple arguments.

The method invokes set(arg) with each of the provided arguments.

The provided arguments must be descendants of Box. These types can be provided:

◆ set() [2/6]

Box & Zivid::Settings::RegionOfInterest::Box::set ( const Enabled & value)
inline

Set Enabled.

◆ set() [3/6]

Box & Zivid::Settings::RegionOfInterest::Box::set ( const Extents & value)
inline

Set Extents.

◆ set() [4/6]

Box & Zivid::Settings::RegionOfInterest::Box::set ( const PointA & value)
inline

Set PointA.

◆ set() [5/6]

Box & Zivid::Settings::RegionOfInterest::Box::set ( const PointB & value)
inline

Set PointB.

◆ set() [6/6]

Box & Zivid::Settings::RegionOfInterest::Box::set ( const PointO & value)
inline

Set PointO.

◆ toString()

std::string Zivid::Settings::RegionOfInterest::Box::toString ( ) const

Get the value as string.

Friends And Related Symbol Documentation

◆ DataModel::Detail::Befriend< Box >

friend struct DataModel::Detail::Befriend< Box >
friend

◆ operator<<

std::ostream & operator<< ( std::ostream & stream,
const Box & value )
friend

Operator to send the value as string to a stream.

Member Data Documentation

◆ description

const char* Zivid::Settings::RegionOfInterest::Box::description
staticconstexpr
Initial value:
{
R"description(Removes points outside the given three-dimensional box.
Using this feature may significantly speed up acquisition and processing time, because
one can avoid acquiring and processing data that is guaranteed to fall outside of the
region of interest. The degree of speed-up depends on the size and shape of the box.
Generally, a smaller box yields a greater speed-up.
The box is defined by three points: O, A and B. These points define two vectors,
OA that goes from PointO to PointA, and OB that goes from PointO to PointB.
This gives 4 points O, A, B and (O + OA + OB), that together form a
parallelogram in 3D.
Two extents can be provided, to extrude the parallelogram along the surface
normal vector of the parallelogram plane. This creates a 3D volume (parallelepiped).
The surface normal vector is defined by the cross product OA x OB.
)description"
}

The description for this value.

◆ name

const char* Zivid::Settings::RegionOfInterest::Box::name { "Box" }
staticconstexpr

The name of this value.

◆ nodeType

DataModel::NodeType Zivid::Settings::RegionOfInterest::Box::nodeType = DataModel::NodeType::group
staticconstexpr

The type of this node.

◆ path

const char* Zivid::Settings::RegionOfInterest::Box::path { "RegionOfInterest/Box" }
staticconstexpr

The full path for this value.


The documentation for this class was generated from the following file: