Index: trunk/Ladybug/LadybugComponent.cpp
===================================================================
--- trunk/Ladybug/LadybugComponent.cpp	(revision 98)
+++ trunk/Ladybug/LadybugComponent.cpp	(revision 99)
@@ -32,5 +32,4 @@
 // Construct the factory
 static ComponentFactory<LadybugComponent> sFactory("LadybugComponent");
-static const size_t kMaxFilepathLength = 128;
 
 /* *Constructor*/
@@ -57,67 +56,4 @@
 	lbTotalNumberOfImagesWritten = 0;
 	lbNumOfFrames = 0;
-
-	if (lbSaveJPGImages)
-	{
-		try 
-		{
-			QString dbtFileName_ = "Camera_1.dbt";
-			mDbtImage1.open(dbtFileName_.toStdString(), WriteMode, FILE_DBT_UNKNOWN, kMaxFilepathLength);
-		} catch (DbiteException & e) {
-			LOG_ERROR("error opening dbt file: " << e.what());
-		}
-
-		try 
-		{
-			QString dbtFileName_ = "Camera_2.dbt";
-			mDbtImage1.open(dbtFileName_.toStdString(), WriteMode, FILE_DBT_UNKNOWN, kMaxFilepathLength);
-		} catch (DbiteException & e) {
-			LOG_ERROR("error opening dbt file: " << e.what());
-		}
-
-		try 
-		{
-			QString dbtFileName_ = "Camera_3.dbt";
-			mDbtImage1.open(dbtFileName_.toStdString(), WriteMode, FILE_DBT_UNKNOWN, kMaxFilepathLength);
-		} catch (DbiteException & e) {
-			LOG_ERROR("error opening dbt file: " << e.what());
-		}
-
-		try 
-		{
-			QString dbtFileName_ = "Camera_4.dbt";
-			mDbtImage1.open(dbtFileName_.toStdString(), WriteMode, FILE_DBT_UNKNOWN, kMaxFilepathLength);
-		} catch (DbiteException & e) {
-			LOG_ERROR("error opening dbt file: " << e.what());
-		}
-
-		try 
-		{
-			QString dbtFileName_ = "Camera_5.dbt";
-			mDbtImage1.open(dbtFileName_.toStdString(), WriteMode, FILE_DBT_UNKNOWN, kMaxFilepathLength);
-		} catch (DbiteException & e) {
-			LOG_ERROR("error opening dbt file: " << e.what());
-		}
-
-		try 
-		{
-			QString dbtFileName_ = "Camera_6.dbt";
-			mDbtImage1.open(dbtFileName_.toStdString(), WriteMode, FILE_DBT_UNKNOWN, kMaxFilepathLength);
-		} catch (DbiteException & e) {
-			LOG_ERROR("error opening dbt file: " << e.what());
-		}
-    }
-
-	if (lbSavePanoImage)
-	{
-		try 
-		{
-			QString dbtFileName_ = "CameraPano.dbt";
-			mDbtImage1.open(dbtFileName_.toStdString(), WriteMode, FILE_DBT_UNKNOWN, kMaxFilepathLength);
-		} catch (DbiteException & e) {
-			LOG_ERROR("error opening dbt file: " << e.what());
-		}
-    }
-
 	THREAD_ALIVE = true;
 	start();
@@ -130,18 +66,4 @@
 	printf (" \n*** Stopping Activity ***\n");
 	LadybugError error;
-
-	    // Close DBT files
-    if (lbSaveJPGImages) {
-		mDbtImage1.close();
-		mDbtImage2.close();
-		mDbtImage3.close();
-		mDbtImage4.close();
-		mDbtImage5.close();
-		mDbtImage6.close();
-    }
-
-	if (lbSavePanoImage) {
-		mDbtImagePano.close();
-	}
 
 	lbIsRecording = false;
@@ -222,11 +144,6 @@
 	CreateImageBuffers();
 
-	// Timestamp
-    road_time_t timestamp = 0;
-    road_timerange_t tr = 0;
-
 	while (THREAD_ALIVE)
 	{
-
 		lbCurrentTime = GetTickCount(); // road_time_t timestamp = road_time(); // ui64 ; unit microsec ; Orig 01/01/1970 00:00
 		lbFrameCount++;
@@ -241,5 +158,5 @@
 
 		error = ladybugGrabImage( lbContext, &image );
-		timestamp = road_time(); // timestamp 
+		// t = road_time(); // timestamp 
 		HandleError(error);
 
@@ -328,6 +245,4 @@
 	HandleError(error);
 
-
-	// Use it to trigger the camera with the gps signal
 	/*// Initialize Trigger
 	error = ladybugGetTriggerModeInfo( lbContext, &triggerModeInfo );
@@ -441,43 +356,4 @@
 		HandleError(error);
 
-        if (uiCamera == 0)
-		{
-			try {
-				mDbtImage1.writeRecord(time, tr, (char *) processedImage.pData, kMaxFilepathLength);
-			} catch (DbiteException & e) {
-				LOG_ERROR("error writing data: " << e.what());
-			}
-		} else if (uiCamera == 1) {
-			try {
-				mDbtImage2.writeRecord(time, tr, (char *) processedImage.pData, kMaxFilepathLength);
-			} catch (DbiteException & e) {
-				LOG_ERROR("error writing data: " << e.what());
-			}
-		}else if (uiCamera == 2) {
-			try {
-				mDbtImage3.writeRecord(time, tr, (char *) processedImage.pData, kMaxFilepathLength);
-			} catch (DbiteException & e) {
-				LOG_ERROR("error writing data: " << e.what());
-			}
-		}else if (uiCamera == 3) {
-			try {
-				mDbtImage4.writeRecord(time, tr, (char *) processedImage.pData, kMaxFilepathLength);
-			} catch (DbiteException & e) {
-				LOG_ERROR("error writing data: " << e.what());
-			}
-		}else if (uiCamera == 4) {
-			try {
-				mDbtImage5.writeRecord(time, tr, (char *) processedImage.pData, kMaxFilepathLength);
-			} catch (DbiteException & e) {
-				LOG_ERROR("error writing data: " << e.what());
-			}
-		}else if (uiCamera == 5) {
-			try {
-				mDbtImage6.writeRecord(time, tr, (char *) processedImage.pData, kMaxFilepathLength);
-			} catch (DbiteException & e) {
-				LOG_ERROR("error writing data: " << e.what());
-			}
-		}
-
 		//printf("Saved camera %u image to %s.\n", uiCamera, pszOutputFilePath);
 
@@ -525,10 +401,4 @@
 	error = ladybugSaveImage(lbContext, &processedImage, pszOutputFilePath, LADYBUG_FILEFORMAT_JPG); 
 	HandleError(error);
-
-	try {
-		mDbtImagePano.writeRecord(time, tr, (char *) processedImage.pData, kMaxFilepathLength);
-	} catch (DbiteException & e) {
-		LOG_ERROR("error writing data: " << e.what());
-	}
 
 }
