diff --git a/include/vclib/ext/README.md b/include/vclib/ext/README.md new file mode 100644 index 000000000..8a4a3a8d6 --- /dev/null +++ b/include/vclib/ext/README.md @@ -0,0 +1,14 @@ +# External Library Support + +This folder contains a set of VCLib functions and classes that can be used only if you have the corresponding external library available on your system. + +The functionalities are then accessible under a specific namespace for each library. + +A list of the supported libraries and their namespaces is provided below: + +| Library(s) | Namespace | Notes | +|:-------:|:---------:|:-----:| +| [OpenGL2](https://registry.khronos.org/OpenGL-Refpages/gl2.1/) | `vcl::gl2` | | +| [Qt6](https://www.qt.io/) | `vcl::qt` | | +| [QGLViewer](http://libqglviewer.com/) | `vcl::qgl` | This library requires Qt6 | +| [VCG](http://vcg.isti.cnr.it/vcglib/) | `vcl::vc` | | diff --git a/include/vclib/ext/vcg/import.h b/include/vclib/ext/vcg/import.h index 36256df54..2b90a0497 100644 --- a/include/vclib/ext/vcg/import.h +++ b/include/vclib/ext/vcg/import.h @@ -28,7 +28,7 @@ #include -namespace vcl { +namespace vcl::vc { template MeshType meshFromVCGMesh(const VCGMeshType& vcgMesh) @@ -179,6 +179,6 @@ void importMeshFromVCGMesh(MeshType& mesh, const VCGMeshType& vcgMesh) } } -} // namespace vcl +} // namespace vcl::vc #endif // VCL_EXT_VCG_IMPORT_H diff --git a/test/tests/ext/vcg/mesh_import_vcg/main.cpp b/test/tests/ext/vcg/mesh_import_vcg/main.cpp index 592b852ba..3fb9503db 100644 --- a/test/tests/ext/vcg/mesh_import_vcg/main.cpp +++ b/test/tests/ext/vcg/mesh_import_vcg/main.cpp @@ -40,7 +40,7 @@ TEST_CASE("Import TriMesh from VCG") REQUIRE(vcgMesh.VN() == 8); REQUIRE(vcgMesh.FN() == 12); - vcl::TriMesh tm = vcl::meshFromVCGMesh(vcgMesh); + vcl::TriMesh tm = vcl::vc::meshFromVCGMesh(vcgMesh); REQUIRE(tm.vertexNumber() == 8); REQUIRE(tm.faceNumber() == 12); @@ -65,7 +65,7 @@ TEST_CASE("Import PolyMesh from VCG") REQUIRE(vcgMesh.VN() == 8); REQUIRE(vcgMesh.FN() == 12); - vcl::PolyMesh pm = vcl::meshFromVCGMesh(vcgMesh); + vcl::PolyMesh pm = vcl::vc::meshFromVCGMesh(vcgMesh); REQUIRE(pm.vertexNumber() == 8); REQUIRE(pm.faceNumber() == 12);