Back to Adaptive Vision Library website

You are here: Start » Function Reference » Geometry 2D Basics » CreateRandomPointArray

CreateRandomPointArray


Header:AVL.h
Namespace:avl

Creates array of random points inside given box.

Syntax

C++
C#
 
void avl::CreateRandomPointArray
(
	const int inLength,
	const avl::Box& inBox,
	const float inStep,
	atl::Optional<int> inSeed,
	atl::Array< avl::Point2D >& outArray
)

Parameters

Name Type Range Default Description
inLength const int 1 - + 10 Length of output array
inBox const Box& Bounding box of generated point
inStep const float 0.0001 - 1.0f Minimal difference between two generated values on each coordinate
inSeed Optional<int> NIL Random seed
outArray ArrayPoint2D >&

Errors

List of possible exceptions:

Error type Description
DomainError Value of inStep is greater than height of box in CreateRandomPointArray.
DomainError Value of inStep is greater than width of box in CreateRandomPointArray.