Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kinetic Surface Reconstruction #7908

Merged
Merged
Show file tree
Hide file tree
Changes from 250 commits
Commits
Show all changes
598 commits
Select commit Hold shift + click to select a range
41811ce
adapted CMakeLists.txt of examples to changed filenames
soesau Jan 24, 2023
f741e35
addition of Kinetic_shape_partitioning_Traits_3
soesau Jan 27, 2023
686e8ca
doc fix
soesau Jan 27, 2023
272c9a4
typo fix doc
soesau Jan 29, 2023
4717cf3
Merge branch 'master' into Kinetic_shape_reconstruction-new_package-s…
soesau Jan 29, 2023
af37dd8
fixed include
soesau Jan 29, 2023
d0516b6
one should use DOXYGEN_RUNNING
sloriot Jan 30, 2023
58890b2
API and documentation changes
soesau Jan 31, 2023
bf3df28
doc fix
soesau Jan 31, 2023
d5fa449
update on documentation
soesau Feb 1, 2023
35bf3cb
fixed package name
soesau Feb 1, 2023
be77a22
using Kinetic shape reconstruction as package name for now
soesau Feb 1, 2023
505f97d
doc fix
soesau Feb 1, 2023
dc26470
added concept
soesau Feb 1, 2023
c447cf1
doc fixes
soesau Feb 1, 2023
70cc3cc
doc fixes
soesau Feb 1, 2023
e33ec0a
doc update
soesau Feb 2, 2023
f15da23
doc update
soesau Feb 2, 2023
ff09dd4
doc fix (point map an distance_tolerance default)
soesau Feb 2, 2023
a90ff4f
typo
soesau Feb 2, 2023
13e5f26
bugfix
soesau Feb 2, 2023
ac3840a
added point map np parameter back
soesau Feb 2, 2023
8b5bbdd
moving point map into named parameters
soesau Feb 3, 2023
12f9a70
added dependency to Property_map for Identity_property_map
soesau Feb 3, 2023
e2ec70a
another pass on the documentation
soesau Feb 3, 2023
adcdb40
resizing and changing logo
soesau Feb 3, 2023
3568448
fixed PkgBib
soesau Feb 3, 2023
03094a1
dependencies update
soesau Feb 3, 2023
37d059f
moving test data into test folder
soesau Feb 10, 2023
b9edeec
adapting code to documented API
soesau Feb 10, 2023
2d5f229
adapted test
soesau Feb 10, 2023
5df1e48
moving test data to test folder
soesau Feb 13, 2023
1803867
fixed examples (and temporarily disabled not working ones)
soesau Feb 13, 2023
b10c5d1
fixes to make it compile with clang
soesau Feb 13, 2023
0d4c7a6
removed dependency to boost filesystem
soesau Feb 13, 2023
51dfeb6
removed tabs
soesau Feb 13, 2023
56b3a03
bug fixes
soesau Feb 13, 2023
55a4fb4
removed old Reconstruction.h
soesau Feb 13, 2023
c045a5d
disabled segmented point cloud ply export
soesau Feb 13, 2023
73ba4d2
fixed types
soesau Feb 13, 2023
c3d3b53
disabled reconstruction source
soesau Feb 13, 2023
d96f8ed
Merge branch 'CGAL:master' into Kinetic_shape_reconstruction-new_pack…
soesau Feb 14, 2023
954355d
added plenty of dependencies (will be reduced later)
soesau Feb 14, 2023
676c4f0
added dependency file in package_info
soesau Feb 14, 2023
3383071
update on dependencies
soesau Feb 14, 2023
06aecd8
simplified example
soesau Feb 14, 2023
66e2837
disabling example in documentation
soesau Feb 14, 2023
8cd4dbe
reverted changes to doc dependencies
soesau Feb 14, 2023
55fd982
bugfix and test update
soesau Feb 22, 2023
2ef678a
Merge remote-tracking branch 'remotes/origin/master' into Kinetic_sha…
soesau Feb 24, 2023
cc79cf4
merge fix
soesau Feb 24, 2023
34b2b9f
removed warnings
soesau Feb 27, 2023
e8e1f8c
parentheses around max/min
soesau Mar 1, 2023
be9ac95
add missing include
soesau Mar 1, 2023
1db6c55
removed unused variables
soesau Mar 8, 2023
db9b589
fixed path
soesau Mar 8, 2023
5366166
removed unused variables
soesau Mar 8, 2023
d1978f9
disabled one test that generated different results on debug/release
soesau Mar 8, 2023
c9a7b79
Merge remote-tracking branch 'remotes/origin/master' into Kinetic_sha…
soesau Mar 8, 2023
6b6ff64
renamed named parameters in commented out code
soesau Mar 9, 2023
6d15e4e
reduction of console output
soesau Mar 10, 2023
4f5a69c
typo fix
soesau Apr 27, 2023
11b7d53
restructuring for splitting input data into several partitions (WIP)
soesau May 9, 2023
1fec105
reenable kinetic reconstruction
soesau Sep 14, 2023
10cda49
Merge remote-tracking branch 'remotes/orth/orthtree-generalization' i…
soesau Sep 25, 2023
7980272
fixed color export of surface meshes
soesau Sep 25, 2023
7467a0d
adaptation orthtree, c++17 & new Property handling
soesau Sep 25, 2023
d6e8939
adaptation to use of std::optional
soesau Oct 2, 2023
abcc69d
documented new methods of KSP_3
soesau Oct 2, 2023
06904b5
doc fix
soesau Oct 2, 2023
194ee11
doc fix
soesau Oct 2, 2023
7829d2c
doc fix
soesau Oct 2, 2023
2b82c55
API proposal based on LCC
soesau Oct 2, 2023
eb02fe4
doc fix
soesau Oct 2, 2023
081ffb9
removed regularization from api
soesau Oct 2, 2023
3b2a221
doc fix
soesau Oct 2, 2023
d0914fc
update on lcc with properties
soesau Oct 4, 2023
5a27f38
Merge remote-tracking branch 'orth/orthtree-generalization' into Kine…
soesau Oct 10, 2023
f0dc448
push before another merge of orthtree
soesau Nov 7, 2023
b26e22b
Merge remote-tracking branch 'remotes/orth/orthtree-generalization' i…
soesau Nov 8, 2023
2b25412
merging LCC creation, point on face projection for reconstruction and…
soesau Nov 8, 2023
87fb23b
LCC export with all properties
soesau Nov 13, 2023
d7f7fca
adding concept KineticLCCProperties
soesau Nov 13, 2023
516f1fe
added volume_id to KineticLCCProperties
soesau Nov 13, 2023
acfa140
removed boost filesystem dependecy from test
soesau Nov 13, 2023
6aa3f23
removed unused test
soesau Nov 13, 2023
34daa5a
removed unused example and doc fixes
soesau Nov 13, 2023
e16936d
doc fix
soesau Nov 13, 2023
61eccb9
doc fix
soesau Nov 13, 2023
70b9d8a
doc fix for concept
soesau Nov 13, 2023
bfeacd4
split up the KineticLCCProperties concept
soesau Nov 13, 2023
eef1279
update on Concepts/KineticLCCDartWrapper.h
soesau Nov 13, 2023
30bd53c
pass on documentation
soesau Nov 14, 2023
7a2e4be
doc fix
soesau Nov 14, 2023
04fbc73
Fix doxygen groups
afabri Nov 14, 2023
ef3e36c
doc iteration
soesau Nov 14, 2023
e71b70e
doc
soesau Nov 14, 2023
da3ccb9
Fix ingroup
afabri Nov 14, 2023
8734790
Add addgroup
afabri Nov 14, 2023
eb98e2a
fixing doc linking
soesau Nov 14, 2023
4f1649e
Change authors
afabri Nov 14, 2023
a70f01f
Deal with license check
afabri Nov 14, 2023
3d055e2
untabify
afabri Nov 14, 2023
d965375
doc fixes
soesau Nov 14, 2023
c40466b
fix
soesau Nov 14, 2023
22f2b84
add missing header
soesau Nov 14, 2023
e48d8ba
fix missing license header & doc
soesau Nov 14, 2023
6cf654e
removing special character
soesau Nov 14, 2023
465d508
removed tabs
soesau Nov 14, 2023
255a4fa
adding dependency to Combinatorial_map
soesau Nov 14, 2023
3eb8acc
doc
soesau Nov 14, 2023
748a39c
remove extra comment (already in comment section)
sloriot Nov 14, 2023
a8f3ee7
doc fix
soesau Nov 14, 2023
6cb86ae
backtick
afabri Nov 14, 2023
2955558
keep doc of parameters together
afabri Nov 14, 2023
f2f6737
doc
soesau Nov 14, 2023
56aaf04
five -> three parameters
soesau Nov 14, 2023
0f99f14
some fixes for ci
soesau Nov 14, 2023
e94bc9b
ci fix
soesau Nov 14, 2023
80ee2a0
ci fixes
soesau Nov 14, 2023
ffac304
some more fixes for ci
soesau Nov 15, 2023
de76d7d
Add dependency for ConstRange
afabri Nov 15, 2023
dc02b0d
pass on examples and some doc typos
soesau Nov 15, 2023
602eda3
renaming Kinetic_shape_reconstruction to Kinetic_shape_partition
soesau Nov 15, 2023
cb4e402
ongoing renaming Kinetic_shape_reconstruction to Kinetic_shape_partition
soesau Nov 15, 2023
2c87155
Merge remote-tracking branch 'orth/orthtree-generalization' into Kine…
soesau Nov 15, 2023
633e4e7
ongoing renaming
soesau Nov 15, 2023
b520b1b
temporarily removing examples
soesau Nov 15, 2023
b6f38c1
fix
soesau Nov 15, 2023
affbc8f
fixes
soesau Nov 15, 2023
4faeba0
doc
soesau Nov 15, 2023
c1921bb
doc & license files
soesau Nov 15, 2023
2894b8c
update on dependencies
soesau Nov 15, 2023
7fdfe22
doc fix
soesau Nov 15, 2023
79b451a
added two missing named parameters
soesau Nov 15, 2023
18aa5f6
bugfix
soesau Nov 15, 2023
def9673
removed named parameter from KSR
soesau Nov 15, 2023
eebd222
pass on documentation from reviews
soesau Nov 16, 2023
07bd3d0
doc using correct \cgalBigO
soesau Nov 16, 2023
506289d
merging of coplanar adjacent surfaces of reconstruction result from LCC
soesau Nov 23, 2023
d7e778c
clean up
soesau Nov 28, 2023
bb9bd32
changed license file
soesau Dec 13, 2023
61756e9
renamed license to Kinetic_shape_partition (no _3)
soesau Dec 13, 2023
9ed7ec2
renaming Kinetic_shape_partition to Kinetic_space_partition
soesau Dec 13, 2023
c868c0f
renaming package to Kinetic_space_partition
soesau Dec 13, 2023
de388bc
CMakeLists.txt fix
soesau Dec 13, 2023
56dfa3a
bug fix
soesau Dec 13, 2023
b924c76
updating dependencies
soesau Dec 13, 2023
0cab878
pass on example
soesau Dec 15, 2023
5790966
spelling fix
soesau Dec 15, 2023
ddcbd5c
renaming inside concepts
soesau Dec 15, 2023
c4678fa
set cmake_minimum_required to proper values (broke testing before)
soesau Jan 11, 2024
f4cd4ff
fix warnings
soesau Jan 11, 2024
246e7eb
changing cmake_minimum_required to be in line with other packages in …
soesau Jan 11, 2024
490c99f
Merge remote-tracking branch 'cgal/master' into Kinetic_shape_reconst…
soesau Mar 26, 2024
4c52001
update deps
soesau Mar 28, 2024
55c9b03
fixes for clang
soesau Mar 28, 2024
fa11cf6
removing redefinition of Support_line in KSP_2
soesau Mar 28, 2024
e63550d
Fix some errors and warnings
afabri Apr 2, 2024
6e3c81e
update dependencies
soesau Apr 3, 2024
d723f17
fixing some warnings and errors
soesau Apr 3, 2024
7d50a1e
Deal with -1
afabri Apr 3, 2024
2659378
Remove copy constructor and assignment
afabri Apr 3, 2024
fc8243f
Fix Color
afabri Apr 4, 2024
6698875
Add assignment of Edge_property which does NOT copy order (which seem…
afabri Apr 4, 2024
86b1547
#include for make_hexahedron
afabri Apr 9, 2024
32609b0
intersection timing is now exact
soesau Apr 22, 2024
d1688e0
fix compilation issues and warnings
sloriot Apr 23, 2024
a1f4877
fix dependancies
sloriot Apr 23, 2024
9192102
fix typedef
sloriot Apr 23, 2024
e9ed069
removing debug code
soesau Apr 24, 2024
c8e45dd
support plane comparison is exact now
soesau Apr 24, 2024
1edc22b
cleaning up tests
soesau Apr 24, 2024
1a54b64
turn off spamming
soesau Apr 24, 2024
436a53e
remove debug code
soesau Apr 25, 2024
f60278e
making find_adjacent_faces exact
soesau Apr 25, 2024
0bead91
fix link error
sloriot Apr 29, 2024
6fbf520
new package for kinetic surface reconstruction
soesau Dec 4, 2023
2087250
first version of doc
soesau Dec 4, 2023
898941f
doc
soesau Dec 4, 2023
cde727d
doc fix
soesau Dec 4, 2023
b2df004
doc
soesau Dec 5, 2023
70b3530
doc
soesau Dec 5, 2023
75514fd
doc
soesau Dec 5, 2023
b2f015f
first version of user manual
soesau Dec 7, 2023
013d1ad
doc fix tags
soesau Dec 7, 2023
0603f1d
Update Kinetic_surface_reconstruction/include/CGAL/Kinetic_surface_re…
soesau Dec 8, 2023
9d1decf
some bugfixes for lcc export and merging of coplanar adjacent polygons
soesau Dec 11, 2023
bbf2ca3
integrated comments
soesau Dec 11, 2023
dc1a2ec
removing trailing whitespaces from documentation
soesau Dec 11, 2023
7fc0d9d
Update Kinetic_surface_reconstruction/include/CGAL/Kinetic_surface_re…
soesau Dec 11, 2023
a4d4438
doc results
soesau Dec 13, 2023
6cd8cb3
removing CGAL_USE_FILE
soesau Dec 13, 2023
9b9d058
missing license file
soesau Dec 13, 2023
aa58806
moving Graph_cut.h from KSP to KSR
soesau Dec 14, 2023
c9e2dc6
disable dumping functions using private functions
soesau Dec 14, 2023
a10895e
Merge remote-tracking branch 'origin/Kinetic_shape_reconstruction-new…
sloriot May 15, 2024
a86c470
remove CGAL_USE_FILE from CMakeLists.txt
soesau Dec 14, 2023
fceefc5
fixed name
soesau Dec 14, 2023
6948707
fixes for ci
soesau Dec 14, 2023
44f4a4a
fix for ci
soesau Dec 14, 2023
7357ca1
update dependencies
soesau Dec 14, 2023
697761f
adding more dependencies
soesau Dec 14, 2023
7f4eb87
fix
soesau Dec 14, 2023
c3b5ce3
fix not renamed reference to Kinetic_shape_partition
soesau Dec 14, 2023
61e7b0f
added test
soesau Dec 15, 2023
5f9abee
CMakeLists.txt fix
soesau Dec 15, 2023
8bcd930
fixed old references to KineticShapePartition
soesau Dec 15, 2023
74f3707
update doc dependencies
soesau Dec 15, 2023
b85652f
doc
soesau Dec 15, 2023
d6a5dc5
updating example
soesau Dec 15, 2023
02118b7
Merge remote-tracking branch 'origin/Kinetic_shape_reconstruction-new…
sloriot May 15, 2024
06ffd9a
documentation
soesau Dec 15, 2023
dabc8ff
adding more tests
soesau Jan 5, 2024
6f63f6a
set cmake_minimum_required to proper values (broke testing before)
soesau Jan 11, 2024
4d0840f
fix warnings
soesau Jan 11, 2024
14db7b8
Merge remote-tracking branch 'origin/Kinetic_shape_reconstruction-new…
sloriot May 15, 2024
f0609dc
renaming examples as targets are global
soesau Jan 11, 2024
56365c2
fix warnings
soesau Jan 11, 2024
393c73a
Merge remote-tracking branch 'origin/Kinetic_shape_reconstruction-new…
sloriot May 15, 2024
6f91baa
changing cmake_minimum_required to be in line with other packages in …
soesau Jan 11, 2024
f6546e1
fix max supported version
sloriot Jan 17, 2024
d34e9a0
Add typename
afabri Jan 17, 2024
495ce7a
Add template for LCC template member functions
afabri Jan 17, 2024
c179d9d
unused-parameter warning
afabri Jan 17, 2024
74c9e0a
Remove Orthtree::unsplit()
afabri Jan 18, 2024
c48faf3
reorder member initialization
afabri Jan 18, 2024
c09937e
std::size_t -> LCC::size_type
afabri Jan 18, 2024
d3b7798
rename struct to avoid change of meaning in the same namespace
sloriot Jan 18, 2024
5747c0b
polish doc
afabri Jan 18, 2024
b9ef5de
Merge remote-tracking branch 'mine/Kinetic_shape_reconstruction-new_p…
sloriot May 15, 2024
e7e8256
fix dependencies
soesau Apr 17, 2024
7264047
fix dependencies
soesau Apr 17, 2024
679440b
fix warnings
sloriot Apr 23, 2024
eb1d1d5
removed unused included headers
soesau Apr 23, 2024
b053d68
Merge remote-tracking branch 'remotes/mine/Kinetic_shape_reconstructi…
sloriot May 15, 2024
b575162
removed warnings
soesau Apr 24, 2024
c180c7e
made tests more tolerant to different results
soesau Apr 24, 2024
3cab8d9
fixed dependencies
soesau Apr 25, 2024
b58ebad
clearing between calling detect_planar_shapes twice
soesau Apr 25, 2024
409280c
bugfixes
soesau Apr 25, 2024
1bcf284
fixing tests
soesau Apr 25, 2024
68cbb62
removed trailing whitespace
soesau Apr 25, 2024
5a9321d
Merge remote-tracking branch 'soesau/Kinetic_shape_reconstruction-new…
sloriot May 15, 2024
d69642c
use an existing data set
sloriot May 15, 2024
2436e3e
update on implementation history
soesau May 17, 2024
f7c9529
de-duplicate label
sloriot May 24, 2024
76f69f1
fixing ghost edge placement for more complicated cases
soesau May 24, 2024
118f395
doc update on performance numbers and used parameters for reconstruction
soesau May 24, 2024
28ef0b6
removing some spamming
soesau May 24, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
174 changes: 167 additions & 7 deletions BGL/include/CGAL/boost/graph/alpha_expansion_graphcut.h
Original file line number Diff line number Diff line change
Expand Up @@ -566,6 +566,7 @@ double alpha_expansion_graphcut (const InputGraph& input_graph,
std::size_t number_of_labels = get(vertex_label_cost_map, *(vertices(input_graph).first)).size();

bool success;
bool full_loop = false;
do {
success = false;

Expand Down Expand Up @@ -644,6 +645,8 @@ double alpha_expansion_graphcut (const InputGraph& input_graph,
#ifdef CGAL_SEGMENTATION_BENCH_GRAPHCUT
cut_time += timer.time();
#endif
if (full_loop && flow >= min_cut)
continue;

if(min_cut - flow <= flow * tolerance) {
continue;
Expand All @@ -656,18 +659,158 @@ double alpha_expansion_graphcut (const InputGraph& input_graph,
std::size_t vertex_i = get (vertex_index_map, vd);
alpha_expansion.update(vertex_label_map, inserted_vertices, vd, vertex_i, alpha);
}
}
full_loop = true;
} while (success);

#ifdef CGAL_SEGMENTATION_BENCH_GRAPHCUT
CGAL_TRACE_STREAM << "vertex creation time: " << vertex_creation_time <<
std::endl;
CGAL_TRACE_STREAM << "edge creation time: " << edge_creation_time << std::endl;
CGAL_TRACE_STREAM << "max flow algorithm time: " << cut_time << std::endl;
#endif

return min_cut;
}


template <typename InputGraph,
typename EdgeCostMap,
typename VertexLabelCostMap,
typename VertexLabelMap,
typename NamedParameters>
double min_cut(const InputGraph& input_graph,
EdgeCostMap edge_cost_map,
VertexLabelCostMap vertex_label_cost_map,
VertexLabelMap vertex_label_map,
const NamedParameters& np)
{
using parameters::choose_parameter;
using parameters::get_parameter;

typedef boost::graph_traits<InputGraph> GT;
typedef typename GT::edge_descriptor input_edge_descriptor;
typedef typename GT::vertex_descriptor input_vertex_descriptor;

typedef typename GetInitializedVertexIndexMap<InputGraph, NamedParameters>::type VertexIndexMap;
VertexIndexMap vertex_index_map = CGAL::get_initialized_vertex_index_map(input_graph, np);

typedef typename GetImplementationTag<NamedParameters>::type Impl_tag;

// select implementation
typedef typename std::conditional
<std::is_same<Impl_tag, Alpha_expansion_boost_adjacency_list_tag>::value,
Alpha_expansion_boost_adjacency_list_impl,
typename std::conditional
<std::is_same<Impl_tag, Alpha_expansion_boost_compressed_sparse_row_tag>::value,
Alpha_expansion_boost_compressed_sparse_row_impl,
Alpha_expansion_MaxFlow_impl>::type>::type
Alpha_expansion;

typedef typename Alpha_expansion::Vertex_descriptor Vertex_descriptor;

Alpha_expansion graph;

double min_cut = (std::numeric_limits<double>::max)();

#ifdef CGAL_SEGMENTATION_BENCH_GRAPHCUT
double vertex_creation_time, edge_creation_time, cut_time;
vertex_creation_time = edge_creation_time = cut_time = 0.0;
#endif

std::vector<Vertex_descriptor> inserted_vertices;
inserted_vertices.resize(num_vertices(input_graph));

graph.clear_graph();

#ifdef CGAL_SEGMENTATION_BENCH_GRAPHCUT
Timer timer;
timer.start();
#endif

// For E-Data
// add every input vertex as a vertex to the graph, put edges to source & sink vertices
for (input_vertex_descriptor vd : CGAL::make_range(vertices(input_graph)))
{
std::size_t vertex_i = get(vertex_index_map, vd);
Vertex_descriptor new_vertex = graph.add_vertex();
inserted_vertices[vertex_i] = new_vertex;

double source_weight = get(vertex_label_cost_map, vd)[0];
double sink_weight = get(vertex_label_cost_map, vd)[0];

graph.add_tweight(new_vertex, source_weight, sink_weight);
}
#ifdef CGAL_SEGMENTATION_BENCH_GRAPHCUT
vertex_creation_time += timer.time();
timer.reset();
#endif

// For E-Smooth
// add edge between every vertex,
for (input_edge_descriptor ed : CGAL::make_range(edges(input_graph)))
{
input_vertex_descriptor vd1 = source(ed, input_graph);
input_vertex_descriptor vd2 = target(ed, input_graph);
std::size_t idx1 = get(vertex_index_map, vd1);
std::size_t idx2 = get(vertex_index_map, vd2);

double weight = get(edge_cost_map, ed);

Vertex_descriptor v1 = inserted_vertices[idx1],
v2 = inserted_vertices[idx2];

graph.add_edge(v1, v2, weight, weight);
}
} while(success);

#ifdef CGAL_SEGMENTATION_BENCH_GRAPHCUT
CGAL_TRACE_STREAM << "vertex creation time: " << vertex_creation_time <<
std::endl;
CGAL_TRACE_STREAM << "edge creation time: " << edge_creation_time << std::endl;
CGAL_TRACE_STREAM << "max flow algorithm time: " << cut_time << std::endl;
edge_creation_time += timer.time();
#endif

return min_cut;
}
graph.init_vertices();

#ifdef CGAL_SEGMENTATION_BENCH_GRAPHCUT
timer.reset();
#endif

min_cut = graph.max_flow();

#ifdef CGAL_SEGMENTATION_BENCH_GRAPHCUT
cut_time += timer.time();
#endif

/*
//update labeling
for (input_vertex_descriptor vd : CGAL::make_range(vertices(input_graph)))
{
std::size_t vertex_i = get(vertex_index_map, vd);
alpha_expansion.update(vertex_label_map, inserted_vertices, vd, vertex_i, alpha);
}*/

graph.get_labels(vertex_index_map, vertex_label_map, inserted_vertices, CGAL::make_range(vertices(input_graph)));
/*
//update labeling
for (auto vd : vertices(input_graph)) {
std::size_t idx = get(vertex_index_map, vd);
int label = graph.get_label(inserted_vertices[idx]);
put(vertex_label_map, vd, label);
}

for (input_vertex_descriptor vd : CGAL::make_range(vertices(input_graph)))
{
std::size_t vertex_i = get(vertex_index_map, vd);
graph.update(vertex_label_map, inserted_vertices, vd, vertex_i, alpha);
}*/

#ifdef CGAL_SEGMENTATION_BENCH_GRAPHCUT
CGAL_TRACE_STREAM << "vertex creation time: " << vertex_creation_time <<
std::endl;
CGAL_TRACE_STREAM << "edge creation time: " << edge_creation_time << std::endl;
CGAL_TRACE_STREAM << "max flow algorithm time: " << cut_time << std::endl;
#endif

return min_cut;
}

/// \cond SKIP_IN_MANUAL

Expand Down Expand Up @@ -701,6 +844,23 @@ double alpha_expansion_graphcut (const std::vector<std::pair<std::size_t, std::s
CGAL::parameters::vertex_index_map (graph.vertex_index_map()).
implementation_tag (AlphaExpansionImplementationTag()));
}

template <typename AlphaExpansionImplementationTag>
double min_cut(const std::vector<std::pair<std::size_t, std::size_t> >& edges,
const std::vector<double>& edge_costs,
const std::vector<std::vector<double> >& cost_matrix,
std::vector<std::size_t>& labels,
const AlphaExpansionImplementationTag&)
{
internal::Alpha_expansion_old_API_wrapper_graph graph(edges, edge_costs, cost_matrix, labels);

return min_cut(graph,
graph.edge_cost_map(),
graph.vertex_label_cost_map(),
graph.vertex_label_map(),
CGAL::parameters::vertex_index_map(graph.vertex_index_map()).
implementation_tag(AlphaExpansionImplementationTag()));
}
/// \endcond

}//namespace CGAL
Expand Down
12 changes: 12 additions & 0 deletions Documentation/doc/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,18 @@ endif()
find_package(Doxygen REQUIRED)
find_package(Python3 REQUIRED COMPONENTS Interpreter)

if (NOT Python3_EXECUTABLE)
message(FATAL_ERROR "Cannot build the documentation without Python3!")
return()
endif()

message(STATUS ${Python3_EXECUTABLE})

if(NOT DOXYGEN_FOUND)
message(WARNING "Cannot build the documentation without Doxygen!")
return()
endif()

#starting from cmake 3.9 the usage of DOXYGEN_EXECUTABLE is deprecated
if(TARGET Doxygen::doxygen)
get_property(
Expand Down
2 changes: 2 additions & 0 deletions Documentation/doc/Documentation/packages.txt
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@
\package_listing{Scale_space_reconstruction_3}
\package_listing{Advancing_front_surface_reconstruction}
\package_listing{Polygonal_surface_reconstruction}
\package_listing{Kinetic_space_partition}
\package_listing{Kinetic_surface_reconstruction}
\package_listing{Optimal_transportation_reconstruction_2}

\cgalPackageSection{PartGeometryProcessing,Geometry Processing}
Expand Down
19 changes: 19 additions & 0 deletions Documentation/doc/biblio/geom.bib
Original file line number Diff line number Diff line change
Expand Up @@ -151974,6 +151974,25 @@ @inproceedings{schnabel2007efficient
organization={Wiley Online Library}
}

@article{bauchet2020kinetic,
author = {Bauchet, Jean-Philippe and Lafarge, Florent},
title = {Kinetic Shape Reconstruction},
journal = "ACM Transactions on Graphics",
year = {2020},
issue_date = {October 2020},
publisher = {Association for Computing Machinery},
address = {New York, NY, USA},
volume = {39},
number = {5},
issn = {0730-0301},
url = {https://doi.org/10.1145/3376918},
doi = {10.1145/3376918},
month = {jun},
articleno = {156},
numpages = {14},
keywords = {polygonal surface mesh, Surface reconstruction, kinetic framework, surface approximation}
}

@article{levismooth,
title={Smooth Rotation Enhanced As-Rigid-As-Possible Mesh Animation},
author={Levi, Zohar and Gotsman, Craig},
Expand Down
54 changes: 54 additions & 0 deletions Installation/include/CGAL/license/Kinetic_space_partition.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
// Copyright (c) 2016 GeometryFactory SARL (France).
// All rights reserved.
//
// This file is part of CGAL (www.cgal.org)
//
// $URL$
// $Id$
// SPDX-License-Identifier: LGPL-3.0-or-later OR LicenseRef-Commercial
//
// Author(s) : Andreas Fabri
//
// Warning: this file is generated, see include/CGAL/license/README.md

#ifndef CGAL_LICENSE_KINETIC_SPACE_PARTITION_H
#define CGAL_LICENSE_KINETIC_SPACE_PARTITION_H

#include <CGAL/config.h>
#include <CGAL/license.h>

#ifdef CGAL_KINETIC_SPACE_PARTITION_COMMERCIAL_LICENSE

# if CGAL_KINETIC_SPACE_PARTITION_COMMERCIAL_LICENSE < CGAL_RELEASE_DATE

# if defined(CGAL_LICENSE_WARNING)

CGAL_pragma_warning("Your commercial license for CGAL does not cover "
"this release of the Kinetic Space Partition package.")
# endif

# ifdef CGAL_LICENSE_ERROR
# error "Your commercial license for CGAL does not cover this release \
of the Kinetic Space Partition package. \
You get this error, as you defined CGAL_LICENSE_ERROR."
# endif // CGAL_LICENSE_ERROR
# endif // CGAL_KINETIC_SPACE_PARTITION_COMMERCIAL_LICENSE < CGAL_RELEASE_DATE
#else // no CGAL_KINETIC_SPACE_PARTITION_COMMERCIAL_LICENSE
# if defined(CGAL_LICENSE_WARNING)
CGAL_pragma_warning("\nThe macro CGAL_KINETIC_SPACE_PARTITION_COMMERCIAL_LICENSE is not defined."
"\nYou use the CGAL Kinetic Space Partition package under "
"the terms of the GPLv3+.")
# endif // CGAL_LICENSE_WARNING
# ifdef CGAL_LICENSE_ERROR
# error "The macro CGAL_KINETIC_SPACE_PARTITION_COMMERCIAL_LICENSE is not defined.\
You use the CGAL Kinetic Space Partition package under the terms of \
the GPLv3+. You get this error, as you defined CGAL_LICENSE_ERROR."
# endif // CGAL_LICENSE_ERROR
#endif // no CGAL_KINETIC_SPACE_PARTITION_COMMERCIAL_LICENSE
#endif // CGAL_LICENSE_KINETIC_SPACE_PARTITION_H
54 changes: 54 additions & 0 deletions Installation/include/CGAL/license/Kinetic_surface_reconstruction.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
// Copyright (c) 2016 GeometryFactory SARL (France).
// All rights reserved.
//
// This file is part of CGAL (www.cgal.org)
//
// $URL$
// $Id$
// SPDX-License-Identifier: LGPL-3.0-or-later OR LicenseRef-Commercial
//
// Author(s) : Andreas Fabri
//
// Warning: this file is generated, see include/CGAL/license/README.md

#ifndef CGAL_LICENSE_KINETIC_SURFACE_RECONSTRUCTION_H
#define CGAL_LICENSE_KINETIC_SURFACE_RECONSTRUCTION_H

#include <CGAL/config.h>
#include <CGAL/license.h>

#ifdef CGAL_KINETIC_SURFACE_RECONSTRUCTION_COMMERCIAL_LICENSE

# if CGAL_KINETIC_SURFACE_RECONSTRUCTION_COMMERCIAL_LICENSE < CGAL_RELEASE_DATE

# if defined(CGAL_LICENSE_WARNING)

CGAL_pragma_warning("Your commercial license for CGAL does not cover "
"this release of the Kinetic Surface Reconstruction package.")
# endif

# ifdef CGAL_LICENSE_ERROR
# error "Your commercial license for CGAL does not cover this release \
of the Kinetic Surface Reconstruction package. \
You get this error, as you defined CGAL_LICENSE_ERROR."
# endif // CGAL_LICENSE_ERROR

# endif // CGAL_KINETIC_SURFACE_RECONSTRUCTION_COMMERCIAL_LICENSE < CGAL_RELEASE_DATE

#else // no CGAL_KINETIC_SURFACE_RECONSTRUCTION_COMMERCIAL_LICENSE

# if defined(CGAL_LICENSE_WARNING)
CGAL_pragma_warning("\nThe macro CGAL_KINETIC_SURFACE_RECONSTRUCTION_COMMERCIAL_LICENSE is not defined."
"\nYou use the CGAL Kinetic Surface Reconstruction package under "
"the terms of the GPLv3+.")
# endif // CGAL_LICENSE_WARNING

# ifdef CGAL_LICENSE_ERROR
# error "The macro CGAL_KINETIC_SURFACE_RECONSTRUCTION_COMMERCIAL_LICENSE is not defined.\
You use the CGAL Kinetic Surface Reconstruction package under the terms of \
the GPLv3+. You get this error, as you defined CGAL_LICENSE_ERROR."
# endif // CGAL_LICENSE_ERROR

#endif // no CGAL_KINETIC_SURFACE_RECONSTRUCTION_COMMERCIAL_LICENSE

#endif // CGAL_LICENSE_KINETIC_SURFACE_RECONSTRUCTION_H
1 change: 1 addition & 0 deletions Installation/include/CGAL/license/gpl_package_list.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ Inscribed_areas Inscribed Areas
Interpolation 2D and Surface Function Interpolation
Interval_skip_list Interval Skip List
Jet_fitting_3 Estimation of Local Differential Properties of Point-Sampled Surfaces
Kinetic_surface_reconstruction Kinetic Surface Reconstruction
Matrix_search Monotone and Sorted Matrix Search
Mesh_2 2D Conforming Triangulations and Meshes
Mesh_3 3D Mesh Generation
Expand Down
Loading