#include "VTKDataProcessingWidget.h"
#include "ritkDebugManager.h"

#include <windows.h> 


VTKDataProcessingWidget::VTKDataProcessingWidget()
{
	setupUi(this);

	this->m_VisualizationWidget3D->update();
	this->m_VisualizationWidget3D->show();

	// Input selection
	connect(this->m_PushButtonLoadVTKData, SIGNAL(clicked()), this, SLOT(PushButtonLoadVTKDataClicked()));
	connect(this->m_PushButtonLoadRangeData, SIGNAL(clicked()), this, SLOT(PushButtonLoadRangeDataClicked()));
	connect(this->m_PushButtonSaveData, SIGNAL(clicked()), this, SLOT(PushButtonSaveDataClicked()));
	connect(this->m_PushButtonPerformSegmentation, SIGNAL(clicked()), this, SLOT(PushButtonPerformSegmentationClicked()));
	connect(this->m_PushButtonPerformTriangulation, SIGNAL(clicked()), this, SLOT(PushButtonPerformTriangulationClicked()));
	connect(this->m_PushButtonPerformDecimation, SIGNAL(clicked()), this, SLOT(PushButtonPerformDecimationClicked()));

	connect(this->m_PushButtonSaveRangeData, SIGNAL(clicked()), this, SLOT(PushButtonSaveRangeDataClicked()));
	connect(this->m_PushButtonSaveFlagData, SIGNAL(clicked()), this, SLOT(PushButtonSaveFlagDataClicked()));
}

VTKDataProcessingWidget::~VTKDataProcessingWidget()
{
}

void VTKDataProcessingWidget::UpdateGUI()
{	
	this->m_VisualizationWidget3D->UpdateGUI();
}

//----------------------------------------------------------------------------
void 
VTKDataProcessingWidget::PushButtonLoadVTKDataClicked()
{
	emit PushButtonLoadVTKData();
}

//----------------------------------------------------------------------------
void 
VTKDataProcessingWidget::PushButtonLoadRangeDataClicked()
{
	emit PushButtonLoadRangeData();
}


//----------------------------------------------------------------------------
void 
VTKDataProcessingWidget::PushButtonSaveDataClicked()
{
	emit PushButtonSaveData();
}

//----------------------------------------------------------------------------
void 
VTKDataProcessingWidget::PushButtonPerformSegmentationClicked()
{
	emit PushButtonPerformSegmentation();
}

//----------------------------------------------------------------------------
void 
VTKDataProcessingWidget::PushButtonPerformTriangulationClicked()
{
	emit PushButtonPerformTriangulation();
}
//----------------------------------------------------------------------------
void 
VTKDataProcessingWidget::PushButtonPerformDecimationClicked()
{
	emit PushButtonPerformDecimation();
}

//----------------------------------------------------------------------------
void 
VTKDataProcessingWidget::PushButtonSaveRangeDataClicked()
{
	emit PushButtonSaveRangeData();
}

//----------------------------------------------------------------------------
void 
VTKDataProcessingWidget::PushButtonSaveFlagDataClicked()
{
	emit PushButtonSaveFlagData();
}

