00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00033 #include "volume.h"
00034 #include "proto2D.h"
00035 #include "essai.h"
00036 #include <stdlib.h>
00037 #include <string.h>
00038
00039
00040 int main(int argc, char *argv[]){
00041
00042 param par0, *ptp;
00043 int iloc;
00044 float floc;
00045 char nomlocIn[200], nomlocOut[200];
00046
00047 ima3Du1 imaOri, imaRes;
00048 essai_t bid;
00049
00050
00051
00052 param_debut(argc, argv, &par0);
00053 ptp = &par0;
00054
00055 lec_param(">>main, fichier volume a lire", ptp);
00056 strcpy(nomlocIn, ptp->rep);
00057 ptp = ptp->next;
00058
00059 ptp = essai_lect(&bid, ptp, ">> essai_lect, debut de question :");
00060
00061 lec_param(">>main, entier iloc", ptp);
00062 iloc = atoi(ptp->rep);
00063 ptp = ptp->next;
00064
00065 lec_param(">>main, float floc", ptp);
00066 floc = (float)atof(ptp->rep);
00067 ptp = ptp->next;
00068
00069 lec_param(">>main, fichier volume a ecrire", ptp);
00070 strcpy(nomlocOut, ptp->rep);
00071 ptp = ptp->next;
00072
00073 param_fin(argc, argv, &par0);
00074
00075
00076
00077
00078 lect_volume_u1( nomlocIn, &imaOri);
00079 essaiu1_init(&bid, imaOri, &imaRes);
00080
00081
00082
00083 essaiu1_calc(&bid, imaOri, &imaRes);
00084 printf("\n partie calcul, iloc=%d, floc=%f, nomlocIn=%s, nomlocOut=%s\n",
00085 iloc, floc, nomlocIn, nomlocOut);
00086
00087
00088
00089 write_volume_u1( nomlocOut, &imaRes) ;
00090 }
00091