00001 //###################################################################### 00002 // 00003 // GraspIt! 00004 // Copyright (C) 2002-2009 Columbia University in the City of New York. 00005 // All rights reserved. 00006 // 00007 // GraspIt! is free software: you can redistribute it and/or modify 00008 // it under the terms of the GNU General Public License as published by 00009 // the Free Software Foundation, either version 3 of the License, or 00010 // (at your option) any later version. 00011 // 00012 // GraspIt! is distributed in the hope that it will be useful, 00013 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00014 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00015 // GNU General Public License for more details. 00016 // 00017 // You should have received a copy of the GNU General Public License 00018 // along with GraspIt!. If not, see <http://www.gnu.org/licenses/>. 00019 // 00020 // Author(s): Andrew T. Miller and Matei T. Ciocarlie 00021 // 00022 // $Id: barrettHandDlg.h,v 1.3 2009/04/21 14:53:08 cmatei Exp $ 00023 // 00024 //###################################################################### 00025 00026 #ifndef _barretthanddlg_h_ 00027 #define _barretthanddlg_h_ 00028 00029 #include "ui_barrettHandDlg.h" 00030 00031 #include <QDialog> 00032 00033 class Barrett; 00034 class BarrettHandThread; 00035 class BarrettHand; 00036 class World; 00037 class Robot; 00038 00040 00046 class BarrettHandDlg : public QDialog, public Ui::BarrettHandDlgUI 00047 { 00048 Q_OBJECT 00049 private: 00051 bool userInteractionOngoing; 00053 bool withinSimulationUpdate; 00054 00055 Robot *simulatedHandForContinuousOperation; 00057 BarrettHand *mRealBarrett; 00059 BarrettHandThread *mBHT; 00061 Barrett *mSimBarrett; 00063 World *world; 00064 00066 void init(); 00068 void userInteractionStart(); 00070 void userInteractionEnd(); 00071 00072 public: 00074 BarrettHandDlg(QWidget *parent = 0) : QDialog(parent) { 00075 setupUi(this); 00076 init(); 00077 } 00078 00080 bool setWorld( World *w ); 00081 00082 public slots: 00084 void initializeHand(); 00086 void simulationFromRealHand(); 00088 void realHandFromSimulation(); 00090 void toggleContinuousOperation(); 00092 void smoothButton_clicked(); 00094 void initSpreadButton_clicked(); 00095 }; 00096 00097 #endif