IndexedLocalCoordinate.h
Go to the documentation of this file.
1 // This file is a part of the OpenSurgSim project.
2 // Copyright 2013, SimQuest Solutions Inc.
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 
16 #ifndef SURGSIM_DATASTRUCTURES_INDEXEDLOCALCOORDINATE_H
17 #define SURGSIM_DATASTRUCTURES_INDEXEDLOCALCOORDINATE_H
18 
19 #include "SurgSim/Math/Vector.h"
20 
21 namespace SurgSim
22 {
23 
24 namespace DataStructures
25 {
26 
30 {
33 
39 
41  size_t index;
42 
45 
50  bool isApprox(const IndexedLocalCoordinate& other, double precision = std::numeric_limits<double>::epsilon())
51  const;
52 };
53 
54 } // namespace DataStructures
55 
56 } // namespace SurgSim
57 
58 #endif // SURGSIM_DATASTRUCTURES_INDEXEDLOCALCOORDINATE_H
Vector.h
Definitions of small fixed-size vector types.
SurgSim
Definition: CompoundShapeToGraphics.cpp:30
SurgSim::DataStructures::IndexedLocalCoordinate
A generic (size_t index, Vector coordinate) pair.
Definition: IndexedLocalCoordinate.h:30
SurgSim::DataStructures::IndexedLocalCoordinate::index
size_t index
Numeric index to indicate the entity w.r.t which the barycentricCoordinate is defined.
Definition: IndexedLocalCoordinate.h:41
SurgSim::Math::Vector
Eigen::Matrix< double, Eigen::Dynamic, 1 > Vector
A dynamic size column vector.
Definition: Vector.h:68
SurgSim::DataStructures::IndexedLocalCoordinate::coordinate
SurgSim::Math::Vector coordinate
Coordinates with respect to the entity identified by the index.
Definition: IndexedLocalCoordinate.h:44
SurgSim::DataStructures::IndexedLocalCoordinate::isApprox
bool isApprox(const IndexedLocalCoordinate &other, double precision=std::numeric_limits< double >::epsilon()) const
Comparison method 'isApprox'.
Definition: IndexedLocalCoordinate.cpp:33
SurgSim::DataStructures::IndexedLocalCoordinate::IndexedLocalCoordinate
IndexedLocalCoordinate()
Default constructor with no initialization.
Definition: IndexedLocalCoordinate.cpp:24