Index: GTP/trunk/Lib/Geom/shared/GTGeometry/src/GeoMeshSimplifier.cpp
===================================================================
--- GTP/trunk/Lib/Geom/shared/GTGeometry/src/GeoMeshSimplifier.cpp	(revision 2127)
+++ GTP/trunk/Lib/Geom/shared/GTGeometry/src/GeoMeshSimplifier.cpp	(revision 2194)
@@ -224,6 +224,4 @@
 	VMI::vTexCoords	=	vTexCoords;
 
-	
-
 	mGeoMesh	=	new Mesh();
 
@@ -252,8 +250,10 @@
 
 	if (VMI::bLoadCamerasFromFile == GL_FALSE)
-		VMI::cameras = VMI::setCameras(VMI::radius, VMI::cameraType, &VMI::numCameras);
+		VMI::cameras = VMI::setCameras(	VMI::radius, 
+																		VMI::cameraType,
+																		&VMI::numCameras);
 
 	VMI::histogram	=	VMI::initHistogram(	VMI::mesh->currentNumTriangles,
-			VMI::numCameras);
+																				VMI::numCameras);
 
 	VMI::initialIs	=	VMI::initIs(VMI::numCameras);
@@ -272,6 +272,6 @@
 }
 
-/// Starts the simplification process. Receives as a parameter the 
-///	LOD factor in a range of [0,1]. Implements the 
+/// Starts the simplification process. Receives as a parameter the
+///	LOD factor in a range of [0,1]. Implements the
 ///	Simplifier::Simplify method to perform an image based simplification.
 void ViewPointDrivenSimplifier::Simplify(Real percent)
@@ -333,5 +333,5 @@
 
 	VMI::contractInitialMesh(VMI::mesh);
-
+	
 	//	Load a geometry mesh for vmi mesh.
 	loadMesh();
@@ -431,10 +431,9 @@
 		vmi_mesh->vertices[i].z = vertex_buffer->mPosition[i].z;
 
-		vmi_mesh->vertices[i].numTriangles = 0;
-		vmi_mesh->vertices[i].triangles = NULL;
-		vmi_mesh->vertices[i].numEdges = 0;
-		vmi_mesh->vertices[i].edges = NULL;
-		vmi_mesh->vertices[i].enable 	= GL_TRUE;
-		vmi_mesh->vertices[i].movable = GL_TRUE;
+		vmi_mesh->vertices[i].numTriangles	= 0;
+		vmi_mesh->vertices[i].triangles			= NULL;
+		vmi_mesh->vertices[i].numEdges			= 0;
+		vmi_mesh->vertices[i].edges					= NULL;
+		vmi_mesh->vertices[i].enable				= GL_TRUE;
 	}
 	
@@ -468,7 +467,10 @@
 			vmi_mesh->triangles[index].indices[2] = geosubmesh->mIndex[(3 * i) + 2];
 
-			vmi_mesh->triangles[index].area = computeTriangleArea(vmi_mesh->vertices, 
-					&vmi_mesh->triangles[index]);
-			computeTriangleNormal(vmi_mesh->vertices, &vmi_mesh->triangles[index]);
+			vmi_mesh->triangles[index].area = computeTriangleArea(
+																						vmi_mesh->vertices, 
+																						&vmi_mesh->triangles[index]);
+
+			computeTriangleNormal(vmi_mesh->vertices,
+														&vmi_mesh->triangles[index]);
 
 			vmi_mesh->triangles[index].saliency = 0.0;
@@ -482,5 +484,9 @@
 
 				// Reallocate memory for the new adjacent triangle.
-				vmi_mesh->vertices[v1].triangles = (int *)realloc(vmi_mesh->vertices[v1].triangles, (vmi_mesh->vertices[v1].numTriangles + 1) * sizeof(int));
+				vmi_mesh->vertices[v1].triangles = 
+											(int *)realloc(vmi_mesh->vertices[v1].triangles,
+											(vmi_mesh->vertices[v1].numTriangles + 1)
+											*
+											sizeof(int));
 
 				VMI::addItem(	(int *)vmi_mesh->vertices[v1].triangles,
@@ -503,6 +509,6 @@
 	// E = 3 T / 2
 	vmi_mesh->edges = (VMI::Edge *)malloc(sizeof(VMI::Edge)
-																		*
-																		vmi_mesh->numTriangles * 3);
+										*
+										vmi_mesh->numTriangles * 3);
 
 	if (vmi_mesh->edges == NULL)
@@ -554,17 +560,26 @@
 	vmi_mesh->numEdges = n;
 
-	for (i=0; i<vmi_mesh->numEdges; i++) {
+	for (i	=	0; i < vmi_mesh->numEdges; i++)
+	{
 		v1 = vmi_mesh->edges[i].u;
 		v2 = vmi_mesh->edges[i].v;
 
-		vmi_mesh->vertices[v1].edges = 
-			(int *)realloc(vmi_mesh->vertices[v1].edges, (vmi_mesh->vertices[v1].numEdges + 1) * sizeof(int));
+		vmi_mesh->vertices[v1].edges	=
+							(int *)realloc(vmi_mesh->vertices[v1].edges,
+							(vmi_mesh->vertices[v1].numEdges + 1) * sizeof(int));
+
 		// Adding edge i adjacent to vertex v1
-		VMI::addItem(vmi_mesh->vertices[v1].edges, &vmi_mesh->vertices[v1].numEdges, i);
-
-		vmi_mesh->vertices[v2].edges = 
-			(int *)realloc(vmi_mesh->vertices[v2].edges, (vmi_mesh->vertices[v2].numEdges + 1) * sizeof(int));
+		VMI::addItem(	vmi_mesh->vertices[v1].edges,
+									&vmi_mesh->vertices[v1].numEdges,
+									i);
+
+		vmi_mesh->vertices[v2].edges =
+								(int *)realloc(vmi_mesh->vertices[v2].edges,
+								(vmi_mesh->vertices[v2].numEdges + 1) * sizeof(int));
+
 		// Adding edge i adjacent to vertex v2
-		VMI::addItem(vmi_mesh->vertices[v2].edges, &vmi_mesh->vertices[v2].numEdges, i);
+		VMI::addItem(	vmi_mesh->vertices[v2].edges,
+									&vmi_mesh->vertices[v2].numEdges,
+									i);
 	}
 
