Skip to content

Commit 0887745

Browse files
committed
First round of Reference Manual revisions
1 parent 33c7868 commit 0887745

32 files changed

+540
-459
lines changed

Documentation/BaseDoxyfile.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1396,7 +1396,7 @@ EXTRA_SEARCH_MAPPINGS =
13961396
# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will
13971397
# generate Latex output.
13981398

1399-
GENERATE_LATEX = NO
1399+
GENERATE_LATEX = YES
14001400

14011401
# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put.
14021402
# If a relative path is entered the value of OUTPUT_DIRECTORY will be

Documentation/pkglist_filter.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ def main(argv):
1717
if(index > 0):
1818
top_level = pkg[:index]
1919
lower_level = pkg[index+1:]
20-
filename="/cygdrive/c/Users/stephen/Documents/Programming/CGALDev/Documentation/" + top_level + "/doc/" + lower_level + "/PackageDescription.txt"
20+
filename="./" + top_level + "/doc/" + lower_level + "/PackageDescription.txt"
2121
else:
22-
filename="/cygdrive/c/Users/stephen/Documents/Programming/CGALDev/Documentation/" + pkg + "/doc/" + pkg + "/PackageDescription.txt"
22+
filename="./" + pkg + "/doc/" + pkg + "/PackageDescription.txt"
2323
pkgdesc = codecs.open(filename, 'r', encoding='utf-8')
2424
do_print=False
2525
for l in pkgdesc:

Polyhedron/demo/Polyhedron/Scene_polyhedron_shortest_path_item.cpp

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,8 @@ void Scene_polyhedron_shortest_path_item::get_as_edge_point(Scene_polyhedron_sho
256256
}
257257
}
258258

259-
inOutLocation.second = Barycentric_coordinate(coords[0], coords[1], coords[2]);
259+
Construct_barycentric_coordinate construct_barycentric_coordinate;
260+
inOutLocation.second = construct_barycentric_coordinate(coords[0], coords[1], coords[2]);
260261
}
261262

262263
void Scene_polyhedron_shortest_path_item::get_as_vertex_point(Scene_polyhedron_shortest_path_item::Face_location& inOutLocation)
@@ -276,7 +277,8 @@ void Scene_polyhedron_shortest_path_item::get_as_vertex_point(Scene_polyhedron_s
276277
FT coords[3] = { FT(0.0), FT(0.0), FT(0.0), };
277278
coords[maxIndex] = FT(1.0);
278279

279-
inOutLocation.second = Barycentric_coordinate(coords[0], coords[1], coords[2]);
280+
Construct_barycentric_coordinate construct_barycentric_coordinate;
281+
inOutLocation.second = construct_barycentric_coordinate(coords[0], coords[1], coords[2]);
280282
}
281283

282284
bool Scene_polyhedron_shortest_path_item::run_point_select(const Ray_3& ray)
@@ -426,13 +428,15 @@ bool Scene_polyhedron_shortest_path_item::deferred_load(Scene_polyhedron_item* p
426428
std::string line;
427429
std::size_t faceId;
428430
Barycentric_coordinate location;
431+
Construct_barycentric_coordinate construct_barycentric_coordinate;
429432

430433
while (std::getline(inFile, line))
431434
{
432435
std::istringstream lineStream(line);
433436
FT coords[3];
434437
lineStream >> faceId >> coords[0] >> coords[1] >> coords[2];
435-
location = Barycentric_coordinate(coords[0], coords[1], coords[2]);
438+
439+
location = construct_barycentric_coordinate(coords[0], coords[1], coords[2]);
436440

437441
// std::cout << "Read in face: " << faceId << " , " << location << std::endl;
438442

Polyhedron/demo/Polyhedron/Scene_polyhedron_shortest_path_item.h

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,24 +40,22 @@ class SCENE_POLYHEDRON_SHORTEST_PATH_ITEM_EXPORT Scene_polyhedron_shortest_path_
4040

4141
public:
4242
typedef Scene_interface::Bbox Bbox;
43-
44-
typedef boost::property_map<Polyhedron, boost::vertex_index_t>::type VertexIndexMap;
45-
typedef boost::property_map<Polyhedron, CGAL::halfedge_index_t>::type HalfedgeIndexMap;
46-
typedef boost::property_map<Polyhedron, CGAL::face_index_t>::type FaceIndexMap;
43+
4744
typedef boost::property_map<Polyhedron, CGAL::vertex_point_t>::type VertexPointMap;
4845

4946
typedef boost::graph_traits<Polyhedron> GraphTraits;
5047
typedef GraphTraits::face_descriptor face_descriptor;
5148
typedef GraphTraits::face_iterator face_iterator;
5249

5350
typedef CGAL::Polyhedron_shortest_path_default_traits<Kernel, Polyhedron> Polyhedron_shortest_path_traits;
54-
typedef CGAL::Polyhedron_shortest_path<Polyhedron_shortest_path_traits, VertexIndexMap, HalfedgeIndexMap, FaceIndexMap, VertexPointMap> Polyhedron_shortest_path;
51+
typedef CGAL::Polyhedron_shortest_path<Polyhedron_shortest_path_traits> Polyhedron_shortest_path;
5552
typedef Polyhedron_shortest_path::Face_location Face_location;
5653
typedef CGAL::AABB_face_graph_triangle_primitive<Polyhedron, VertexPointMap> AABB_face_graph_primitive;
5754
typedef CGAL::AABB_traits<Kernel, AABB_face_graph_primitive> AABB_face_graph_traits;
5855
typedef CGAL::AABB_tree<AABB_face_graph_traits> AABB_face_graph_tree;
5956

6057
typedef Polyhedron_shortest_path_traits::Barycentric_coordinate Barycentric_coordinate;
58+
typedef Polyhedron_shortest_path_traits::Construct_barycentric_coordinate Construct_barycentric_coordinate;
6159
typedef Polyhedron_shortest_path_traits::Ray_3 Ray_3;
6260
typedef Polyhedron_shortest_path_traits::Point_3 Point_3;
6361
typedef Polyhedron_shortest_path_traits::FT FT;

Polyhedron_shortest_path/benchmark/Polyhedron_shortest_path/benchmark_shortest_paths.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
1212

1313
#include <CGAL/Polyhedron_3.h>
14+
#include <CGAL/Polyhedron_items_with_id_3.h>
1415
#include <CGAL/IO/Polyhedron_iostream.h>
1516

1617
#include <CGAL/Polyhedron_shortest_path/Polyhedron_shortest_path_traits.h>
@@ -29,9 +30,10 @@
2930
#define UNUSED(X) (void)sizeof(X)
3031

3132
typedef CGAL::Exact_predicates_inexact_constructions_kernel Kernel;
32-
typedef CGAL::Polyhedron_3<Kernel> Polyhedron_3;
33+
typedef CGAL::Polyhedron_3<Kernel, CGAL::Polyhedron_items_with_id_3> Polyhedron_3;
3334
typedef CGAL::Polyhedron_shortest_path_default_traits<Kernel, Polyhedron_3> Traits;
3435
typedef Traits::Barycentric_coordinate Barycentric_coordinate;
36+
typedef Traits::Construct_barycentric_coordinate Construct_barycentric_coordinate;
3537
typedef CGAL::Polyhedron_shortest_path<Traits> Polyhedron_shortest_path;
3638
typedef boost::graph_traits<Polyhedron_3> GraphTraits;
3739
typedef GraphTraits::vertex_descriptor vertex_descriptor;
@@ -156,9 +158,10 @@ void print_results(std::ostream& stream, const std::string& filename, const Benc
156158

157159
Barycentric_coordinate random_coordinate(CGAL::Random& rand)
158160
{
161+
Construct_barycentric_coordinate construct_barycentric_coordinate;
159162
Traits::FT u = rand.uniform_01<Traits::FT>();
160163
Traits::FT v = rand.uniform_real(Traits::FT(0.0), Traits::FT(1.0) - u);
161-
return Barycentric_coordinate(u, v, Traits::FT(1.0) - u - v);
164+
return construct_barycentric_coordinate(u, v, Traits::FT(1.0) - u - v);
162165
}
163166

164167
void run_benchmarks_no_id(CGAL::Random& rand, size_t numTrials, size_t numSources, size_t numQueries, Polyhedron_3& polyhedron, Benchmark_data& outData)

Polyhedron_shortest_path/doc/Polyhedron_shortest_path/Concepts/PolyhedronShortestPathTraits.h

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ class PolyhedronShortestPathTraits
154154
Function object type.
155155
Must support the result_of protocol, that is the return type of the operator()(A, B) is CGAL::cpp11::result<Intersect_2(A,B)>.
156156
Must provide
157-
`CGAL::cpp11::result<Intersect_2(A,B)> operator()(A obj1, B obj2)`
157+
`CGAL::cpp11::result_of<Intersect_2(A,B)> operator()(A obj1, B obj2)`
158158
to compute the intersection between obj1 and obj2, where A and B can be any one of
159159
Line_2,
160160
Ray_2,
@@ -219,21 +219,21 @@ class PolyhedronShortestPathTraits
219219
/*!
220220
Function object type that provides
221221
`FT operator()(Point_3 p1, Point_3 p2)`
222-
to compute the squared distance between p1 and p2.
222+
to compute the squared distance between `p1` and `p2`.
223223
*/
224224
typedef unspecified_type Compute_squared_distance_3;
225225

226226
/*!
227227
Function object type that provides
228228
`Triangle_2 operator()(Triangle_3 t)`
229-
which computes a 2-dimensional projection of t
229+
which computes a 2-dimensional projection of `t`
230230
that preserves all edge lengths.
231231
*/
232232
typedef unspecified_type Project_triangle_3_to_triangle_2;
233233

234234
/*!
235235
Function object type that provides
236-
`Triangle_2 operator()(Triangle_3 t, size_t i, Segment_2 base)`
236+
`Triangle_2 operator()(Triangle_3 t, std::size_t i, Segment_2 base)`
237237
which computes a 2-dimensional projection of t
238238
that preserves all edge lengths, such that the `i`th edge of t
239239
lies along `base`.
@@ -245,8 +245,8 @@ class PolyhedronShortestPathTraits
245245
/*!
246246
Function object type that provides
247247
`FT operator()(Point_2 x0, Point_2 x1, Point_2 p)`
248-
which computes the parametric distance of p along the
249-
segment [x0,x1]. That is, it computes `t`, such that
248+
which computes the parametric distance of `p` along the
249+
segment `[x0,x1]`. That is, it computes `t`, such that
250250
`p = (1.0 - t)*x0 + t*x1`
251251
252252
\pre p is a point along the segment [x0,x1]
@@ -262,22 +262,22 @@ class PolyhedronShortestPathTraits
262262

263263
/*!
264264
Function object type that provides
265-
`FT operator(Barycentric_coordinate b, size_t i)`
266-
to get the ith weight of barycentric coordinate `b`.
265+
`FT operator(Barycentric_coordinate b, std::size_t i)`
266+
to get the `i`th weight of barycentric coordinate `b`.
267267
*/
268268
typedef unspecified_type Construct_barycentric_coordinate_weight;
269269

270270
/*!
271271
Function object type that provides
272272
`Barycentric_coordinate operator()(Triangle_2 t, Point_2 p)`
273-
which computes the Barycentric location of p in t.
273+
which computes the Barycentric location of `p` in `t`.
274274
*/
275275
typedef unspecified_type Construct_barycentric_coordinate_in_triangle_2;
276276

277277
/*!
278278
Function object type that provides
279279
`Barycentric_coordinate operator()(Triangle_3 t, Point_3 p)`
280-
which computes the Barycentric location of p in t.
280+
which computes the Barycentric location of `p` in `t`.
281281
*/
282282
typedef unspecified_type Construct_barycentric_coordinate_in_triangle_3;
283283

@@ -288,16 +288,16 @@ class PolyhedronShortestPathTraits
288288

289289
/*!
290290
Function object type that provides
291-
`std::pair<CGAL::internal::Barycentric_coordinate_type,size_t> operator()(Barycentric_coordinate b)`,
292-
which computes the classification and nearest edge of the coordinate `b`
291+
`std::pair<CGAL::Polyhedron_shortest_paths_3::Barycentric_coordinate_type,std::size_t> operator()(Barycentric_coordinate b)`,
292+
which computes the classification and the associated edge (if applicable) of the coordinate `b`
293293
\details Returns the pair (`type`, `i`), such that `type` is:
294-
- `CGAL::internal::BARYCENTRIC_COORDINATE_VERTEX` if `b` has exactly one non-zero component equal to 1, and the rest are zero
295-
- `CGAL::internal::BARYCENTRIC_COORDINATE_EDGE` if `b` has exactly one zero component, and the rest sum to 1
296-
- `CGAL::internal::BARYCENTRIC_COORDINATE_INTERNAL` if `b` has no non-zero component, and they all sum to 1
297-
- `CGAL::internal::BARYCENTRIC_COORDINATE_EXTERNAL` if the components of `b` do not sum to 1
298-
- `CGAL::internal::BARYCENTRIC_COORDINATE_INVALID` otherwise
299-
If `type` is `CGAL::internal::BARYCENTRIC_COORDINATE_VERTEX`, `i` should be the index of that vertex
300-
If `type` is `CGAL::internal::BARYCENTRIC_COORDINATE_EDGE`, `i` should be the index of the non-zero edge
294+
- `CGAL::Polyhedron_shortest_paths_3::BARYCENTRIC_COORDINATE_VERTEX` if `b` has exactly one non-zero component equal to 1, and the rest are zero
295+
- `CGAL::Polyhedron_shortest_paths_3::BARYCENTRIC_COORDINATE_EDGE` if `b` has exactly one zero component, and the rest sum to 1
296+
- `CGAL::Polyhedron_shortest_paths_3::BARYCENTRIC_COORDINATE_INTERNAL` if `b` has no non-zero component, and they all sum to 1
297+
- `CGAL::Polyhedron_shortest_paths_3::BARYCENTRIC_COORDINATE_EXTERNAL` if the components of `b` do not sum to 1
298+
- `CGAL::Polyhedron_shortest_paths_3::BARYCENTRIC_COORDINATE_INVALID` otherwise
299+
If `type` is `CGAL::Polyhedron_shortest_paths_3::BARYCENTRIC_COORDINATE_VERTEX`, `i` should be the index of that vertex
300+
If `type` is `CGAL::Polyhedron_shortest_paths_3::BARYCENTRIC_COORDINATE_EDGE`, `i` should be the index of the non-zero edge
301301
- 0 if (0,1) are the non-zero coordinates
302302
- 1 if (1,2) are the non-zero coordinates
303303
- 2 if (2,0) are the non-zero coordinates
@@ -327,17 +327,17 @@ class PolyhedronShortestPathTraits
327327
start point of s1, scaled by the length of s1, to the distance of the intersection
328328
of s2 with l2 from the start point of s2, scaled by the length of s2.
329329
330-
\pre the intersection of s1 and l1 is a single point
331-
\pre the intersection of s2 and l2 is a single point
330+
\pre the intersection of `s1` and `l1` is a single point
331+
\pre the intersection of `s2` and `l2` is a single point
332332
*/
333333
typedef unspecified_type Compare_relative_intersection_along_segment_2;
334334

335335
/*!
336336
Function object type that provides
337337
`template <class VertexPointMap> bool operator()(boost::graph_traits<FaceGraph>::vertex_descriptor v, FaceGraph& p, VertexPointMap vpm)`
338338
that returns true if the vertex is a saddle vertex (more than 2pi surface area
339-
over all adjacent faces), and false otherwise. vmp must be a a model of concept ReadablePropertyMap that maps from vertex_descriptor to
340-
Point_3 objects.
339+
over all adjacent faces), and false otherwise. `vpm` must be a a model of concept `ReadablePropertyMap` that maps from `vertex_descriptor` to
340+
`Point_3` objects.
341341
*/
342342
typedef unspecified_type Is_saddle_vertex;
343343

Polyhedron_shortest_path/doc/Polyhedron_shortest_path/Doxyfile.in

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,8 @@
22
PROJECT_NAME = "CGAL ${CGAL_CREATED_VERSION_NUM} - Shortest Paths on Polyhedra"
33
INPUT = ${CMAKE_SOURCE_DIR}/Polyhedron_shortest_path/doc/Polyhedron_shortest_path/ \
44
${CMAKE_SOURCE_DIR}/Polyhedron_shortest_path/include
5+
6+
INTERNAL_DOCS = NO
7+
EXTRACT_ALL = NO
8+
HIDE_UNDOC_CLASSES = YES
9+
HIDE_UNDOC_MEMBERS = YES

Polyhedron_shortest_path/doc/Polyhedron_shortest_path/PackageDescription.txt

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@
2121
\cgalPkgSummaryEnd
2222

2323
\cgalPkgShortInfoBegin
24+
25+
\cgalPkgLicense{\ref licensesLGPL "LGPL"}
26+
\cgalPkgDependsOn{\ref PkgBGLSummary}
2427
\cgalPkgDemo{Operations on Polyhedra,polyhedron_3.zip}
2528
\cgalPkgShortInfoEnd
2629

@@ -45,6 +48,14 @@
4548

4649
## Enums ##
4750

48-
- `CGAL::PolyhedronShortestPath::Barycentric_coordinate_type`
51+
- `CGAL::Polyhedron_shortest_paths_3::Barycentric_coordinate_type`
4952

5053
*/
54+
55+
56+
/*!
57+
\namespace CGAL::Polyhedron_shortest_paths_3
58+
59+
\brief Namespace containing support members specific to this package.
60+
*/
61+

Polyhedron_shortest_path/doc/Polyhedron_shortest_path/Polyhedron_shortest_path.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ The algorithm used is based on a paper by Xin and Wang \cgalCite{XinWang2009impr
5050
\cgalFigureEnd
5151

5252
\subsection Polyhedron_shortest_pathSaddleVertex Saddle Vertices
53-
A <em>saddle vertex</em> on a polyhedron is a vertex \f$v\f$ where the sum surface angle of all faces incident at \f$v\f$ is greater than \f$2 \pi\f$, or, in simpler terms, one cannot flatten all the faces incident to \f$v\f$ into the plane without overlap. Identifying and dealing with saddle vertices are important shortest path algorithms, because they form `blind spots' which cannot be reached by a single geodesic curve.
53+
A <em>saddle vertex</em> on a polyhedron is a vertex \f$v\f$ where the sum surface angle of all faces incident at \f$v\f$ is greater than \f$2 \pi\f$, or, in simpler terms, one cannot flatten all the faces incident to \f$v\f$ into the plane without overlap. Identifying and dealing with saddle vertices are important shortest path algorithms, because they form <em>blind spots</em> which cannot be reached by a single geodesic curve.
5454

5555
\cgalFigureBegin{Saddle_vertex,saddleVertex.png}
5656
A visibility window (shaded blue) encounters a saddle vertex; the shaded red region behind the vertex is not reachable with a geodesic from the origin point (assuming the geodesic must stay inside the initial window).

Polyhedron_shortest_path/doc/Polyhedron_shortest_path/dependencies

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,5 @@ STL_Extension
44
Algebraic_foundations
55
Circulator
66
Stream_support
7+
BGL
8+
AABB_tree

0 commit comments

Comments
 (0)