Commit Graph

139 Commits

Author SHA1 Message Date
Paolo Cignoni ad2cb4678a Converted to support highdpi devices 2013-12-16 12:15:20 +00:00
Paolo Cignoni 2e65cae10e HEAVY CHANGE. Further cleaning of the matrix classes of VCG.
Get rid of all the unused stuff. 
internally use Eigen for computing Inverse. 
Removed the stupid incomprehensible method Invert() that changed the matrix itself. 
Nobody was using it in a reasonable way.
2013-03-19 16:59:45 +00:00
Paolo Cignoni 794f2f27a7 Small Change of the Trackball apply interface. It does no more require a bool to specify if the trackball icon has to be drawn because it is always wrong to draw the trackball at the apply time (two reasons, antialiasing and transparency and zbuffer preservation) So now the standard call is just Apply() without the useless bool parameters.
Updated also all the vcg samples using the trackball
2013-01-28 15:15:14 +00:00
ganovelli 0f99bd505e changes and minor fix to enable input/output with VMI on memory 2012-07-02 14:38:10 +00:00
Paolo Cignoni a912ac3a82 Small changed in the rendering of the trackball icon to remove the stepped line effect due to line antialiasing 2012-03-06 11:52:00 +00:00
Paolo Cignoni f64b175b13 Updating after the change
IntersectionPlaneLine -> IntersectionLinePlane
2012-01-18 16:49:18 +00:00
Marco Callieri b853e5fd3f - removed from standard trackball rendering the useless plane handles (can be re-drawn using a parameter, that is false by default)
- different color on the three circles of the trackball (X red, Y green, Z blue)
2011-12-20 12:27:30 +00:00
Federico Ponchio fbee572ad2 removing trash. 2011-12-09 16:08:33 +00:00
Federico Ponchio 4400d8dd2d added multithreading 2011-12-09 16:06:08 +00:00
ganovelli 6f804cbb20 Distance plane point updated with lib 2011-11-18 14:46:38 +00:00
Paolo Cignoni 2fe129645b Rolled back 2011-10-05 15:04:40 +00:00
Paolo Cignoni 646cfe482d With a couple of parenthesis no need any more for NOMINMAX 2011-03-25 10:37:07 +00:00
Federico Ponchio a464fed6ae IsOutside returns distance now. (and 0 if inside :) 2010-11-22 16:48:02 +00:00
Federico Ponchio 327de0c77e fixed bug in getModelPlane 2010-11-15 00:09:48 +00:00
Federico Ponchio b8c868da99 added some doc. 2010-11-15 00:06:15 +00:00
Paolo Cignoni 30186419dc Updated to the new glLabel calling style 2010-10-31 13:07:17 +00:00
Nico Pietroni 88ec283477 corrected ClosestPoint and DIstance function calls to the ones in distance3.h 2010-10-15 15:22:30 +00:00
Nico Pietroni 0b2b8f8700 removed SegmentSegmentDistance function, it must be used the one in distance3.h 2010-10-15 15:21:43 +00:00
granzuglia 7df0c698d6 used QPainter to render the axis labels 2010-10-04 08:46:19 +00:00
Paolo Cignoni f299a80c7b added two glgeterror for cleaning the error stack after qt render text 2010-09-30 08:12:54 +00:00
Paolo Cignoni 349e9869cf Updated many vcg files to do not use anymore the vcg::Max(a,b) and vcg::Min(a,b). Use the std version instead. 2010-09-21 22:09:13 +00:00
Federico Ponchio 1111b67e7e fixed resolution 2010-04-29 16:54:10 +00:00
Federico Ponchio 975ecd103e added range (for near and far computation) 2010-04-25 20:37:59 +00:00
Federico Ponchio bae0c7decc added SetView allowing direct passing of matrices. 2010-04-20 18:23:51 +00:00
Paolo Cignoni f017c8646e removed "suggest parentheses around && within ||" warning 2010-01-11 09:30:44 +00:00
Paolo Cignoni 9608ec798b compilation fixes with Eigen 2009-07-21 07:29:13 +00:00
Marco Di Benedetto 816b49a3e5 removed some warnings. 2009-06-30 19:02:17 +00:00
Paolo Cignoni 0c5aefb278 Added ClearModes() method to trackball to avoid leaking and corruptions due to double deletion of modes. 2009-04-01 14:53:20 +00:00
Paolo Cignoni efde1babe5 Sorry, corrected a mistake in the Matrix() method due to a temporary local library change. Won't do that again. 2009-03-31 09:23:20 +00:00
Paolo Cignoni a353708f16 Added Matrix)() and InverseMatrix() methods, which respectively return the direct and inverse matrices that describe how the trackball similarity is applied with respect to the trackball center.
Corrected ToAscii() and SetFromAscii() methods, which should work with 8 values instead of 9 (well, in effect they are implemantation dependent methods, so...).
2009-03-31 09:03:18 +00:00
Paolo Cignoni 946ae834b8 Changed the include guard. Added comment to remember that the View class is used only by the trackball 2009-03-11 09:32:12 +00:00
Paolo Cignoni 8a53c7a836 Fixed memory leak 2009-01-23 13:58:20 +00:00
Paolo Cignoni 928c8dd997 Removed harmless warnings 2008-11-28 14:55:45 +00:00
Paolo Cignoni 16e51c9d75 Corrected long standing bug of double deletion of trackmodes. New safer destructor 2008-11-13 09:33:43 +00:00
mtarini 80f1fa2396 Added NavigatorWasdMode: doom-like navigation around/inside objects (see samples/SDL_trackball for an example) 2008-11-12 16:36:55 +00:00
mtarini 1ad548c24c Added animations and keys (so far, only used by the Navigator Mode) 2008-11-12 16:33:40 +00:00
Paolo Cignoni 0f2d864e05 remove a trailing print() 2008-10-30 11:31:28 +00:00
Paolo Cignoni e587581275 add transposeInPlace and duplicate V(int) 2008-10-29 11:17:11 +00:00
Paolo Cignoni 07f2e976ea * change all remaining Transpose to transpose,
* update the gl/math wrappers to make them more Eigen friendly
  (and remove the useless, and not used, and somehow dangerous
   *Direct and *E functions)
* add automatic reinterpret_casting from Eigen::Matrix to vcg
  specialized types
2008-10-29 00:05:44 +00:00
Federico Ponchio 632f4842f1 Polar mode now working. 2008-10-28 16:43:56 +00:00
Paolo Cignoni c0c76bc5b8 added Polarmode prototype (doesn't work yet) 2008-10-28 15:55:40 +00:00
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 ab200fc950 Port to eigen2: state of the mess:
* curently nothing change if you don't define VCG_USE_EIGEN
* make Matrix*, Point3 and Point4 derive Eigen::Matrix (still ugly)
* now catching all the dot products to replace them by .dot()
  note that most of meshlab already compile
2008-10-27 19:35:17 +00:00
Paolo Cignoni dcbb7456ac Added by default rotation on middle + alt, (almost a standard on various 3d packages). Kind patch submitted by Sebastian Herholz. 2008-09-22 23:10:00 +00:00
Paolo Cignoni d3ac368bd5 Updated references of SetRotate to the new SetRotateDeg/SetRotateRad interface 2008-07-13 07:41:20 +00:00
Paolo Cignoni bafcd1768e remove harmless warnings 2008-07-02 13:26:25 +00:00
Paolo Cignoni 5fa10cda23 made generic functions static 2008-04-10 11:09:34 +00:00
Paolo Cignoni 4bd2caa2e6 improved comments 2008-03-21 16:09:02 +00:00
Paolo Cignoni 0af424701d Added doxygen documentation 2008-03-21 16:08:43 +00:00
Paolo Cignoni 35848b0a77 improved comments 2008-03-14 17:15:59 +00:00