PLaSK library

Loading...
Searching...
No Matches
Public Types | Static Public Member Functions | Static Public Attributes | List of all members
plask::Primitive< 2 > Struct Reference

Specialization of Primitive, which define types of primitives and constants in space with 2 dimensions. More...

`#include <plask/geometry/primitives.hpp>`

Collaboration diagram for plask::Primitive< 2 >:
[legend]

## Public Types
enum | Direction { DIRECTION_TRAN = 0 , DIRECTION_VERT = 1 }
typedef Box2D | Box
| Rectangle type in 2d space.
typedef Vec< 2, double > | DVec
| Real (double) vector type in 2d space.

## Static Public Member Functions
static void | ensureIsValidDirection (unsigned direction)
static bool | vecFuzzyCompare (const DVec &a, const DVec &b)
| Compare if `a` < with reasonable tollerance.

## Static Public Attributes
static const int | dim = 2
| Number of dimensions (2).
static const DVec | ZERO_VEC = Vec<2>(0.0, 0.0)
| Zeroed 2d vector.
static const DVec | NAN_VEC = Vec<2>(std::numeric_limits<double>::quiet_NaN(), std::numeric_limits<double>::quiet_NaN())
| NaNed 2d vector.
static const Box | INF_BOX = Box2D(- std::numeric_limits<double>::infinity(), - std::numeric_limits<double>::infinity(), std::numeric_limits<double>::infinity(), std::numeric_limits<double>::infinity())
| infinit box

## Detailed Description

Specialization of Primitive, which define types of primitives and constants in space with 2 dimensions.

Definition at line 775 of file primitives.hpp.

## Member Typedef Documentation

## ◆ Box

typedef Box2D plask::Primitive< 2 >::Box

Rectangle type in 2d space.

Definition at line 777 of file primitives.hpp.

## ◆ DVec

typedef Vec<2, double> plask::Primitive< 2 >::DVec

Real (double) vector type in 2d space.

Definition at line 780 of file primitives.hpp.

## Member Enumeration Documentation

## ◆ Direction

enum plask::Primitive< 2 >::Direction

Enumerator
DIRECTION_TRAN |
DIRECTION_VERT |

Definition at line 794 of file primitives.hpp.

## Member Function Documentation

## ◆ ensureIsValidDirection()

static void plask::Primitive< 2 >::ensureIsValidDirection | ( | unsigned | direction | ) |
| inline static

Definition at line 796 of file primitives.hpp.

## ◆ vecFuzzyCompare()

static bool plask::Primitive< 2 >::vecFuzzyCompare | ( | const DVec & | a,
|  | const DVec & | b
| ) |  |
| inline static

Compare if `a` < with reasonable tollerance.

Definition at line 801 of file primitives.hpp.

## Member Data Documentation

## ◆ dim

const int plask::Primitive< 2 >::dim = 2
| static

Number of dimensions (2).

Definition at line 783 of file primitives.hpp.

## ◆ INF_BOX

const Primitive< 2 >::Box plask::Primitive< 2 >::INF_BOX = Box2D(- std::numeric_limits<double>::infinity(), - std::numeric_limits<double>::infinity(), std::numeric_limits<double>::infinity(), std::numeric_limits<double>::infinity())
| static

infinit box

Definition at line 792 of file primitives.hpp.

## ◆ NAN_VEC

const Primitive< 2 >::DVec plask::Primitive< 2 >::NAN_VEC = Vec<2>(std::numeric_limits<double>::quiet_NaN(), std::numeric_limits<double>::quiet_NaN())
| static

NaNed 2d vector.

Definition at line 789 of file primitives.hpp.

## ◆ ZERO_VEC

const Primitive< 2 >::DVec plask::Primitive< 2 >::ZERO_VEC = Vec<2>(0.0, 0.0)
| static

Zeroed 2d vector.

Definition at line 786 of file primitives.hpp.

The documentation for this struct was generated from the following files:

- plask/geometry/primitives.hpp
- plask/geometry/primitives.cpp