mreggrow.c

00001 /*
00002 *    Copyright (c) 2007. The BATI team. All right reserved.
00003 *
00004 *    This file is part of BATI library.
00005 *
00006 *    BATI library is free software: you can redistribute it and/or modify
00007 *    it under the terms of the GNU General Public License as published by
00008 *    the Free Software Foundation, either version 3 of the License, or
00009 *    (at your option) any later version.
00010 *
00011 *    BATI library  is distributed in the hope that it will be useful,
00012 *    but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014 *    GNU General Public License for more details.
00015 *
00016 *    You should have received a copy of the GNU General Public License
00017 *    along with BATI library.  If not, see <http://www.gnu.org/licenses/>.
00018 */
00028 #include "image.h"
00029 #include "proto2D.h"
00030 #include "reggrow.h"
00031 
00032 int main(int argc, char *argv[]){
00033   /* images */ 
00034   imau1 im0, imres; 
00035   int r;
00036   /* operateurs */
00037   read_ima_t  rea;
00038   reggrow_t regparam;
00039   write_ima_t wri;
00040  /* main : variables et parametres propres au main*/
00041   param par0, *ptp;      /* tete et pointeur pour la chaine de parametres */
00042  
00043 
00044 /* LECTURE PARAMETRES */
00045   param_debut(argc, argv, &par0); 
00046   ptp = &par0;
00047   ptp = reggrow_lect(&regparam, ptp, ">>region growing question :");
00048   ptp = read_ima_lect(&rea, ptp, ">> image initiale 1 (u1) :");
00049   ptp = write_ima_lect(&wri, ptp, ">> image resultat 1 (u1) :");
00050 
00051   param_fin(argc, argv, &par0);
00052 
00053 /* INITIALISATION  */
00054   read_imau1_init(&rea, &im0);
00055   reggrow_init(&regparam, &im0, &imres);
00056   write_ima_init(&wri);
00057 
00058 /* CALCUL */
00059   reggrow_calc(&regparam, &im0, &imres);
00060   
00061 /* FERMETURE */
00062   write_imau1_ferm(&wri, imres);
00063   return(0);
00064 }
00065 
00066 
00067 

Generated on Tue Apr 22 13:31:04 2008 for ima2D by  doxygen 1.5.3