problem

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

problem

Kurt Klaus Horvath
Hallo,
based on the sample "\examples\Ridges_3\Compute_Ridges_Umbilics.cpp" i try to setup my own application but there seems to be some kind of dependency or template problem which i dont really understand

1) i can compile the sample program and run it using visual studio 2015

2) i did try to setup a small standalone application and to isolate the problem. visual studio 2015 and also 2017 tell me:

error C2976: 'CGAL::Monge_via_jet_fitting': too few template arguments
error C2955: 'CGAL::Monge_via_jet_fitting': use of class template requires template argument list

it seems there is a problem with the interpretation of the of the template, here is my test-application
###############################
#include "stdafx.h"
#include <CGAL/Monge_via_jet_fitting.h>

int main()
{
typedef CGAL::Simple_cartesian<double>  Kernel;

typedef CGAL::Monge_via_jet_fitting<Kernel>    Monge_via_jet_fitting;
typedef Monge_via_jet_fitting::Monge_form      Monge_form;

    return 0;
}
##################################

is there any kind of special setting i need to apply? the cmake files used by cgal seems to do some settings which does fix that but i couldnt really find out what it is 

i use "CGAL-4.12-beta1"

\br & thx

Kurt
Reply | Threaded
Open this post in threaded view
|

Re: problem

Simon Giraudot-2
Hello,

CGAL::Monge_via_jet_fitting has 3 template arguments and you only provided the first one, see documentation: https://doc.cgal.org/latest/Jet_fitting_3/classCGAL_1_1Monge__via__jet__fitting.html

The documentation also mentions "If CGAL_EIGEN3_ENABLED is defined, LocalKernel and SvdTraits template parameters have defaults, Simple_cartesian<double> and Eigen_svd respectively". This is the case for the example that is compiled using the Eigen library (this is why only the first template argument is specified here). If you want to get the same behavior, you need to compile using Eigen too.

Best,

-- 
Simon Giraudot, PhD
R&D Engineer
GeometryFactory - http://geometryfactory.com/


Le 03/04/2018 à 12:34, Kurt Klaus Horvath a écrit :
Hallo,
based on the sample "\examples\Ridges_3\Compute_Ridges_Umbilics.cpp" i try to setup my own application but there seems to be some kind of dependency or template problem which i dont really understand

1) i can compile the sample program and run it using visual studio 2015

2) i did try to setup a small standalone application and to isolate the problem. visual studio 2015 and also 2017 tell me:

error C2976: 'CGAL::Monge_via_jet_fitting': too few template arguments
error C2955: 'CGAL::Monge_via_jet_fitting': use of class template requires template argument list

it seems there is a problem with the interpretation of the of the template, here is my test-application
###############################
#include "stdafx.h"
#include <CGAL/Monge_via_jet_fitting.h>

int main()
{
typedef CGAL::Simple_cartesian<double>  Kernel;

typedef CGAL::Monge_via_jet_fitting<Kernel>    Monge_via_jet_fitting;
typedef Monge_via_jet_fitting::Monge_form      Monge_form;

    return 0;
}
##################################

is there any kind of special setting i need to apply? the cmake files used by cgal seems to do some settings which does fix that but i couldnt really find out what it is 

i use "CGAL-4.12-beta1"

\br & thx

Kurt

Reply | Threaded
Open this post in threaded view
|

Re: problem

Kurt Klaus Horvath
Hi,
thx indeed that solved it, i did just add  CGAL_EIGEN3_ENABLED

\br

On Tue, Apr 3, 2018 at 12:42 PM, Simon Giraudot <[hidden email]> wrote:
Hello,

CGAL::Monge_via_jet_fitting has 3 template arguments and you only provided the first one, see documentation: https://doc.cgal.org/latest/Jet_fitting_3/classCGAL_1_1Monge__via__jet__fitting.html

The documentation also mentions "If CGAL_EIGEN3_ENABLED is defined, LocalKernel and SvdTraits template parameters have defaults, Simple_cartesian<double> and Eigen_svd respectively". This is the case for the example that is compiled using the Eigen library (this is why only the first template argument is specified here). If you want to get the same behavior, you need to compile using Eigen too.

Best,

-- 
Simon Giraudot, PhD
R&D Engineer
GeometryFactory - http://geometryfactory.com/


Le 03/04/2018 à 12:34, Kurt Klaus Horvath a écrit :
Hallo,
based on the sample "\examples\Ridges_3\Compute_Ridges_Umbilics.cpp" i try to setup my own application but there seems to be some kind of dependency or template problem which i dont really understand

1) i can compile the sample program and run it using visual studio 2015

2) i did try to setup a small standalone application and to isolate the problem. visual studio 2015 and also 2017 tell me:

error C2976: 'CGAL::Monge_via_jet_fitting': too few template arguments
error C2955: 'CGAL::Monge_via_jet_fitting': use of class template requires template argument list

it seems there is a problem with the interpretation of the of the template, here is my test-application
###############################
#include "stdafx.h"
#include <CGAL/Monge_via_jet_fitting.h>

int main()
{
typedef CGAL::Simple_cartesian<double>  Kernel;

typedef CGAL::Monge_via_jet_fitting<Kernel>    Monge_via_jet_fitting;
typedef Monge_via_jet_fitting::Monge_form      Monge_form;

    return 0;
}
##################################

is there any kind of special setting i need to apply? the cmake files used by cgal seems to do some settings which does fix that but i couldnt really find out what it is 

i use "CGAL-4.12-beta1"

\br & thx

Kurt