openPSTD
2.0
Open source simulation for sound propagation in urban environments
|
This class is specificaly for horizontal edges and vertical edges. More...
#include <Edges.h>
Public Member Functions | |
Edge (float PosInDim, int dim, float start, float end, float absorption, bool localReacting) | |
Edge (QVector2D start, QVector2D end, float absorption, bool localReacting) | |
bool | IsOnlyInDim (int dim) const |
bool | IsVertical () const |
bool | IsHorizontal () const |
QVector2D | GetStart () const |
QVector2D | GetEnd () const |
float | GetAbsorption () const |
float | GetLocalReacting () const |
bool | OnSameLine (const Edge &edge) const |
Tests if the 2 edges are on the same line. More... | |
std::vector< Edge > | Substract (const Edge &edge) const |
Static Public Member Functions | |
static bool | OnSameLine (const Edge &edge1, const Edge &edge2) |
static std::vector< Edge > | SubstractEdgeFromList (std::vector< Edge > edges, Edge rhs) |
static std::vector< Edge > | SubstractListFromList (std::vector< Edge > lhs, std::vector< Edge > rhs) |
static std::vector< Edge > | SubstractListFromEdge (Edge lhs, std::vector< Edge > rhs) |
static std::vector< Edge > | SubstractListFromEdge (Edge lhs, std::vector< Edge > rhs, std::vector< int > exceptIndices) |
This class is specificaly for horizontal edges and vertical edges.
No fields are added to this class. It is possible to send an object of this type directly to the GPU and draw lines.
bool OpenPSTD::GUI::Edge::OnSameLine | ( | const Edge & | edge | ) | const |
Tests if the 2 edges are on the same line.
This only works if they are on horizontal of vertical.