mirror of https://github.com/CGAL/cgal
Link with BLAS, LAPACK and TAUCS using CGAL_UseTAUCS.cmake
This commit is contained in:
parent
8ec64344ea
commit
74d29f695a
|
|
@ -45,18 +45,14 @@ if(QT_FOUND)
|
||||||
find_package(QGLViewer QUIET )
|
find_package(QGLViewer QUIET )
|
||||||
endif(QT_FOUND)
|
endif(QT_FOUND)
|
||||||
|
|
||||||
# Find TAUCS (optionnal)
|
# Link with BLAS, LAPACK and TAUCS (optional)
|
||||||
find_package(TAUCS QUIET)
|
include( CGAL_UseTAUCS )
|
||||||
|
if (NOT TAUCS_FOUND)
|
||||||
|
message(STATUS "warning: TAUCS is not found. parameterization will not be available.")
|
||||||
|
endif(TAUCS_FOUND)
|
||||||
|
|
||||||
if(CGAL_Qt4_FOUND AND Boost_FOUND AND Boost_THREAD_FOUND AND QT_FOUND AND OPENGL_FOUND AND QGLVIEWER_FOUND)
|
if(CGAL_Qt4_FOUND AND Boost_FOUND AND Boost_THREAD_FOUND AND QT_FOUND AND OPENGL_FOUND AND QGLVIEWER_FOUND)
|
||||||
|
|
||||||
if(TAUCS_FOUND)
|
|
||||||
include_directories( ${TAUCS_INCLUDE_DIR} )
|
|
||||||
add_definitions(-DCGAL_TAUCS_ENABLED)
|
|
||||||
else(TAUCS_FOUND)
|
|
||||||
message(STATUS "warning: TAUCS is not found. parametrization will not be available.")
|
|
||||||
endif(TAUCS_FOUND)
|
|
||||||
|
|
||||||
qt4_wrap_ui( UI_FILES MainWindow.ui )
|
qt4_wrap_ui( UI_FILES MainWindow.ui )
|
||||||
|
|
||||||
include(AddFileDependencies)
|
include(AddFileDependencies)
|
||||||
|
|
@ -117,18 +113,6 @@ if(CGAL_Qt4_FOUND AND Boost_FOUND AND Boost_THREAD_FOUND AND QT_FOUND AND OPENGL
|
||||||
# Link with libQGLViewer, OpenGL
|
# Link with libQGLViewer, OpenGL
|
||||||
target_link_libraries( Polyhedron_3 ${QGLVIEWER_LIBRARY} ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY} )
|
target_link_libraries( Polyhedron_3 ${QGLVIEWER_LIBRARY} ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY} )
|
||||||
|
|
||||||
if(TAUCS_FOUND)
|
|
||||||
# Link with TAUCS
|
|
||||||
link_directories(Polyhedron_3 ${TAUCS_LIBRARIES_DIR})
|
|
||||||
target_link_libraries(Polyhedron_3 ${TAUCS_LIBRARIES})
|
|
||||||
endif(TAUCS_FOUND)
|
|
||||||
|
|
||||||
# Blas and Lapack, under Linux
|
|
||||||
if( NOT CGAL_AUTO_LINK_ENABLED )
|
|
||||||
add_definitions( -DCGAL_USE_F2C )
|
|
||||||
target_link_libraries( Polyhedron_3 lapack blas )
|
|
||||||
endif()
|
|
||||||
|
|
||||||
else (CGAL_Qt4_FOUND AND Boost_FOUND AND Boost_THREAD_FOUND AND QT_FOUND AND OPENGL_FOUND AND QGLVIEWER_FOUND)
|
else (CGAL_Qt4_FOUND AND Boost_FOUND AND Boost_THREAD_FOUND AND QT_FOUND AND OPENGL_FOUND AND QGLVIEWER_FOUND)
|
||||||
|
|
||||||
set(POLYHEDRON_MISSING_DEPS "")
|
set(POLYHEDRON_MISSING_DEPS "")
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ namespace Ui {
|
||||||
|
|
||||||
#include "Polyhedron_type_fwd.h"
|
#include "Polyhedron_type_fwd.h"
|
||||||
|
|
||||||
class MainWindow :
|
class MainWindow :
|
||||||
public CGAL::Qt::DemosMainWindow
|
public CGAL::Qt::DemosMainWindow
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
@ -58,7 +58,7 @@ protected slots:
|
||||||
void on_actionDCP_triggered();
|
void on_actionDCP_triggered();
|
||||||
|
|
||||||
// save selected polyhedron as...
|
// save selected polyhedron as...
|
||||||
void on_actionSaveAs_triggered();
|
void on_actionSaveAs_triggered();
|
||||||
|
|
||||||
// defined in MainWindow_simplify.cpp
|
// defined in MainWindow_simplify.cpp
|
||||||
void on_actionSimplify_triggered();
|
void on_actionSimplify_triggered();
|
||||||
|
|
@ -100,7 +100,7 @@ protected:
|
||||||
// defined in MainWindow_boolean_operations.cpp
|
// defined in MainWindow_boolean_operations.cpp
|
||||||
void boolean_operation(const Boolean_operation operation);
|
void boolean_operation(const Boolean_operation operation);
|
||||||
|
|
||||||
#ifdef CGAL_TAUCS_ENABLED
|
#ifdef CGAL_USE_TAUCS
|
||||||
enum Parameterization_method { PARAM_MVC,
|
enum Parameterization_method { PARAM_MVC,
|
||||||
PARAM_DCP};
|
PARAM_DCP};
|
||||||
// defined in MainWindow_parameterization.cpp
|
// defined in MainWindow_parameterization.cpp
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifdef CGAL_TAUCS_ENABLED
|
#ifdef CGAL_USE_TAUCS
|
||||||
|
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
#include <QTime>
|
#include <QTime>
|
||||||
|
|
@ -34,7 +34,7 @@ void MainWindow::parameterize(const Parameterization_method method)
|
||||||
QTime time;
|
QTime time;
|
||||||
time.start();
|
time.start();
|
||||||
typedef CGAL::Parameterization_polyhedron_adaptor_3<Polyhedron> Adaptor;
|
typedef CGAL::Parameterization_polyhedron_adaptor_3<Polyhedron> Adaptor;
|
||||||
Adaptor adaptor(*pMesh);
|
Adaptor adaptor(*pMesh);
|
||||||
|
|
||||||
bool success;
|
bool success;
|
||||||
switch(method)
|
switch(method)
|
||||||
|
|
@ -73,7 +73,7 @@ void MainWindow::parameterize(const Parameterization_method method)
|
||||||
|
|
||||||
Polyhedron::Vertex_iterator it1;
|
Polyhedron::Vertex_iterator it1;
|
||||||
Textured_polyhedron::Vertex_iterator it2;
|
Textured_polyhedron::Vertex_iterator it2;
|
||||||
for(it1 = pMesh->vertices_begin(),
|
for(it1 = pMesh->vertices_begin(),
|
||||||
it2 = pTex_polyhedron->vertices_begin();
|
it2 = pTex_polyhedron->vertices_begin();
|
||||||
it1 != pMesh->vertices_end(),
|
it1 != pMesh->vertices_end(),
|
||||||
it2 != pTex_polyhedron->vertices_end();
|
it2 != pTex_polyhedron->vertices_end();
|
||||||
|
|
@ -106,7 +106,7 @@ void MainWindow::on_actionDCP_triggered()
|
||||||
parameterize(PARAM_DCP);
|
parameterize(PARAM_DCP);
|
||||||
}
|
}
|
||||||
|
|
||||||
#else // #ifdef CGAL_TAUCS_ENABLED
|
#else // #ifdef CGAL_USE_TAUCS
|
||||||
|
|
||||||
void MainWindow::on_actionMVC_triggered()
|
void MainWindow::on_actionMVC_triggered()
|
||||||
{
|
{
|
||||||
|
|
@ -116,4 +116,4 @@ void MainWindow::on_actionDCP_triggered()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // #ifdef CGAL_TAUCS_ENABLED
|
#endif // #ifdef CGAL_USE_TAUCS
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue