summaryrefslogtreecommitdiff
path: root/2005/i/robert/src/ovision/ui/live.hh
diff options
context:
space:
mode:
Diffstat (limited to '2005/i/robert/src/ovision/ui/live.hh')
-rw-r--r--2005/i/robert/src/ovision/ui/live.hh81
1 files changed, 81 insertions, 0 deletions
diff --git a/2005/i/robert/src/ovision/ui/live.hh b/2005/i/robert/src/ovision/ui/live.hh
new file mode 100644
index 0000000..7c5301e
--- /dev/null
+++ b/2005/i/robert/src/ovision/ui/live.hh
@@ -0,0 +1,81 @@
+// robert - programme du robot 2005
+//
+// Copyright (C) 2005 Olivier Gaillard
+//
+// Robot APB Team/Efrei 2005.
+// Web: http://assos.efrei.fr/robot/
+// Email: robot AT efrei DOT fr
+//
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation; either version 2 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+#ifndef live_h
+#define live_h
+
+#include "adjust.hh"
+#include "ovision/see/convertImg.hh"
+#include "ovision/see/imgInterface.hh"
+#include "ovision/see/segmLearn.hh"
+#include "ovision/see/oconfig.hh"
+#include "ovision/see/group.hh"
+#include "ovision/see/magnifier.hh"
+
+#define NB_POINTS_UI 6
+
+/// Traitement de l'image dans le but d'être visualisé sur une interface
+class Live
+{
+ unsigned nbImg_;
+ ImageReader *reader_;
+ public:
+ enum ImageInput {file, cam, serv};
+ /// Constructeur
+ Live (const unsigned nbImg, const ImageInput imgInput = file);
+ /// Destructeur
+ ~Live (void);
+
+ /// tableau des numeros de textures utilises par openGL
+ unsigned *tex;
+ /// tableau de donnees RGB stockant les images
+ unsigned char **data;
+ /// classe image
+ ImgInterface *img;
+ /// classe config
+ OConfig *oconfig;
+ /// classe segmentation
+ SegmLearn *segm;
+ /// classe group
+ Group *group;
+ /// classe magnifier
+ Magnifier *mag;
+ /// nom de l'image courante
+ char fname[100];
+
+ /// Initialisation
+ void init (const char *filename);
+ /// Recharge le fichier de config
+ void reloadConfig (const char *filename);
+ /// Segmentation et groupement des couleurs
+ void segmAndGroup(int numColorToShow = -1);
+ /// Fixe une image ségmentée et une image de groupe dans la partie centrale
+ void rootPics ();
+ /// Mis à jour de l'image
+ void updateImg (const char *filename);
+
+ private:
+ ImageInput imgInput_;
+};
+
+
+#endif // live_h