ESyS-Particle
4.0.1
Main Page
Related Pages
Namespaces
Classes
Files
File List
Geometry
Corner2D.h
1
2
// //
3
// Copyright (c) 2003-2011 by The University of Queensland //
4
// Earth Systems Science Computational Centre (ESSCC) //
5
// http://www.uq.edu.au/esscc //
6
// //
7
// Primary Business: Brisbane, Queensland, Australia //
8
// Licensed under the Open Software License version 3.0 //
9
// http://www.opensource.org/licenses/osl-3.0.php //
10
// //
12
13
#ifndef __CORNER2D_H
14
#define __CORNER2D_H
15
16
//-- Project includes --
17
#include "Foundation/vec3.h"
18
#include "Geometry/Edge2D.h"
19
20
//-- STL includes --
21
#include <vector>
22
23
using
std::vector;
24
25
34
class
Corner2D
35
{
36
private
:
37
Vec3
m_p;
38
vector<Edge2D*> m_edges;
39
int
m_id;
40
41
public
:
42
Corner2D
(
const
Vec3
&,
int
);
43
44
void
addEdge
(
Edge2D
*);
45
double
sep
(
const
Vec3
&)
const
;
46
// pair<bool,double> dist(const Vec3&) const ; // signed separation according to direction of the normal
47
bool
isValidContact
(
const
Vec3
&)
const
;
48
Vec3
getDirectionFromPoint
(
const
Vec3
&)
const
;
49
void
move
(
const
Vec3
&);
50
Vec3
getPos()
const
{
return
m_p;};
51
int
getID()
const
{
return
m_id;};
52
int
getNEdges()
const
{
return
m_edges.size();};
53
Vec3
getEdgeNormal
(
int
)
const
;
54
void
applyForceToEdge
(
int
,
const
Vec3
&);
55
};
56
57
#endif // __CORNER2D_H
Generated on Wed Jun 6 2012 00:04:49 for ESyS-Particle by
1.8.1