Class VppConfig

Nested Relationships

Nested Types

Inheritance Relationships

Base Type

Class Documentation

class VppConfig : public dai::Buffer

VppConfig message. Carries config for Virtual Projection Pattern algorithm

Public Types

enum PatchColoringType

Values:

enumerator RANDOM
enumerator MAXDIST

Public Functions

VppConfig() = default
virtual ~VppConfig()
inline float getBlending() const

Get blending factor between 0 and 1.

Returns:

Current blending value

inline void setBlending(float value)

Set blending factor between 0 and 1: resulting pixel: patchColor * blending + (1 - blending) * imgFrame.

Parameters:

value – Blending value to set

inline float getDistanceGamma() const

Get distance gamma.

Returns:

Current distance gamma

inline void setDistanceGamma(float value)

Set distance gamma.

Parameters:

value – Distance gamma to set

inline uint8_t getMaxPatchSize() const

Get maximum patch size.

Returns:

Maximum patch size

inline void setMaxPatchSize(uint8_t value)

Set maximum patch size.

Parameters:

value – Patch size to set

inline PatchColoringType getPatchColoringType() const

Get patch coloring type: UNIFORM/MAXDIST.

Returns:

Current patch coloring type

inline void setPatchColoringType(PatchColoringType type)

Set patch coloring type: UNIFORM/MAXDIST.

Parameters:

type – Patch coloring type to set

inline bool getUniformPatch() const

Check if uniform patching is enabled.

Returns:

True if uniform patching is enabled

inline void setUniformPatch(bool value)

Enable or disable uniform patching.

Parameters:

value – True to enable, false to disable

inline InjectionParameters getInjectionParameters() const

Get injection parameters.

Returns:

Current injection parameters

inline void setInjectionParameters(const InjectionParameters &params)

Set injection parameters.

Parameters:

params – Injection parameters to set

inline int getMaxNumThreads() const

Get maximum number of threads.

Returns:

Maximum number of threads

inline void setMaxNumThreads(int value)

Set maximum number of threads.

Parameters:

value – Number of threads to set

inline int getMaxFPS() const

Get maximum FPS.

Returns:

Maximum FPS

inline void setMaxFPS(int value)

Set maximum FPS.

Parameters:

value – Maximum FPS to set

inline virtual void serialize(std::vector<std::uint8_t> &metadata, DatatypeEnum &datatype) const override
DEPTHAI_SERIALIZE(VppConfig, blending, distanceGamma, maxPatchSize, patchColoringType, uniformPatch, injectionParameters, maxNumThreads, maxFPS)

Public Members

float blending = 0.5
float distanceGamma = 0.3
uint8_t maxPatchSize = 3
PatchColoringType patchColoringType = PatchColoringType::RANDOM
bool uniformPatch = true
InjectionParameters injectionParameters
int maxNumThreads = 1
int maxFPS = 0
struct InjectionParameters

Public Functions

inline bool getUseInjection() const

Check if injection is enabled False: all possible pixels will be used.

Returns:

True if injection is used

inline void setUseInjection(bool value)

Enable or disable injection.

Parameters:

value – True to use injection, false to disable

inline int getKernelSize() const

Get kernel size for injection.

Returns:

Kernel size

inline void setKernelSize(int value)

Set kernel size for injection.

Parameters:

value – Kernel size to set

inline float getTextureThreshold() const

Get texture threshold.

Returns:

Texture threshold value

inline void setTextureThreshold(float value)

Set texture threshold.

Parameters:

value – Texture threshold to set

inline float getConfidenceThreshold() const

Get confidence threshold.

Returns:

Confidence threshold value

inline void setConfidenceThreshold(float value)

Set confidence threshold.

Parameters:

value – Confidence threshold to set

inline int getMorphologyIterations() const

Get number of morphology iterations.

Returns:

Number of iterations

inline void setMorphologyIterations(int value)

Set number of morphology iterations.

Parameters:

value – Number of iterations

inline bool isUseMorphology() const

Check if morphology is used.

Returns:

True if morphology is applied

inline void setUseMorphology(bool value)

Enable or disable morphology.

Parameters:

value – True to use morphology, false to disable

DEPTHAI_SERIALIZE(InjectionParameters, useInjection, kernelSize, textureThreshold, confidenceThreshold, morphologyIterations, useMorphology)

Public Members

bool useInjection = true
int kernelSize = 3
float textureThreshold = 0.5
float confidenceThreshold = 0.5
int morphologyIterations = 5
bool useMorphology = true