Commit Graph

15 Commits

Author SHA1 Message Date
Paolo Cignoni 7befff7bec make point2 derived Eigen's Matrix, and a set of minimal fixes to make meshlab compile
with both old and new version. The fixes include:
- dot product: vec0 * vec1 => vec0.dot(vec1) (I added .dot() to the old Point classes too)
- Transpose: Transpose is an Eigen type, so we cannot keep it if Eigen is used. Therefore
  I added a .tranpose() to old matrix classes, and modified most of the Transpose() to transpose()
  both in vcg and meshlab. In fact, transpose() are free with Eigen, it simply returns a transpose
  expression without copies. On the other be carefull:  m = m.transpose() won't work as expected,
  here me must evaluate to a temporary: m = m.transpose().eval(); However, this operation in very
  rarely needed: you transpose at the same sime you set m, or you use m.transpose() directly.
- the last issue is Normalize which both modifies *this and return a ref to it. This behavior
  don't make sense anymore when using expression template, e.g., in (a+b).Normalize(), the type
  of a+b if not a Point (or whatever Vector types), it an expression of the addition of 2 points,
  so we cannot modify the value of *this, since there is no value. Therefore I've already changed
  all those .Normalize() of expressions to the Eigen's version .normalized().
- Finally I've changed the Zero to SetZero in the old Point classes too.
2008-10-28 00:59:46 +00:00
Paolo Cignoni 17369b521b Matrix transformations corrected in glCylinder and glArrow. 2008-06-23 14:33:51 +00:00
Paolo Cignoni e7200db32e remove warning C4244 2006-07-03 13:46:34 +00:00
Paolo Cignoni 47e62b3c6e Removed all GLUT dependencies! 2006-05-25 09:22:58 +00:00
Paolo Cignoni 309fa30451 Wrong matrix type in cone (thx Maarten) 2006-03-29 07:54:03 +00:00
Nico Pietroni e9b8ee44e1 unified use of float in drawing methods 2006-01-03 11:13:25 +00:00
Federico Ponchio d652973606 glut->GL/glut (for real this time) 2005-12-06 14:11:15 +00:00
ganovelli 3312583e86 glut.h --> GL/glut.h 2005-07-23 09:21:37 +00:00
Paolo Cignoni 2d2bbfb454 fix some bugs 2005-07-11 09:04:26 +00:00
Paolo Cignoni 701abb9c2c modificato:
- void  Cone(..)
 aggiustate le normali per avere un effetto piu' gradevole.
2005-06-30 13:20:32 +00:00
Nico Pietroni 0a7cd4af5c minor changes 2005-05-19 09:09:54 +00:00
Nico Pietroni 6160f0545d added boolean parameter to use on not the display list 2005-04-04 11:59:16 +00:00
Nico Pietroni a5128f71e3 added disabling of cullfaces to obtaing a correct visualization of arrows 2005-03-03 13:29:35 +00:00
Nico Pietroni 5ce9f028b7 1 error corrected in display list of glCylinder 2005-03-03 13:11:30 +00:00
Nico Pietroni 0663f16525 first working version 2005-03-03 10:48:54 +00:00