added to IsValidHandle the check that pointer to data is not null.
Explanation:
a handle may be not valid for two reasons:
1) the attribute has been destroyed with a DeletePer*Attribute
2) the handle has been declared but not initialized.
The change is to cover the case 2)
added to IsValidHandle the check that pointer to data is not null.
Explanation:
a handle may be not valid for two reasons:
1) the attribute has been destroyed with a DeletePer*Attribute
2) the handle has been declared but not initialized.
The change is to cover the case 2)
The member 'camera' of the base trimesh class, is no more used since Dec 2006.His initial purpose was keeping intrinsics of the camera, but it is a long time that intrinsics have moved into the Shot class.
The I/O procedure already comply this fact filling only the interal structure.
This modification removes the old way to define simplexes (already deprecated and unsupported).
In the following SIMPLEX = [vertex|edge|face|tetrahedron]
All the stuff that was in vcg/simplex/SIMPLEXplus/ has now been promoted to vcg/simplex/
Details:
- the folder vcg/simplex/SIMPLEX/with has been removed
- the file vcg/simplex/SIMPLEX/base.h has been renamed into vcg/simplex/SIMPLEX/base_old.h
- the content of vcg/simplex/SIMPLEXplus/ has been moved into vcg/simplex/SIMPLEX/
- the folder vcg/simplex/SIMPLEXplus/ has been removed
Actions the update the code using vcglib:
replace <vcg/simplex/SIMPLEXplus/*> with <vcg/simplex/SIMPLEX/*> in every include
for MESHLAB users: already done along with this commit
Added default template to TriMesh to include the edges.
Added peredge attributes.
These modification do not require any change to the code using TriMesh, but it allows
to specify a real type of edge in case you want to use it.
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.
* 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
Added components to the face to handle generic polygons.
(compiled with .net and gcc)
This commit includes the following files:
vcg/complex/trimesh/base.h
Added deallocation of polygon data in the destructor
vcg/complex/trimesh/allocate.h
generalization from 3 to VN() vertices
vcg/complex/trimesh/update/topology.h
generalization from 3 to VN() vertices
vcg/complex/trimesh/update/flags.h
generalization from 3 to VN() vertices
vcg/simplex/face/pos.h
generalization from 3 to VN() vertices
vcg/simplex/faceplus/base.h
Added the method VN() to query the number of vertices
of the polygon (deafult 3) and methods Prev and Next
vcg/simplex/faceplus/component.h
added Alloc and Dealloc calls along the hierarchies
vert->vertex
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
vert->vertex
trimesh->tri
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
vert->vrt
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
vert->vrt
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
vert->vrt
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
vert->vrt
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
trimesh->tri
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
trimesh->tri
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
trimesh->tri
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
vert->vertex
trimesh->tri
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
trimesh->tri
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
edge->edg
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
edge->edg
trimesh->tri
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
[Namespaces changes]
vert->vertex
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
edge->edg
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
edge->edg
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (extended namespaces):
order 0 (vertex) :vertex
order 1 (edge) :edge
order 2 (triangle) :triangle (temporarily it remains "face")
order 3 (tetrahedron) :tetrahedron
[Namespaces changes]
edge->edg
clean up of some namespaces to comply the following naming:
Complexes (3 letters namespaces):
order 0 (point cloud ) :vrt
order 1 (edge meshes) :edg
order 2 (triangle meshes) :tri
order 3 (triangle meshes) :tet
Simplexes (4 letters namespaces):
order 0 (vertex) :vert
order 1 (edge) :edge
order 2 (triangle) :triangle
order 3 (tetrahedron) :tetrahedron
An ENUM for Desaturation methods has been added too.
Added EQ filter and relative functions. It works just on lighness right now. Comments still to be written. work in progress.