Back to Adaptive Vision Library websiteYou are here:
Start »
Function Reference »
Region Basics »
CreateRectangleBorderRegion
CreateRectangleBorderRegion
Creates a frame-shaped region with given parameters.
Syntax
C++
C#
void avl::CreateRectangleBorderRegion
(
const avl::Rectangle2D& inRectangle,
atl::Optional<const avl::CoordinateSystem2D&> inRectangleAlignment,
float inBorderWidth,
avl::BorderPosition::Type inBorderPosition,
int inFrameWidth,
int inFrameHeight,
avl::Region& outRegion,
atl::Optional<avl::Rectangle2D&> outAlignedRectangle = atl::NIL
)
void CreateRectangleBorderRegion
(
Rectangle2D inRectangle,
CoordinateSystem2D? inRectangleAlignment,
float inBorderWidth,
BorderPosition inBorderPosition,
int inFrameWidth,
int inFrameHeight,
out Region outRegion,
out Rectangle2D? outAlignedRectangle
)
Parameters
|
Name |
Type |
Range |
Default |
Description |
|
inRectangle |
const Rectangle2D& |
|
|
|
|
inRectangleAlignment |
Optional<const CoordinateSystem2D&> |
|
NIL |
Adjusts the rectangle to the position of the inspected object |
|
inBorderWidth |
float |
0.0 - |
1.0f |
|
|
inBorderPosition |
BorderPosition::Type |
|
Centered |
|
|
inFrameWidth |
int |
0 - |
|
Width of the created region's frame |
|
inFrameHeight |
int |
0 - |
|
Height of the created region's frame |
|
outRegion |
Region& |
|
|
Output region |
|
outAlignedRectangle |
Optional<Rectangle2D&> |
|
NIL |
The input rectangle transformed to the absolute coordinate system |
Errors
Error type |
Description |
DomainError |
Incorrect BorderPosition in CreateRectangleBorderRegion. |