Index: GTP/trunk/Lib/Geom/shared/GeoTool/include/GeoMeshViewUI.h
===================================================================
--- GTP/trunk/Lib/Geom/shared/GeoTool/include/GeoMeshViewUI.h	(revision 1554)
+++ GTP/trunk/Lib/Geom/shared/GeoTool/include/GeoMeshViewUI.h	(revision 2090)
@@ -88,4 +88,6 @@
 using	namespace	std;
 
+//-----------------------------------------------------------------------------
+//-----------------------------------------------------------------------------
 class GeoToolIndexData : public Geometry::IndexData
 {
@@ -131,4 +133,7 @@
 };
 
+//-----------------------------------------------------------------------------
+//	Class User Interface of GeoTool.
+//-----------------------------------------------------------------------------
 class GeoMeshViewUI
 {
@@ -198,4 +203,6 @@
 	inline void cb_menuRenderSolid_i(fltk::Item*, void*);
 	static void cb_menuRenderSolid(fltk::Item*, void*);
+	inline void cb_menuRenderLighting_i(fltk::Item*, void*);
+	static void cb_menuRenderLighting(fltk::Item*, void*);
 	inline void cb_menuRenderCW_i(fltk::Item*, void*);
 	static void cb_menuRenderCW(fltk::Item*, void*);
@@ -361,4 +368,5 @@
 	fltk::Item					*menuRenderWire;
 	fltk::Item					*menuRenderSolid;
+	fltk::Item					*menuRenderLighting;
 	fltk::Item					*menuRenderCW;
 	fltk::Item					*menuRenderCCW;
Index: GTP/trunk/Lib/Geom/shared/GeoTool/include/GeoMeshView.h
===================================================================
--- GTP/trunk/Lib/Geom/shared/GeoTool/include/GeoMeshView.h	(revision 1549)
+++ GTP/trunk/Lib/Geom/shared/GeoTool/include/GeoMeshView.h	(revision 2090)
@@ -34,4 +34,5 @@
 	bool		mWire;
 	bool		mSolid;
+	bool		mLighting;
 	bool		mCW;
 	bool		mCCW;
@@ -95,4 +96,8 @@
 	void	activeSolid(){mSolid	=	true;};
 	void	deactiveSolid(){mSolid	=	false;};
+
+	//	Lighting.
+	void	activeLighting(){mLighting	=	true;};
+	void	deactiveLighting(){mLighting	=	false;};
 
 	//	Clockwise mode.
Index: GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshViewUI.cpp
===================================================================
--- GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshViewUI.cpp	(revision 1560)
+++ GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshViewUI.cpp	(revision 2090)
@@ -4,11 +4,12 @@
 #include "resource.h"
 #include "GeoLodTreeConstructor.h"
+#include <string.h>
 
 using	namespace	Geometry;
 using	namespace	std;
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Menu File Open Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuFileOpen_i(fltk::Item*, void*)
 {
@@ -101,7 +102,7 @@
 
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Repaint the FPS label.
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 void	GeoMeshViewUI::refreshFPS(int fps)
 {
@@ -124,7 +125,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Save callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuFileSave_i(fltk::Item*, void*)
 {
@@ -152,7 +153,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Save As Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuFileSaveAs_i(fltk::Item*, void*)
 {
@@ -215,5 +216,5 @@
 				//-------------------------------------
 
-				mesh_saver->save(mGeoMesh,filename_name(file_name));
+				mesh_saver->save(mGeoMesh,file_name);
 
 				delete	mesh_saver;
@@ -234,7 +235,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Mesh info callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuMeshInfo_i(fltk::Item*, void*)
 {
@@ -253,7 +254,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Mesh Export to OBJ callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuMeshExportOBJ_i(fltk::Item*, void*)
 {
@@ -278,7 +279,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Transform to Shared Vertex callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuTransformSharedVertex_i(fltk::Item*, void*)
 {
@@ -323,7 +324,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Quit Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuFileQuit_i(fltk::Item*, void*)
 {
@@ -338,7 +339,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Undo Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuEditUndo_i(fltk::Item*, void*)
 {
@@ -354,7 +355,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Fit Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuEditFit_i(fltk::Item*, void*)
 {
@@ -370,7 +371,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Rotate Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuEditRotate_i(fltk::Item	*item, void*)
 {	
@@ -402,7 +403,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Pan Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuEditPan_i(fltk::Item	*item, void*)
 {	
@@ -434,7 +435,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Zoom Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuEditZoom_i(fltk::Item*, void*)
 {
@@ -448,7 +449,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Wire Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuRenderWire_i(fltk::Item *item, void*)
 {
@@ -476,7 +477,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Solid Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuRenderSolid_i(fltk::Item	*item, void*)
 {
@@ -504,7 +505,32 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
+//	Lighting Callback
+//-------------------------------------------------------------------------
+inline void GeoMeshViewUI::cb_menuRenderLighting_i(fltk::Item	*item, void*)
+{
+	if (item->value())
+	{
+		geoMeshView->activeLighting();
+	}
+	else
+	{
+		geoMeshView->deactiveLighting();
+	}
+									
+	//	Repaint the main window.
+	mMainWindow->redraw();
+}
+
+void GeoMeshViewUI::cb_menuRenderLighting(fltk::Item* o, void* v)
+{
+  ((GeoMeshViewUI*)	(o->parent()->parent()->parent()->user_data()))
+										->
+										cb_menuRenderLighting_i(o,v);
+}
+
+//-------------------------------------------------------------------------
 //	CW callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuRenderCW_i(fltk::Item	*item, void*)
 {
@@ -534,7 +560,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	CCW callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuRenderCCW_i(fltk::Item	*item, void*)
 {
@@ -564,7 +590,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Flat callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuRenderFlat_i(fltk::Item*, void*)
 {
@@ -586,7 +612,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Smooth Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuRenderSmooth_i(fltk::Item*, void*)
 {
@@ -608,7 +634,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Textures callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuRenderTextures_i(fltk::Item*, void*)
 {
@@ -628,7 +654,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Stripify Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuStripify_i(fltk::Item*, void*)
 {
@@ -657,7 +683,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Simplify Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuSimplify_i(fltk::ItemGroup*, void*)
 {
@@ -671,7 +697,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Edge collapse Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuSimplifyEdgeCollapse_i(fltk::Item*, void*)
 {
@@ -701,7 +727,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Leaves collapse Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuSimplifyLeavesCollapse_i(fltk::Item*, void*)
 {
@@ -730,7 +756,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Tree select leaves simplification Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuSelectLeaves_i(fltk::Item*, void*)
 {
@@ -751,7 +777,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Auto Generate LodStrips Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuLodStripsGenerate_i(fltk::Item*, void*)
 {
@@ -781,7 +807,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Auto Generate LodStrips Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuLodTreesGenerate_i(fltk::Item*, void*)
 {
@@ -812,7 +838,7 @@
 
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Visualize LodStrips Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuLodStripsVisualize_i(fltk::Item*, void*)
 {
@@ -874,17 +900,7 @@
 		if (geoMeshLoader->GetTreeSimpSeq() && geoMeshLoader->GetLodStripsData())
 		{
-/*			// select the first triangle-list submesh as leaves submesh
-			int leafsSubMeshID = -1;
-
-			for (int i=0; i<mGeoMesh->mSubMeshCount; i++)
-			{
-				if (mGeoMesh->mSubMesh[i].mType==GEO_TRIANGLE_LIST)
-				{
-					leafsSubMeshID=i;
-					break;
-				}
-			}*/
-
-			setLodTreesLibrary(geoMeshLoader->GetLodStripsData(), geoMeshLoader->GetTreeSimpSeq(), mGeoMesh/*, leafsSubMeshID*/);
+			setLodTreesLibrary(	geoMeshLoader->GetLodStripsData(),
+													geoMeshLoader->GetTreeSimpSeq(),
+													mGeoMesh);
 
 			//	Sets the aplication mode.
@@ -923,7 +939,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Open LodStrip trunk Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuLodTreesOpenLodStripTrunk_i(fltk::Item*, void*)
 {
@@ -937,7 +953,7 @@
 }
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Open leaves simplification Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuLodTreesOpenLeavesSimplification_i(fltk::Item*, void*)
 {
@@ -964,7 +980,7 @@
 
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	About Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_menuHelpAbout_i(fltk::Item*, void*)
 {
@@ -983,7 +999,7 @@
 Index *orig_indices					=	NULL;
 
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 //	Button Process Callback
-//---------------------------------------------------------------------------
+//-------------------------------------------------------------------------
 inline void GeoMeshViewUI::cb_mButtonProcess_i(fltk::Button*, void*)
 {
@@ -1043,7 +1059,4 @@
 					mGeoMesh	=	mesh_aux;
 
-					// Visualize mesh.
-					geoMeshView->setMesh(mGeoMesh);
-
 					//	Simplify the mesh object.
 					if(simplifyEdgeCollapse())
@@ -1051,4 +1064,8 @@
 						geoMeshView->restoreContext();
 					}
+
+					// Visualize mesh.
+					geoMeshView->setMesh(mGeoMesh);
+
 				}
 				break;
@@ -1074,9 +1091,14 @@
 				else
 				{
-					origSubMeshVB=mGeoMesh->mSubMesh[idMeshLeaves].mVertexBuffer->Clone();
-					orig_numindices=mGeoMesh->mSubMesh[idMeshLeaves].mIndexCount;
-					orig_indices=new Index[orig_numindices];
-					for (int i=0; i<orig_numindices; i++)
+					origSubMeshVB	=	mGeoMesh->
+														mSubMesh[idMeshLeaves].mVertexBuffer->Clone();
+
+					orig_numindices	=	mGeoMesh->mSubMesh[idMeshLeaves].mIndexCount;
+					orig_indices		=	new Index[orig_numindices];
+
+					for (int i = 0; i < orig_numindices; i++)
+					{
 						orig_indices[i]=mGeoMesh->mSubMesh[idMeshLeaves].mIndex[i];
+					}
 
 					std::cout << "Simplificando hojas...";
@@ -1102,6 +1124,4 @@
 					//	Gets the mesh Shared Vertex.
 					mGeoMesh	=	mesh_aux;
-
-					geoMeshView->setMesh(mGeoMesh);
 
 					//	Simplify the mesh object.
@@ -1115,4 +1135,5 @@
 					}
 
+					geoMeshView->setMesh(mGeoMesh);
 				}
 				
@@ -1147,7 +1168,4 @@
 					mGeoMesh	=	mesh_aux;
 
-					// Visualize mesh.
-					geoMeshView->setMesh(mGeoMesh);
-
 					//	Simplify the mesh object.
 					if (simplifyEdgeCollapse())
@@ -1159,4 +1177,7 @@
 						activeBuildProcess();
 					}
+
+					// Visualize mesh.
+					geoMeshView->setMesh(mGeoMesh);
 				}
 
@@ -1259,4 +1280,5 @@
 					delete mUndoMesh;
 
+
 					mUndoMesh	=	new Mesh();
 
@@ -1454,4 +1476,5 @@
 	mViewPointDriven->set_visible();
 	mViewPointDriven->activate();
+	mViewPointDriven->clear();
 
 	/*
@@ -1472,6 +1495,8 @@
 	mVerticesNumber->set_visible();
 	mVerticesNumber->activate();
+	mVerticesNumber->clear();
 
 	mMeshReduction->set_visible();
+	mMeshReduction->value(100);
 
 	// Allows floating point.
@@ -1658,5 +1683,5 @@
 
 	//	Deactive VMI option.
-	mViewPointDriven->deactivate();
+	//mViewPointDriven->deactivate();
 
 	mButtonBuild->set_visible();
@@ -1745,10 +1770,16 @@
 }
 
-//---------------------------------------------------------------------------
+//--------------------------------------------------------------------------
 //	Show the mesh info browser.
-//---------------------------------------------------------------------------
+//--------------------------------------------------------------------------
 void	GeoMeshViewUI::showMeshInfo()
 {
-	char	type[10];
+	char						type[10];
+	unsigned	int		group_index;
+	unsigned	int		group_count;
+	unsigned	int		bone_count;
+	fltk::ItemGroup **info_group;
+	
+	group_index	=	0;
 	
 	if (mGeoMesh)
@@ -1759,9 +1790,42 @@
 		ogeometry->begin();
 
-		fltk::ItemGroup **oprueba;
-		oprueba=new fltk::ItemGroup*[mGeoMesh->mSubMeshCount];
+		group_count	=	mGeoMesh->mSubMeshCount;
+
+		//	Add one group for skeleton info.
+		if (mGeoMesh->hasSkeleton)
+		{
+			group_count++;
+		}
+
+		info_group	=	new fltk::ItemGroup*[group_count];
+
+		//	Write skeleton info.
+		if (mGeoMesh->hasSkeleton)
+		{
+			char	*group_name		=	new char[256];
+			char	*skel_name		=	new char[256];
+			char	*bone_assig		=	new char[256];
+			sprintf(group_name,"Skeleton");
+			info_group[group_index]	= new fltk::ItemGroup(group_name);
+
+			info_group[group_index]->begin();
+			sprintf(skel_name,"Name: %s",mGeoMesh->mSkeletonName);
+			new fltk::Item(skel_name);
+			bone_count	=	mGeoMesh->mBones.size();
+			
+			for (int i	=	0;	i < mGeoMesh->mSubMeshCount;	i++)
+			{
+				bone_count	+=	mGeoMesh->mSubMesh[i].mBones.size();
+			}
+			sprintf(bone_assig,"Bone assignamets: %d",bone_count);
+			new fltk::Item(bone_assig);
+			info_group[group_index]->end();
+
+			group_index++;
+		}
+
 		for(int i=0; i<mGeoMesh->mSubMeshCount;i++)
 		{
-			char *cadena=new char[256];
+			char	*group_name	=	new char[256];
 
 			if (geoMeshView->getLeavesSubMesh() >= 0)
@@ -1782,8 +1846,8 @@
 
 			//	Submesh identifier.
-			sprintf(cadena,"SubMesh %d %s",i,type);
+			sprintf(group_name,"SubMesh %d %s",i,type);
 			
-			oprueba[i] = new fltk::ItemGroup(cadena);
-			oprueba[i]->begin();
+			info_group[group_index] = new fltk::ItemGroup(group_name);
+			info_group[group_index]->begin();
 			fltk::Item *sharedGeometry;
 			if (mGeoMesh->mSubMesh[i].mSharedVertexBuffer)
@@ -1838,5 +1902,5 @@
 
 
-			oprueba[i]->end();
+			info_group[group_index]->end();
 		}
 		ogeometry->end();
@@ -1851,7 +1915,7 @@
 }
 
-//---------------------------------------------------------------------------
+//--------------------------------------------------------------------------
 //	Hide the mesh info browser.
-//---------------------------------------------------------------------------
+//--------------------------------------------------------------------------
 void	GeoMeshViewUI::hideMeshInfo()
 {
@@ -1860,7 +1924,7 @@
 }
 
-//---------------------------------------------------------------------------
+//--------------------------------------------------------------------------
 //	Hide the right panel.
-//---------------------------------------------------------------------------
+//--------------------------------------------------------------------------
 void	GeoMeshViewUI::hideRightPanel()
 {
@@ -1875,7 +1939,7 @@
 }
 
-//---------------------------------------------------------------------------
+//--------------------------------------------------------------------------
 //	Get the number of vertices.
-//---------------------------------------------------------------------------
+//--------------------------------------------------------------------------
 size_t	GeoMeshViewUI::getVertexCount(Mesh	*geoMesh)
 {
@@ -2013,4 +2077,5 @@
 	}
 
+	//	Saves OpenGL contex.
 	geoMeshView->saveContext();
 
@@ -2046,4 +2111,5 @@
 
 			//	Simplifica el geomesh -> Parámetro es un factor LOD [0,1].
+
 			mMeshSimplifier->Simplify(percent);
 
@@ -2059,7 +2125,4 @@
 
 			mGeoMesh	=	mMeshSimplifier->GetMesh();
-
-			//	Visualize mesh.
-			geoMeshView->setMesh(mGeoMesh);
 		}
 		else
@@ -2090,7 +2153,4 @@
 
 		mGeoMesh	=	mMeshSimplifier->GetMesh();
-
-		//	Visualize the mesh.
-		geoMeshView->setMesh(mGeoMesh);
 	}
 
@@ -2263,14 +2323,11 @@
 void	GeoMeshViewUI::undo()
 {
+	Mesh	*aux_mesh;
+
 	//	if the undo mesh is not initialized.
 	if	(mUndoMesh != NULL)
 	{
-		//	Deletes the actual mesh.
-		delete	mGeoMesh;
-
-		mGeoMesh	=	new Mesh();
-
-		//	Restore the previous mesh.
-		*mGeoMesh	=	*mUndoMesh;
+		aux_mesh	=	mGeoMesh;
+		mGeoMesh	=	mUndoMesh;
 
 		//	Visualize the mesh.
@@ -2282,4 +2339,9 @@
 		//	Repaint the window.
 		mMainWindow->redraw();
+
+		//	Deletes the actual mesh.
+		delete	aux_mesh;
+
+		mUndoMesh	=	NULL;
 	}
 }
@@ -2466,6 +2528,8 @@
 			menuRenderSolid->clear_value();
 			menuRenderWire->clear_value();
+			menuRenderLighting->set_value();
 			geoMeshView->deactiveSolid();
 			geoMeshView->deactiveWire();
+			geoMeshView->activeLighting();
 
 			//	Fit model in midle.
@@ -2808,4 +2872,9 @@
 
 				{
+					fltk::Item* o = new fltk::Item("Transform to SV");
+					o->callback((fltk::Callback*)cb_menuFileTransformSharedVertex);
+				}
+
+				{
 					menuLoadTextures = new fltk::ItemGroup("Load Textures");
 					o->add(menuLoadTextures);
@@ -2833,5 +2902,4 @@
 					fltk::Item* o = menuEditFit = new fltk::Item("Fit");
 					o->callback((fltk::Callback*)cb_menuEditFit);
-
 				}
 
@@ -2879,4 +2947,10 @@
 					o->type(fltk::Item::RADIO);
 					o->callback((fltk::Callback*)cb_menuRenderSolid);
+				}
+
+				{
+					fltk::Item* o = menuRenderLighting = new fltk::Item("Lighting");
+					o->type(fltk::Item::RADIO);
+					o->callback((fltk::Callback*)cb_menuRenderLighting);
 				}
 
Index: GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshView.cpp
===================================================================
--- GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshView.cpp	(revision 1554)
+++ GTP/trunk/Lib/Geom/shared/GeoTool/src/GeoMeshView.cpp	(revision 2090)
@@ -6,5 +6,5 @@
 
 //---------------------------------------------------------------------------
-//	Hanle events.
+//	Handle events.
 //---------------------------------------------------------------------------
 int	GeoMeshView::handle(int event)
@@ -46,5 +46,5 @@
 						if (mPan)
 						{
-							xshift	=	xshift	+	(x	-	mMouseX);
+							xshift	=	xshift	+	0.01;
 						}
 						else
@@ -59,5 +59,5 @@
 							if (mPan)
 							{
-								xshift	=	xshift	-	(mMouseX	-	x);
+								xshift	=	xshift	-	0.01;
 							}
 							else
@@ -72,5 +72,5 @@
 						if (mPan)
 						{
-							yshift	=	yshift	-	(y - mMouseY);
+							yshift	=	yshift	-	0.01;
 						}
 						else
@@ -85,5 +85,5 @@
 							if (mPan)
 							{
-								yshift	=	yshift	+	(mMouseY	-	y);
+								yshift	=	yshift	+	0.01;
 							}
 							else
@@ -884,4 +884,5 @@
 			geosubmesh->mIndexCount,
 			GL_UNSIGNED_INT,
+
 			mIndexArray[submesh]);
 
@@ -1146,6 +1147,4 @@
 	glLoadIdentity();
 
-	glEnable(GL_LIGHTING);
-
 	//	Frustrum.
 	glViewport(0,0,w(),h());
@@ -1213,11 +1212,15 @@
 	{
 		enableColorStrips();
-		//glDisable(GL_LIGHTING);
 		glPolygonMode (GL_FRONT_AND_BACK, GL_FILL);
 		drawGeoMesh(false);
 	}
+
+	if (mLighting)
+	{
+		glEnable(GL_LIGHTING);
+	}
 	else
 	{
-		glEnable(GL_LIGHTING);
+		glDisable(GL_LIGHTING);
 	}
 
@@ -1225,6 +1228,4 @@
 	{
 		disableColorStrips();
-
-		//glDisable(GL_LIGHTING);
 
 		GLfloat color[4];
@@ -1257,5 +1258,4 @@
 		{
 			disableColorStrips();
-			//glEnable(GL_LIGHTING);
 			glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
 			drawGeoMesh(false);
@@ -1279,8 +1279,8 @@
 	current_texture = ilutGLLoadImage((const ILstring)imgfile);
 
-	if (!current_texture)
-	{
-		fltk::alert("Error loading texture!");
-	}
+//	if (!current_texture)
+//	{
+//		fltk::alert("Error loading texture!");
+//	}
 
 	ilShutDown();
@@ -1295,8 +1295,8 @@
 	current_texture_submesh[isubmesh] = ilutGLLoadImage((const ILstring)imgfile);
 
-	if (!current_texture_submesh[isubmesh])
-	{
-		fltk::alert("Error loading texture!");
-	}
+//	if (!current_texture_submesh[isubmesh])
+//	{
+//		fltk::alert("Error loading texture!");
+//	}
 
 	ilShutDown();
