Core module¶
Point¶
-
template<class
T
>
classPoint_
¶ The 2D point class.
Public Functions
-
Point_
(T x_ = T{0}, T y_ = T{0})¶ The Point constructor.
-
~Point_
()¶ The Point destructor.
-
Point_<T> &
operator=
(const Point_ &p)¶ Assignment operator.
-
Point_<T> &
operator+=
(const Point_ &p)¶
-
Point_<T> &
operator-=
(const Point_ &p)¶
-
Point_<T>
operator-
() const¶
-
Point_<T> &
operator*=
(T t)¶
-
Point_<T> &
operator/=
(T t)¶
-
T
dot
(const Point_ &p) const¶ Dot product.
-
T
det
(const Point_ &p) const¶ Determinant.
-
bool
operator==
(const Point_ &p) const¶
-
bool
operator!=
(const Point_ &p) const¶
-
bool
operator<
(const Point_ &p) const¶
-
bool
operator>
(const Point_ &p) const¶
-
double
norm
() const¶ Norm.
-
Point_<T>
normalize
() const¶ Normalization.
-
operator cv::Point_<T>
() const¶ Implicit convertion to cv::Point_<T>.
-
Array2D¶
-
template<class
T
>
classArray2D
¶ The 2-dimensional array class.
This class is not supported by Python because this can be altered by Python’s buildin list.
Public Functions
-
Array2D
(int rows, int cols, const T &value)¶ Allocate memory space and fill it with the specified value.
- Parameters
[in] rows
: Number of rows[in] cols
: Number of columns[in] value
: A value with which the array is filled
-
Array2D<T> &
operator=
(const Array2D &ary)¶ Assignment operator (copy).
-
Array2D<T> &
operator=
(Array2D &&ary)¶ Assignment operator (move).
-
T &
operator()
(int i, int j) const¶ Accessor.
-
int
cols
() const¶ Return # of rows.
-
int
rows
() const¶ Return # of columns.
-
Random¶
-
class
Random
¶ Random number generator using Mersenne-twister.
Public Functions
-
LIME_METHOD_API
Random
(uint32_t seed = UINT_MAX)¶
-
LIME_METHOD_API int lime::Random::nextInt()
Generate a random 32-bit signed integer.
-
LIME_METHOD_API int lime::Random::nextInt(const int n)
Generate a random integer from [0, n-1].
-
LIME_METHOD_API double lime::Random::nextReal()
Generate a floating point random number from [0, 1).
-
LIME_METHOD_API double lime::Random::normal()
Generate a random number from normal distribution.
-
LIME_METHOD_API