Small issue to gcc compiling

This commit is contained in:
Paolo Cignoni cignoni 2007-06-07 10:42:43 +00:00
parent 6b98a018ed
commit 5f03c46c81
3 changed files with 13 additions and 18 deletions

View File

@ -40,7 +40,7 @@ namespace vcg {
*s = 0;
}
else {
if (abs(b)>abs(a)) {
if (fabs(b)>fabs(a)) {
tao = -a/b;
*s = 1.0/sqrt(1.0+tao*tao);
*c = *s * tao;
@ -152,17 +152,17 @@ namespace vcg {
//Mvi matrix ready for the vertex vi
//calculate principal directions and curvature
Point3<double> Wvi;
Matrix33<double> Qvi;
Matrix33<double> QviT;
Matrix33<double> tempMatrix;
Point3d Wvi;
Matrix33d Qvi;
Matrix33d QviT;
Matrix33d tempMatrix;
Matrix33<double> A;
Point3<double> E1 = Point3<double>(1,0,0);
Point3<double> Nvi = Point3<double>( (double)(*vi).N()[0], (double)(*vi).N()[1], (double)(*vi).N()[2]);
Matrix33d A;
Point3d E1(1.0,0.0,0.0);
Point3d Nvi = Point3d::Construct((*vi).N());
Nvi.Normalize();
Point3<double> E1nNvi = E1 - Nvi;
Point3<double> E1pNvi = E1 + Nvi;
Point3d E1nNvi = E1 - Nvi;
Point3d E1pNvi = E1 + Nvi;
if (E1nNvi.Norm() > E1pNvi.Norm() ) Wvi = E1nNvi / E1nNvi.Norm();
else Wvi = E1pNvi / E1pNvi.Norm();

View File

@ -75,7 +75,7 @@ namespace vcg {
Matrix33<double> n_nMatrix;
Point3<double> ViVj;
Point3<double> Tij;
Point3<CoordType::ScalarType> tempViVj = p->P() - q->P();
Point3<typename CoordType::ScalarType> tempViVj = p->P() - q->P();
Point3<double> n = Point3<double>((double)p->N()[0], (double)p->N()[1], (double)p->N()[2]);
n = n.Normalize();
n_nMatrix.ExternalProduct(n, n);

View File

@ -1,19 +1,14 @@
TEMPLATE = lib
CONFIG += plugin
INCLUDEPATH += ../.. ../../../../sf ../../../../code/lib/glew/include
HEADERS = editsegment.h cutting.h curvaturetensor.h meshcutdialog.h ui_meshcutdialog.h
HEADERS = editsegment.h cutting.h curvaturetensor.h meshcutdialog.h
SOURCES = editsegment.cpp ../../../../code/lib/glew/src/glew.c meshcutdialog.cpp
TARGET = editsegment
DESTDIR = ../../meshlab/plugins
DEFINES += GLEW_STATIC
QT += opengl
#RESOURCES = meshlab.qrc
unix{
QMAKE_CC = gcc
QMAKE_CXX = g++
QMAKE_LINK = gcc
CONFIG += warn_off debug_and_release
}
FORMS+=meshcutdialog.ui
contains(TEMPLATE,lib){
CONFIG(debug, debug|release){
unix{