Skip to content

Stream support: VTP and VTU writing functions#3297

Merged
lrineau merged 51 commits intoCGAL:masterfrom
maxGimeno:Stream_support-Dont_use_vtk_for_vtu-GF
Feb 7, 2019
Merged

Stream support: VTP and VTU writing functions#3297
lrineau merged 51 commits intoCGAL:masterfrom
maxGimeno:Stream_support-Dont_use_vtk_for_vtu-GF

Conversation

@maxGimeno
Copy link
Copy Markdown
Contributor

@maxGimeno maxGimeno commented Aug 27, 2018

Summary of Changes

Add functions to write surface meshes, c3t3 and cdt to vtp and vtu format, without using the VTK lib, which avoids having to use intermediary structures.

Release Management

@sloriot
Copy link
Copy Markdown
Member

sloriot commented Aug 27, 2018

I don't see any CMakeLists.txt update (in particular in the Polyhedron demo). Is this expected?

@maxGimeno
Copy link
Copy Markdown
Contributor Author

maxGimeno commented Aug 27, 2018

Yes. It only affects the writing, so we still need VTK to read the data. Do you want me to add #ifdef directives to filtrate what always work and what needs vtk ? It seems like a good idea nw that you mention it.

@sloriot
Copy link
Copy Markdown
Member

sloriot commented Aug 27, 2018

If you are no longer using data structure from VTK, I don't see why VTK would be needed at all. So find_package(VTK) could be removed for some plugins.

@maxGimeno
Copy link
Copy Markdown
Contributor Author

It only affects the writing

We still use vtk structures for reading data, so we still need VTK libs.

@lrineau
Copy link
Copy Markdown
Member

lrineau commented Aug 28, 2018

The idea is that writing a VTU/VTP file is not too complicated, because we master everything, and we can chose a particular file format, in the set of things allowed by the VTK file format description.

But reading VTU/VTP files is another story: one has to be able to read all possible valid VTU/VTP files. That includes at least a full XML parser, the possibility to decode base64, gzip compression, and maybe other things.

So we will be:

  • very strict in out export format, writing VTU/VTP file in a specific sub-format, with a code that does not use the VTK libraries,
  • and we have to be conservative in our import of VTK files, and that requires VTK libraries.

@lrineau lrineau added this to the 4.14-beta milestone Aug 28, 2018
@lrineau
Copy link
Copy Markdown
Member

lrineau commented Oct 2, 2018

Travis reports a license issue:

=> There are modifications in licenses:
 M Stream_support/package_info/Stream_support/license.txt

https://travis-ci.org/CGAL/cgal/jobs/421126628#L1867

…endencies problems. Also fix vtu writer of VTK_io_plugin for polygon meshes.
@lrineau
Copy link
Copy Markdown
Member

lrineau commented Oct 4, 2018

https://travis-ci.org/CGAL/cgal/jobs/436537979#L3618

[ 93%] Building CXX object CMakeFiles/Constrained_Delaunay_triangulation_2.dir/Constrained_Delaunay_triangulation_2_autogen/mocs_compilation.cpp.o
/home/travis/build/CGAL/cgal/GraphicsView/demo/Triangulation_2/Constrained_Delaunay_triangulation_2.cpp:25:10: fatal error: 
      'CGAL/IO/vtk_io_2.h' file not found
#include <CGAL/IO/vtk_io_2.h>
         ^
1 error generated.
make[2]: *** [CMakeFiles/Constrained_Delaunay_triangulation_2.dir/Constrained_Delaunay_triangulation_2.cpp.o] Error 1
make[1]: *** [CMakeFiles/Constrained_Delaunay_triangulation_2.dir/all] Error 2
make: *** [all] Error 2

@lrineau
Copy link
Copy Markdown
Member

lrineau commented Oct 5, 2018

We are close:

.. Checking SPDX license identifier presence in header files...
The following files do not have a SPDX license identifier:
Mesh_2/include/CGAL/IO/vtk_io_2.h
Mesh_3/include/CGAL/IO/vtk_io.h

https://travis-ci.org/CGAL/cgal/jobs/437101040#L1815

@lrineau
Copy link
Copy Markdown
Member

lrineau commented Oct 5, 2018

.. Checking include directives in GPL header files...
The following files do not have an include directive of the package license header:
Mesh_2/include/CGAL/IO/vtk_io_2.h
Mesh_3/include/CGAL/IO/vtk_io.h

@lrineau
Copy link
Copy Markdown
Member

lrineau commented Oct 8, 2018

@maxGimeno: why the TODO label?

@lrineau
Copy link
Copy Markdown
Member

lrineau commented Oct 8, 2018

There seem to be indentation issues in this PR.

@MaelRL MaelRL added Accepted small feature and removed pre-approved For pre-approved small features. After 15 days the feature will be accepted. Not yet approved The feature or pull-request has not yet been approved. labels Feb 4, 2019
@lrineau lrineau force-pushed the Stream_support-Dont_use_vtk_for_vtu-GF branch from d67202f to dc275ec Compare February 4, 2019 14:48
@maxGimeno
Copy link
Copy Markdown
Contributor Author

@lrineau lrineau added the rm only: ready for master For the release team only: that indicates that a PR is about to be merged in 'master' label Feb 7, 2019
@lrineau lrineau merged commit 37cc9b0 into CGAL:master Feb 7, 2019
lrineau added a commit that referenced this pull request Feb 7, 2019
…or_vtu-GF

Stream support: VTP and VTU writing functions
@lrineau lrineau removed Under Testing Ready to be tested rm only: ready for master For the release team only: that indicates that a PR is about to be merged in 'master' labels Feb 7, 2019
@lrineau lrineau deleted the Stream_support-Dont_use_vtk_for_vtu-GF branch February 7, 2019 12:49
@lrineau lrineau removed the rm only: release blocker For the release team only: the next release requires this issue/PR to be solved/merge label Feb 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants