Commit Graph

1154 Commits

Author SHA1 Message Date
Maxime Gimeno 8469c45336 Enhance Prevent_deref API and use it. 2016-09-28 10:48:07 +02:00
Jane Tournois e6d0fe99e0 missing const when TBB available 2016-09-06 11:01:42 +02:00
Laurent Rineau 79dc30fee3 Bug-fix Mesh_3: clear c3t3 before refine_mesh
If vertices are inserted manually in the triangulation between calls to
refine_mesh, the c3t3 is corrupted and must be cleared.
2016-09-02 16:55:37 +02:00
Laurent Rineau 955ca9a55d Bug-fix: bug with Null in Labeled_mesh_domain_3
The bug was introduced in the PR #1010, and was only exposed when the
`Null_subdomain_index` functor was non-trivial.
2016-09-02 16:55:19 +02:00
Laurent Rineau 056df4d93d A Mesh_3 bug-fix!
Some use-cases were triggering the assertion
```C++
CGAL_assertion (this->is_facet_on_surface(facet)
```
in `Refine_facets_3::refinement_point_impl()`.

With Jane, we eventually found out that the bug was that, once a
refinement point is not in conflict with the facet, the dual of the
facet is reconstructed using an exact arithmetic (then a round to
doubles); it turns out that, if the new (exact) dual was not
intersecting the surface of the domain, then the facet must be removed
from the `c3t3`... but it must also be removed from the priority queue
of bad facets! The last part was missing.
2016-09-02 11:51:11 +02:00
Laurent Rineau bffed99bb0 Add a missing overload of the constructor: 4 args 2016-09-02 11:51:11 +02:00
Laurent Rineau a3ffae35bd Merge pull request #1364 from sloriot/CGAL-replace_assert
Replace assert by CGAL_assertion in CGAL code
2016-08-29 12:32:01 +02:00
Sébastien Loriot ff1b240a37 replace assert by CGAL_assertion in CGAL code 2016-08-25 11:12:17 +02:00
Laurent Rineau ec78fd78eb A function that allows to specify ones own lines 2016-08-03 15:36:36 +02:00
Laurent Rineau 426f6e623b bugfix for master: used the copied polyhedron
As `Polyhedral_mesh_domain_with_features_3` copies the polyhedra, the
aabb tree should used the copy (with the assigned patch ids!)

cc @jtournoi
2016-07-26 12:36:21 +02:00
Laurent Rineau 2cd9a15bb9 Merge remote-tracking branch 'cgal/releases/CGAL-4.8-branch'
Merge the following merge commits:
> 12b92f5 Merge pull request #1271 from lrineau/Mesh_3-distance_criterion_sizing_field-GF
> 9c3d0b0 Merge pull request #1295 from lrineau/CGAL-add_test-GF

Conflicts:
	Maintenance/release_building/BUGFIX_NUMBER
	Maintenance/release_building/public_release_name
2016-07-22 18:31:02 +02:00
Laurent Rineau 05260fb4ae Allow a sizing field for the distance criterion 2016-07-21 12:59:14 +02:00
Laurent Rineau 06436ba2ea Fix the I/O for Polyhedral_mesh_domain_3 2016-07-11 18:09:25 +02:00
Laurent Rineau 2e1a6d2c3a Add support for Parallel_tag in io_signature.h 2016-07-11 18:08:51 +02:00
Laurent Rineau 831c0def3d Add an assertion 2016-07-11 18:08:40 +02:00
Sébastien Loriot 10cadcb985 Merge remote-tracking branch 'cgal-dev/CGAL_headers_only_step1-gdamiand_cjamin' into HEAD 2016-06-24 17:05:40 +02:00
Sébastien Loriot c951fe0fca Merge pull request #1035 from lrineau/CGAL-fix_Wconversion_warnings-GF
Fix -Wconversion warnings, and issues detected by those warnings
2016-06-24 13:30:48 +02:00
Laurent Rineau f9dd4b4be7 Try to fix a compilation error with CentOS5's g++
The compilation error was:

> ../include/CGAL/Mesh_3/polylines_to_protect.h: In function ‘void CGAL::polylines_to_protect(const CGAL::Image_3&, double, double, double, std::vector<std::vector<IC, std::allocator<_CharT> >, std::allocator<std::vector<IC, std::allocator<_CharT> > > >&, Image_word_type*, Null_subdomain_index, PolylineInputIterator, PolylineInputIterator) [with P = CGAL::Point_3<CGAL::Epick>, Image_word_type = unsigned char, Null_subdomain_index = CGAL::Null_subdomain_index, PolylineInputIterator = __gnu_cxx::__normal_iterator<std::vector<CGAL::Point_3<CGAL::Epick>, std::allocator<CGAL::Point_3<CGAL::Epick> > >*, std::vector<std::vector<CGAL::Point_3<CGAL::Epick>, std::allocator<CGAL::Point_3<CGAL::Epick> > >, std::allocator<std::vector<CGAL::Point_3<CGAL::Epick>, std::allocator<CGAL::Point_3<CGAL::Epick> > > > > >]’:
> ../include/CGAL/Mesh_3/polylines_to_protect.h:538:   instantiated from ‘void CGAL::polylines_to_protect(const CGAL::Image_3&, std::vector<std::vector<IC, std::allocator<_CharT> >, std::allocator<std::vector<IC, std::allocator<_CharT> > > >&, PolylineInputIterator, PolylineInputIterator) [with P = CGAL::Point_3<CGAL::Epick>, Image_word_type = unsigned char, PolylineInputIterator = __gnu_cxx::__normal_iterator<std::vector<CGAL::Point_3<CGAL::Epick>, std::allocator<CGAL::Point_3<CGAL::Epick> > >*, std::vector<std::vector<CGAL::Point_3<CGAL::Epick>, std::allocator<CGAL::Point_3<CGAL::Epick> > >, std::allocator<std::vector<CGAL::Point_3<CGAL::Epick>, std::allocator<CGAL::Point_3<CGAL::Epick> > > > > >]’
> ../test/Mesh_3_Examples/mesh_3D_image_with_features.cpp:62:   instantiated from here
> ../include/CGAL/Mesh_3/polylines_to_protect.h:193: error: no matching function for call to ‘get(boost::tuples::tuple<boost::array<int, 3ul>, CGAL::Point_3<CGAL::Epick>, unsigned char, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type, boost::tuples::null_type>&)’

See https://cgal.geometryfactory.com/CGAL/testsuite/CGAL-4.9-Ic-81/Mesh_3_Examples/TestReport_lrineau_CentOS5.gz
2016-06-23 14:19:24 +02:00
Guillaume Damiand e21ef313c0 Merge branch 'CGAL_headers_only_step1-gdamiand_cjamin-old' into CGAL_headers_only_step1-gdamiand_cjamin 2016-06-22 20:54:37 +02:00
Laurent Rineau bbc05a11d9 Fix -Wconversion warnings
All conversions are safe.
2016-06-16 16:36:43 +02:00
Laurent Rineau 955e965561 Move code
That will fix the initialization of c3t3 from 3D images, in the
Polyhedron demo, with the protection of 1D-features is used, but there
are no 1D-features.

For other use-cases, that does not change anything.
2016-06-16 15:08:36 +02:00
Laurent Rineau 99b646bdd4 Try to fix a warning
> include\CGAL/Mesh_3/search_for_connected_components_in_labeled_image.h(192): warning C4244: 'argument': conversion from 'const ptrdiff_t' to 'const unsigned short', possible loss of data
2016-06-16 14:44:05 +02:00
Laurent Rineau cfb6c060af Try to fix a warning with MSVC
> include\CGAL/Mesh_3/search_for_connected_components_in_labeled_image.h(111): warning C4267: 'argument': conversion from 'size_t' to 'const unsigned short', possible loss of data
2016-06-16 14:44:05 +02:00
Laurent Rineau fa5cb831c9 Add Output_rep<T,F>::is_specialized...
.. that allows `Dump_c3t3` to detect if a type can be streamed, using
either `operator<<` or `Output_rep<T>`.
2016-06-15 18:10:14 +02:00
Laurent Rineau 16d18351ce Add example showing how to initialize components 2016-06-15 18:10:14 +02:00
Guillaume Damiand a53f16edac Merge branch 'CGAL_headers_only_step1-gdamiand_cjamin-old' into CGAL_headers_only_step1-gdamiand_cjamin 2016-06-09 19:09:38 +02:00
Sébastien Loriot 97e122ccb8 Merge pull request #1110 from maxGimeno/Mesh_3_use_split_graph_into_polylines-GF
Remove duplicated implementation in <CGAL/Mesh_3/polylines_to_protect.h>
2016-05-31 16:03:16 +02:00
Sebastien Loriot cf15f57a50 Merge pull request #1097 from lrineau/Mesh_3-improve_polylines_to_protect-GF
Mesh 3: add an example that protects features of a 3D image
2016-05-31 16:00:58 +02:00
Sebastien Loriot 0f04b4262a Merge pull request #1109 from lrineau/Mesh_3-change_default_for_edge_size-GF
Mesh_criteria_3: change the default for `edge_size` from 0 to +∞
2016-05-31 15:49:16 +02:00
Sébastien Loriot 40ff09bd43 Merge pull request #303 from lrineau/Mesh_3-add_remesh_polyhedral_surface-GF
Add an example that remeshes a polyhedral surface
2016-05-31 15:43:05 +02:00
Sébastien Loriot bb856cbd63 add missing typename 2016-05-27 17:25:17 +02:00
Laurent Rineau 5770538719 Fix a warning
> warning: typedef ‘K’ locally defined but not used [-Wunused-local-typedefs]
2016-05-27 16:47:26 +02:00
Laurent Rineau cfd76f1b00 Avoid degenerated polylines 2016-05-27 16:46:28 +02:00
Jane Tournois 5b45da6239 boundary edges already are detected by detect_features
do not detect and add them twice
and prevent from not-terminating
2016-05-26 17:02:05 +02:00
Maxime Gimeno 475d19894c Removed the file Mesh_3/include/CGAL/internal/Mesh_3/split_in_polylines.h and replaced its usage by CGAL::split_graph_into_polylines. 2016-05-26 16:23:06 +02:00
Jane Tournois 57b609464e save the input polyhedra in a vector
and implement the derived constructors to be able to detect features in them
2016-05-26 16:15:45 +02:00
Jane Tournois be95730ee2 fix commit c7d614193e
I had forgotten 2 constructors
2016-05-26 13:01:30 +02:00
Laurent Rineau fe67240536 Change the default for `edge_size` from 0 to +∞
The previous default value for `CGAL::parameters::edge_size`, in the
constructor of `CGAL::Mesh_criteria_3` was `FT(0)`.

That was in contradiction with the documentation of
[`CGAL::Mesh_criteria_3`][*]:

> Each parameter has a special default value `ignored` which means that
> the corresponding criteria will be ignored.

With `edge_size=0`, the protection of 1D-features is certain to trigger
an assertion or a segmentation fault.

The new default value is now `FT(DBL_MAX)`.

[*]: http://doc.cgal.org/latest/Mesh_3/classCGAL_1_1Mesh__criteria__3.html#ada26edb7ee77aa7279b2ae7e96c56eb0
2016-05-26 12:33:30 +02:00
Jane Tournois c7d614193e move detect_borders inside detect_features
and protect its use with a boolean, to avoid doing it twice
2016-05-26 11:54:30 +02:00
Laurent Rineau 025de85f8b Fix a warning
g++, with `-Wall -Wextra`:

    .../include/CGAL/Mesh_3/polylines_to_protect.h:50:28: warning: unused parameter 'k' [-Wunused-parameter]
2016-05-26 09:39:52 +02:00
Laurent Rineau b8f90e6263 Handle the case 1-2-1 with real arcs
Before that, the arcs were each approximated with a polyline of only two
segments. Now they are each approximated with a polyline of 10 segments.
2016-05-25 14:36:36 +02:00
Laurent Rineau cb8609c6ae Handle the case 2-1-1 with real arcs
Before that, the arcs of the case 2-1-1 were approximated with a strait
line segment. Now they are approximated with a polyline composed of 10
line segments.
2016-05-25 12:38:29 +02:00
Guillaume Damiand 10469f9c4e Update with master 2016-05-25 10:58:55 +02:00
Laurent Rineau e1ccdbf567 Add an example of a labeled imaged with 1d-features 2016-05-24 16:28:17 +02:00
Laurent Rineau 4726306ccb Add debug code for <CGAL/Mesh_3/Graph_manipulations.h>
Protected by the macro `CGAL_MESH_3_DEBUG_GRAPH_MANIPULATION`.
2016-05-23 15:20:39 +02:00
Laurent Rineau aaf91148be bug-fix for previous commit 2016-05-23 15:19:19 +02:00
Laurent Rineau c15c75fa1a Do not protect outside the domain! 2016-05-20 16:53:19 +02:00
Laurent Rineau 4d38c931ce Improve the API of <CGAL/Mesh_3/polylines_to_protect.h>
Now the word type and the null functor are passed as parameters.
2016-05-20 16:52:35 +02:00
Laurent Rineau ee0fb3b23a Fix the header guard macro, and copyright years 2016-05-20 12:46:09 +02:00
Laurent Rineau c03f8530ce Fix indentation 2016-05-20 12:45:47 +02:00