openPSTD  2.0
Open source simulation for sound propagation in urban environments
Public Member Functions | Static Public Member Functions | List of all members
OpenPSTD::GUI::Edge Class Reference

This class is specificaly for horizontal edges and vertical edges. More...

#include <Edges.h>

Collaboration diagram for OpenPSTD::GUI::Edge:
Collaboration graph

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< EdgeSubstract (const Edge &edge) const
 

Static Public Member Functions

static bool OnSameLine (const Edge &edge1, const Edge &edge2)
 
static std::vector< EdgeSubstractEdgeFromList (std::vector< Edge > edges, Edge rhs)
 
static std::vector< EdgeSubstractListFromList (std::vector< Edge > lhs, std::vector< Edge > rhs)
 
static std::vector< EdgeSubstractListFromEdge (Edge lhs, std::vector< Edge > rhs)
 
static std::vector< EdgeSubstractListFromEdge (Edge lhs, std::vector< Edge > rhs, std::vector< int > exceptIndices)
 

Detailed Description

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.

Member Function Documentation

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.


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