builtin/basetypes.h¶
Namespaces¶
| Name |
|---|
| cvedia |
| cvedia::rt API for controlling the server and lifecycle management of runtime instances. |
Classes¶
| Name | |
|---|---|
| class | cvedia::rt::Point_ |
| class | cvedia::rt::Size_ |
| class | cvedia::rt::Rect_ |
| struct | cvedia::rt::RoiNormResult |
Types¶
| Name | |
|---|---|
| enum class | RoiRoundPolicy |
| enum class | RoiEvenPolicy |
| typedef std::array< float, 4 > | Color4f |
| typedef Point_< int > | Point2i |
| typedef Point_< int64_t > | Point2l |
| typedef Point_< float > | Point2f |
| typedef Point_< double > | Point2d |
| typedef Point2i | Point |
| typedef Size_< int > | Size2i |
| typedef Size_< int64_t > | Size2l |
| typedef Size_< float > | Size2f |
| typedef Size_< double > | Size2d |
| typedef Size2i | Size |
| typedef Rect_< int > | Rect2i |
| typedef Rect_< float > | Rect2f |
| typedef Rect_< double > | Rect2d |
| typedef Rect2i | Rect |
Functions¶
| Name | |
|---|---|
| int | roiClampInt(int v, int lo, int hi) |
| int | roiRoundToInt(float v, RoiRoundPolicy policy) |
| int | roiAlignEven(int v, RoiEvenPolicy policy) |
| RoiNormResult | normalizeRoi(Rect2f rc, Size const & srcSize, bool relative, RoiRoundPolicy xyRound, RoiRoundPolicy whRound, RoiEvenPolicy xyEven, RoiEvenPolicy whEven, bool clampToBounds, int minWidth, int minHeight) |
| RoiNormResult | normalizeNv12Roi(Rect2f rc, Size const & srcSize, bool relative, bool clampToBounds =true) |
| RoiNormResult | normalizeYv12Roi(Rect2f rc, Size const & srcSize, bool relative, bool clampToBounds =true) |
| template <typename Tp > Rect_< Tp > & |
operator&=(Rect_< Tp > & a, Rect_< Tp > const & b) |
| template <typename Tp > Rect< _Tp > & |
**[operator |
| template <typename Tp > Rect_< Tp > |
operator&(Rect_< Tp > const & a, Rect_< Tp > const & b) |
| template <typename Tp > Rect< _Tp > |
**[operator |
| template <typename Tp > Point_< Tp > & |
operator+=(Point_< Tp > & a, Point_< Tp > const & b) |
| template <typename Tp > Point_< Tp > & |
operator-=(Point_< Tp > & a, Point_< Tp > const & b) |
| template <typename Tp > Point_< Tp > & |
operator*=(Point_< Tp > & a, int b) |
| template <typename Tp > Point_< Tp > & |
operator*=(Point_< Tp > & a, float b) |
| template <typename Tp > Point_< Tp > & |
operator*=(Point_< Tp > & a, double b) |
| template <typename Tp > Point_< Tp > & |
operator/=(Point_< Tp > & a, int b) |
| template <typename Tp > Point_< Tp > & |
operator/=(Point_< Tp > & a, float b) |
| template <typename Tp > Point_< Tp > & |
operator/=(Point_< Tp > & a, double b) |
| template <typename Tp > Point_< Tp > |
operator+(Point_< Tp > const & a, Point_< Tp > const & b) |
| template <typename Tp > Point_< Tp > |
operator-(Point_< Tp > const & a, Point_< Tp > const & b) |
| template <typename Tp > Point_< Tp > |
operator-(Point_< Tp > const & a) |
| template <typename Tp > Point_< Tp > |
operator*(Point_< Tp > const & a, int b) |
| template <typename Tp > Point_< Tp > |
operator*(int a, Point_< Tp > const & b) |
| template <typename Tp > Point_< Tp > |
operator*(Point_< Tp > const & a, float b) |
| template <typename Tp > Point_< Tp > |
operator*(float a, Point_< Tp > const & b) |
| template <typename Tp > Point_< Tp > |
operator*(Point_< Tp > const & a, double b) |
| template <typename Tp > Point_< Tp > |
operator*(double a, Point_< Tp > const & b) |
| template <typename Tp > double |
norm(Point_< Tp > const & pt) |
Defines¶
| Name | |
|---|---|
| TO_CVPOINT_FROMRELATIVE(arg, mat) | |
| TO_CVPOINT(arg) | |
| TO_CVPOINTD(arg) | |
| TO_CVRECT(arg) | |
| TO_CVRECT_FROMRELATIVE(arg, mat) | |
| TO_CVRECTD(arg) | |
| TO_CVRECTI(arg) | |
| TO_CVRECTF(arg) | |
| TO_CVCOLOR(arg) | |
| TO_CVCOLOR3(arg) | |
| TO_CVCOLOR_OPAQUE_8(arg) | |
| RGBA32_TO_BGRA8(src) | |
| RGBA32_TO_BGRA8_OPAQUE(src) | |
| FROM_CVRECT(arg) | |
| FROM_CVPOINT(arg) | |
| BOUNDED_COORD(arg) | |
| BOUNDED_POINT(arg) |
Types Documentation¶
enum RoiRoundPolicy¶
| Enumerator | Value | Description |
|---|---|---|
| Floor | ||
| Ceil | ||
| Round |
enum RoiEvenPolicy¶
| Enumerator | Value | Description |
|---|---|---|
| None | ||
| Down | ||
| Up |
typedef Color4f¶
typedef std::array<float, 4> Color4f;
typedef Point2i¶
typedef Point_<int> Point2i;
typedef Point2l¶
typedef Point_<int64_t> Point2l;
typedef Point2f¶
typedef Point_<float> Point2f;
typedef Point2d¶
typedef Point_<double> Point2d;
typedef Point¶
typedef Point2i Point;
typedef Size2i¶
typedef Size_<int> Size2i;
typedef Size2l¶
typedef Size_<int64_t> Size2l;
typedef Size2f¶
typedef Size_<float> Size2f;
typedef Size2d¶
typedef Size_<double> Size2d;
typedef Size¶
typedef Size2i Size;
typedef Rect2i¶
typedef Rect_<int> Rect2i;
typedef Rect2f¶
typedef Rect_<float> Rect2f;
typedef Rect2d¶
typedef Rect_<double> Rect2d;
typedef Rect¶
typedef Rect2i Rect;
Functions Documentation¶
function roiClampInt¶
inline int roiClampInt(
int v,
int lo,
int hi
)
function roiRoundToInt¶
inline int roiRoundToInt(
float v,
RoiRoundPolicy policy
)
function roiAlignEven¶
inline int roiAlignEven(
int v,
RoiEvenPolicy policy
)
function normalizeRoi¶
inline RoiNormResult normalizeRoi(
Rect2f rc,
Size const & srcSize,
bool relative,
RoiRoundPolicy xyRound,
RoiRoundPolicy whRound,
RoiEvenPolicy xyEven,
RoiEvenPolicy whEven,
bool clampToBounds,
int minWidth,
int minHeight
)
function normalizeNv12Roi¶
inline RoiNormResult normalizeNv12Roi(
Rect2f rc,
Size const & srcSize,
bool relative,
bool clampToBounds =true
)
function normalizeYv12Roi¶
inline RoiNormResult normalizeYv12Roi(
Rect2f rc,
Size const & srcSize,
bool relative,
bool clampToBounds =true
)
function operator&=¶
template <typename Tp >
inline Rect_< Tp > & operator&=(
Rect_< Tp > & a,
Rect_< Tp > const & b
)
function operator|=¶
template <typename _Tp >
static inline Rect_< _Tp > & operator|=(
Rect_< _Tp > & a,
const Rect_< _Tp > & b
)
function operator&¶
template <typename Tp >
inline Rect_< Tp > operator&(
Rect_< Tp > const & a,
Rect_< Tp > const & b
)
function operator|¶
template <typename _Tp >
static inline Rect_< _Tp > operator|(
const Rect_< _Tp > & a,
const Rect_< _Tp > & b
)
function operator+=¶
template <typename Tp >
static inline Point_< Tp > & operator+=(
Point_< Tp > & a,
Point_< Tp > const & b
)
function operator-=¶
template <typename Tp >
static inline Point_< Tp > & operator-=(
Point_< Tp > & a,
Point_< Tp > const & b
)
function operator*=¶
template <typename Tp >
static inline Point_< Tp > & operator*=(
Point_< Tp > & a,
int b
)
function operator*=¶
template <typename Tp >
static inline Point_< Tp > & operator*=(
Point_< Tp > & a,
float b
)
function operator*=¶
template <typename Tp >
static inline Point_< Tp > & operator*=(
Point_< Tp > & a,
double b
)
function operator/=¶
template <typename Tp >
static inline Point_< Tp > & operator/=(
Point_< Tp > & a,
int b
)
function operator/=¶
template <typename Tp >
static inline Point_< Tp > & operator/=(
Point_< Tp > & a,
float b
)
function operator/=¶
template <typename Tp >
static inline Point_< Tp > & operator/=(
Point_< Tp > & a,
double b
)
function operator+¶
template <typename Tp >
static inline Point_< Tp > operator+(
Point_< Tp > const & a,
Point_< Tp > const & b
)
function operator-¶
template <typename Tp >
static inline Point_< Tp > operator-(
Point_< Tp > const & a,
Point_< Tp > const & b
)
function operator-¶
template <typename Tp >
static inline Point_< Tp > operator-(
Point_< Tp > const & a
)
function operator*¶
template <typename Tp >
static inline Point_< Tp > operator*(
Point_< Tp > const & a,
int b
)
function operator*¶
template <typename Tp >
static inline Point_< Tp > operator*(
int a,
Point_< Tp > const & b
)
function operator*¶
template <typename Tp >
static inline Point_< Tp > operator*(
Point_< Tp > const & a,
float b
)
function operator*¶
template <typename Tp >
static inline Point_< Tp > operator*(
float a,
Point_< Tp > const & b
)
function operator*¶
template <typename Tp >
static inline Point_< Tp > operator*(
Point_< Tp > const & a,
double b
)
function operator*¶
template <typename Tp >
static inline Point_< Tp > operator*(
double a,
Point_< Tp > const & b
)
function norm¶
template <typename Tp >
static inline double norm(
Point_< Tp > const & pt
)
Macros Documentation¶
define TO_CVPOINT_FROMRELATIVE¶
#define TO_CVPOINT_FROMRELATIVE(
arg,
mat
)
cv::Point2f(arg.x * static_cast<float>(mat.cols), arg.y * static_cast<float>(mat.rows))
define TO_CVPOINT¶
#define TO_CVPOINT(
arg
)
cv::Point2f(arg.x, arg.y)
define TO_CVPOINTD¶
#define TO_CVPOINTD(
arg
)
cv::Point(arg.x, arg.y)
define TO_CVRECT¶
#define TO_CVRECT(
arg
)
cv::Rect2f(arg.x, arg.y, static_cast<float>(arg.width), static_cast<float>(arg.height))
define TO_CVRECT_FROMRELATIVE¶
#define TO_CVRECT_FROMRELATIVE(
arg,
mat
)
cv::Rect2f(arg.x * static_cast<float>(mat.cols), arg.y * static_cast<float>(mat.rows), static_cast<float>(arg.width) * static_cast<float>(mat.cols), static_cast<float>(arg.height) * static_cast<float>(mat.rows))
define TO_CVRECTD¶
#define TO_CVRECTD(
arg
)
cv::Rect(arg.x, arg.y, static_cast<float>(arg.width), static_cast<float>(arg.height))
define TO_CVRECTI¶
#define TO_CVRECTI(
arg
)
cv::Rect2i(arg.x, arg.y, static_cast<int>(arg.width), static_cast<int>(arg.height))
define TO_CVRECTF¶
#define TO_CVRECTF(
arg
)
cv::Rect2f(arg.x, arg.y, static_cast<float>(arg.width), static_cast<float>(arg.height))
define TO_CVCOLOR¶
#define TO_CVCOLOR(
arg
)
cv::Scalar(arg[0], arg[1], arg[2], arg[3])
define TO_CVCOLOR3¶
#define TO_CVCOLOR3(
arg
)
cv::Scalar(arg[0], arg[1], arg[2])
define TO_CVCOLOR_OPAQUE_8¶
#define TO_CVCOLOR_OPAQUE_8(
arg
)
cv::Scalar(arg[0], arg[1], arg[2], 255)
define RGBA32_TO_BGRA8¶
#define RGBA32_TO_BGRA8(
src
)
cv::Scalar{src[2] * 255.f, src[1] * 255.f, src[0] * 255.f, src[3]}
define RGBA32_TO_BGRA8_OPAQUE¶
#define RGBA32_TO_BGRA8_OPAQUE(
src
)
cv::Scalar{src[2] * 255.f, src[1] * 255.f, src[0] * 255.f, 255.f}
define FROM_CVRECT¶
#define FROM_CVRECT(
arg
)
Rect2f(static_cast<float>(arg.x), static_cast<float>(arg.y), static_cast<float>(arg.width), static_cast<float>(arg.height))
define FROM_CVPOINT¶
#define FROM_CVPOINT(
arg
)
Point2f(static_cast<float>(arg.x), static_cast<float>(arg.y))
define BOUNDED_COORD¶
#define BOUNDED_COORD(
arg
)
std::min(std::max(0.f, arg), 1.f)
define BOUNDED_POINT¶
#define BOUNDED_POINT(
arg
)
Point2f(static_cast<float>(BOUNDED_COORD(arg.x)), static_cast<float>(BOUNDED_COORD(arg.y)))