Sampling
Controls the projected light color and which pixels are sampled for the 3D capture.
For guidance on choosing these settings, see Sampling (3D).
-
class Sampling
Sampling settings.
Public Functions
-
Sampling()
Default constructor.
-
template<typename ...Args>
inline explicit Sampling(Args&&... args) 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
Samplingthen invokingset(args).The provided arguments must be descendants of
Sampling. These types can be provided:
-
template<typename ...Args>
inline void set(Args&&... args) Set multiple arguments.
The method invokes
set(arg)with each of the provided arguments.The provided arguments must be descendants of
Sampling. These types can be provided:
-
template<typename ...Args>
inline Sampling copyWith(Args&&... args) const Returns a copy of this object with the given argument(s) set to the new value(s)
Creates a copy of this Sampling 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
Sampling. These types can be provided:
-
template<typename F>
inline 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>
inline void forEach(const F &f) Run the given function on each direct member with the value of the member as parameter.
-
std::string toString() const
Get the value as string.
Public Static Attributes
-
static constexpr DataModel::NodeType nodeType = DataModel::NodeType::group
The type of this node.
-
static constexpr const char *path = {"Sampling"}
The full path for this value.
-
static constexpr const char *name = {"Sampling"}
The name of this value.
- static constexpr const char * description = { R"description(Samplingsettings.)description" }
The description for this value.
Friends
-
class Color
Choose how to sample colors for the point cloud.
rgboption gives an image with full colors.grayscaleoption gives a grayscale (r=g=b) image, which can be acquired faster than full colors.rgbStrongAmbientLightoption gives an image with full colors and reduced color noise. This option should be chosen only for applications which suffer from high color noise and with high amounts of ambient light in the scene.rgbAmbientSuppressionoption gives an image with full colors while suppressing the ambient light. The Zivid 2+R and Zivid 3 cameras suppress ambient light by default, and therefore do not need the additional optionrgbAmbientSuppression.
The
grayscale,rgbStrongAmbientLightandrgbAmbientSuppressionoptions are 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/Colorfield. 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.Public Types
Public Functions
-
Color() = default
Default constructor.
-
ValueType value() const
Get the value.
If this object does not contain a value (see hasValue) then this method throws an exception.
-
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.
Public Static 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 { R"description(Choose how to sample colors for the point cloud.- `rgb` option gives an image with full colors.- `grayscale` option gives a grayscale(r=g=b) image, whichcan be acquired faster than full colors.- `rgbStrongAmbientLight` option gives an image with full colors and reduced colornoise. This option should be chosen only for applications whichsuffer from highcolornoise and with high amounts of ambient light in thescene.- `rgbAmbientSuppression` option gives an image with full colors whilesuppressing the ambient light. The Zivid 2+R and Zivid 3 cameras suppress ambientlight by default, and therefore do not need the additional option`rgbAmbientSuppression`.The `grayscale`, `rgbStrongAmbientLight` and `rgbAmbientSuppression` options are not available on all camera models.This setting is deprecated as of SDK 2.14. This setting will be removed in the next SDK majorversion (SDK 3.0). The recommended way to do a 2D+3D capture is to set a `Settings2D` objectin the `Settings/Color` field. Tip: If you want to convert an existing settings.yml file tothe recommended API, you can import the .yml file into Zivid Studio and then re-export it to.yml.)description" }
The description for this value.
-
class Pixel
For Zivid 2 and Zivid 2+, this setting controls whether to read out the full image sensor and use white projector light or to subsample pixels for specific color channels with corresponding projector light.
Picking a specific color channel can help reduce noise and effects of ambient light - projecting blue light is recommended.
For Zivid 2+R and Zivid 3, the user does not have to set the projection color and should only consider whether to scale the resolution
by2x2orby4x4. Both of these modes will boost the signal strength by about 4x compared toall, so the user should consider a corresponding reduction in exposure time.Sampling at a decreased resolution decreases capture time, as less data will be captured and processed.
Public Types
Public Functions
-
Pixel() = default
Default constructor.
-
ValueType value() const
Get the value.
If this object does not contain a value (see hasValue) then this method throws an exception.
-
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.
Public Static Attributes
-
static constexpr DataModel::NodeType nodeType = DataModel::NodeType::leafValue
The type of this node.
-
static constexpr const char *path = {"Sampling/Pixel"}
The full path for this value.
-
static constexpr const char *name = {"Pixel"}
The name of this value.
- static constexpr const char * description {R"description(For Zivid 2 and Zivid 2+, this setting controls whether to read out the full image sensor anduse white projector light or to subsample pixels for specificcolorchannels withcorresponding projector light. Picking a specificcolorchannel can help reduce noiseand effects of ambient light - projecting blue light is recommended.For Zivid 2+R and Zivid 3, the user does not have toset the projection colorand should onlyconsider whether to scale the resolution `by2x2` or `by4x4`. Both of these modeswill boost the signal strength by about 4x compared to `all`, so the user shouldconsider a corresponding reduction in exposure time.Samplingat a decreased resolution decreases capture time, as less data will be captured and processed.)description"}
The description for this value.
-
Pixel() = default
-
Sampling()
-
struct SamplingGroup
Sampling settings.
Public Types
-
enum class ColorOption : std::underlying_type<Zivid::Settings::Sampling::Color::ValueType>::type
Choose how to sample colors for the point cloud.
rgboption gives an image with full colors.grayscaleoption gives a grayscale (r=g=b) image, which can be acquired faster than full colors.rgbStrongAmbientLightoption gives an image with full colors and reduced color noise. This option should be chosen only for applications which suffer from high color noise and with high amounts of ambient light in the scene.rgbAmbientSuppressionoption gives an image with full colors while suppressing the ambient light. The Zivid 2+R and Zivid 3 cameras suppress ambient light by default, and therefore do not need the additional optionrgbAmbientSuppression.
The
grayscale,rgbStrongAmbientLightandrgbAmbientSuppressionoptions are 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/Colorfield. 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.Values:
-
enumerator Rgb
-
enumerator Disabled
-
enumerator Grayscale
-
enumerator RgbStrongAmbientLight
-
enumerator RgbAmbientSuppression
-
enum class PixelOption : std::underlying_type<Zivid::Settings::Sampling::Pixel::ValueType>::type
For Zivid 2 and Zivid 2+, this setting controls whether to read out the full image sensor and use white projector light or to subsample pixels for specific color channels with corresponding projector light.
Picking a specific color channel can help reduce noise and effects of ambient light - projecting blue light is recommended.
For Zivid 2+R and Zivid 3, the user does not have to set the projection color and should only consider whether to scale the resolution
by2x2orby4x4. Both of these modes will boost the signal strength by about 4x compared toall, so the user should consider a corresponding reduction in exposure time.Sampling at a decreased resolution decreases capture time, as less data will be captured and processed.
Values:
-
enumerator All
-
enumerator BlueSubsample2x2
-
enumerator RedSubsample2x2
-
enumerator BlueSubsample4x4
-
enumerator RedSubsample4x4
-
enumerator By2x2
-
enumerator By4x4
-
enumerator All
Public Functions
-
inline SamplingGroup()
Constructor.
- SamplingGroup ^ CopyWith (CopyWithDelegate ^ delegate)
Create a clone (deep copy) of the current instance and invoke delegate on the clone.
Creates a clone (deep copy) of this object, then invokes the delegate function on the clone, and finally returns the clone. This method can be used to create a clone of an instance and then change one or more properties on the clone in one method call. The current instance is unchanged.
- SamplingGroup ^ Clone ()
Create a clone (deep copy) of the current instance.
- System::String ^ ToString () override
Get string representation of the object.
Properties
-
System::Nullable<ColorOption> Color
Choose how to sample colors for the point cloud.
rgboption gives an image with full colors.grayscaleoption gives a grayscale (r=g=b) image, which can be acquired faster than full colors.rgbStrongAmbientLightoption gives an image with full colors and reduced color noise. This option should be chosen only for applications which suffer from high color noise and with high amounts of ambient light in the scene.rgbAmbientSuppressionoption gives an image with full colors while suppressing the ambient light. The Zivid 2+R and Zivid 3 cameras suppress ambient light by default, and therefore do not need the additional optionrgbAmbientSuppression.
The
grayscale,rgbStrongAmbientLightandrgbAmbientSuppressionoptions are 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/Colorfield. 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.
-
System::Nullable<PixelOption> Pixel
For Zivid 2 and Zivid 2+, this setting controls whether to read out the full image sensor and use white projector light or to subsample pixels for specific color channels with corresponding projector light.
Picking a specific color channel can help reduce noise and effects of ambient light - projecting blue light is recommended.
For Zivid 2+R and Zivid 3, the user does not have to set the projection color and should only consider whether to scale the resolution
by2x2orby4x4. Both of these modes will boost the signal strength by about 4x compared toall, so the user should consider a corresponding reduction in exposure time.Sampling at a decreased resolution decreases capture time, as less data will be captured and processed.
-
enum class ColorOption : std::underlying_type<Zivid::Settings::Sampling::Color::ValueType>::type
- class Sampling(
- color: str | None = _zivid.Settings.Sampling.Color().value,
- pixel: str | None = _zivid.Settings.Sampling.Pixel().value,
Sampling settings.
- class Color
Choose how to sample colors for the point cloud. -
rgboption gives an image with full colors. -grayscaleoption gives a grayscale (r=g=b) image, which can be acquired faster than full colors. -rgbStrongAmbientLightoption gives an image with full colors and reduced color noise. This option should be chosen only for applications which suffer from high color noise and with high amounts of ambient light in the scene. -rgbAmbientSuppressionoption gives an image with full colors while suppressing the ambient light. The Zivid 2+R and Zivid 3 cameras suppress ambient light by default, and therefore do not need the additional optionrgbAmbientSuppression. Thegrayscale,rgbStrongAmbientLightandrgbAmbientSuppressionoptions are 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 theSettings/Colorfield. 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.
- class Pixel
For Zivid 2 and Zivid 2+, this setting controls whether to read out the full image sensor and use white projector light or to subsample pixels for specific color channels with corresponding projector light. Picking a specific color channel can help reduce noise and effects of ambient light - projecting blue light is recommended. For Zivid 2+R and Zivid 3, the user does not have to set the projection color and should only consider whether to scale the resolution
by2x2orby4x4. Both of these modes will boost the signal strength by about 4x compared toall, so the user should consider a corresponding reduction in exposure time. Sampling at a decreased resolution decreases capture time, as less data will be captured and processed.
- property color
Choose how to sample colors for the point cloud. -
rgboption gives an image with full colors. -grayscaleoption gives a grayscale (r=g=b) image, which can be acquired faster than full colors. -rgbStrongAmbientLightoption gives an image with full colors and reduced color noise. This option should be chosen only for applications which suffer from high color noise and with high amounts of ambient light in the scene. -rgbAmbientSuppressionoption gives an image with full colors while suppressing the ambient light. The Zivid 2+R and Zivid 3 cameras suppress ambient light by default, and therefore do not need the additional optionrgbAmbientSuppression. Thegrayscale,rgbStrongAmbientLightandrgbAmbientSuppressionoptions are 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 theSettings/Colorfield. 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.
- property pixel
For Zivid 2 and Zivid 2+, this setting controls whether to read out the full image sensor and use white projector light or to subsample pixels for specific color channels with corresponding projector light. Picking a specific color channel can help reduce noise and effects of ambient light - projecting blue light is recommended. For Zivid 2+R and Zivid 3, the user does not have to set the projection color and should only consider whether to scale the resolution
by2x2orby4x4. Both of these modes will boost the signal strength by about 4x compared toall, so the user should consider a corresponding reduction in exposure time. Sampling at a decreased resolution decreases capture time, as less data will be captured and processed.