Enrollment 28.2.0
Loading...
Searching...
No Matches

Segment detected in print capture Usually the segment has also position that is assigned by segmentation algorithm. More...

#include <PrintSegment.h>

Collaboration diagram for PrintSegment:

Public Member Functions

bool HasPosition () const
 It checks if position is set.
void SetPosition (const PrintPosition &position)
 Set the Position.
PrintPosition GetPosition ()
 Returns print position.
std::shared_ptr< PrintSegment > Resize (Rectangle::Width newWidth, Rectangle::Height newHeight) const
 Create new segment with given width and height.
std::shared_ptr< Print > ToPrint ()
 It transforms segment to Print.
std::shared_ptr< Print > ToPrint (const PrintCropConfiguration &cfg)
 It transforms segment to Print.
void WriteTo (Writer &writer) const final
 Function serializes slap segment.

Public Attributes

const Rectangle roundingBox
 Found rounding box of segmented fingertip.

Detailed Description

Segment detected in print capture Usually the segment has also position that is assigned by segmentation algorithm.

In rare cases the segmentation algorithm does not detect position. Then it is necessary that user sets correct position to be possible to create Print for further processing.

Member Function Documentation

◆ GetPosition()

PrintPosition GetPosition ( )
inline

Returns print position.

Returns
print position
Exceptions
EnrollmentRuntimeExceptionwhen no print position

◆ HasPosition()

bool HasPosition ( ) const
inline

It checks if position is set.

Returns
true when position is set
false when position is not set

◆ Resize()

std::shared_ptr< PrintSegment > Resize ( Rectangle::Width newWidth,
Rectangle::Height newHeight ) const
inline

Create new segment with given width and height.

The center and angle of segment will remain same.

Parameters
newWidthnew width of segment
newHeightnew height of segment
Returns
new segment with corresponding width and high

References roundingBox.

◆ SetPosition()

void SetPosition ( const PrintPosition & position)
inline

Set the Position.

Parameters
positionPrintPosition of fingertip

◆ ToPrint() [1/2]

std::shared_ptr< Print > ToPrint ( )
inline

It transforms segment to Print.

Usually the segment has also position that is assigned by segmentation algorithm. In rare cases the segmentation algorithm does not detect position. Then it is necessary that user sets correct position to be possible to create Print for further processing. Default PrintCropConfiguration is used for cropping.

Returns
Print
Exceptions
EnrollmentExceptionwhen position is not set

References ToPrint().

Referenced by ToPrint().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ToPrint() [2/2]

std::shared_ptr< Print > ToPrint ( const PrintCropConfiguration & cfg)
inline

It transforms segment to Print.

Usually the segment has also position that is assigned by segmentation algorithm. In rare cases the segmentation algorithm does not detect position. Then it is necessary that user sets correct position to be possible to create Print for further processing.

Parameters
cfgcrop configuration
Returns
Print
Exceptions
EnrollmentRuntimeExceptionwhen position is not set

References Print::Create(), and roundingBox.

Here is the call graph for this function:

◆ WriteTo()

void WriteTo ( Writer & writer) const
inlinefinalvirtual

Function serializes slap segment.

Parameters
writerused to serialize PrintSegment.

Implements Serializable.

References roundingBox.


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