ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/REPOS_ERICCA/magic/lib/diamesh/src/m3d_check.cpp
Revision: 272
Committed: Mon Dec 13 21:04:45 2010 UTC (14 years, 5 months ago) by francois
File size: 1338 byte(s)
Log Message:
suppression des warnings

File Contents

# User Rev Content
1 5 #include <stdio.h>
2     #include "m3d_struct.h"
3     #include "m3d_const.h"
4     #include "m3d_hotes.h"
5     #include "m3d_erreur.h"
6     #include "prototype.h"
7     extern int debug;
8     extern GEST_MEM *gest ;
9     int m3d_check(void)
10     {
11     TETRAEDRE *tetra ;
12     char mess[255];
13     int i, card ;
14     FACE *face ;
15     for (i=0;i<gest->nb_face;i++)
16     {
17     /* adresse de la face de numero i */
18     card = 0 ;
19     ADRESSE(face,i,face)
20     if (face->mark != DESTROYED)
21     {
22     if (face->hist == 0) /* face de la peau */
23     {
24     if (face->tetra1 != NULL)
25     if (face->tetra1->mark != KILLED) card ++ ;
26     if (face->tetra2 != NULL)
27     if (face->tetra2->mark != KILLED) card ++ ;
28     if (card != 1)
29     {
30     if (debug)
31     {
32 francois 272 sprintf(mess,"%s\n",(char*)"MAILLAGE NON CONFORME ") ;
33 5 //aff_text(mess);
34     }
35     m3d_erreur(ERR_SYST) ;
36     return(FAUX) ;
37     }
38     }
39     else
40     {
41     if (face->tetra1 != NULL)
42     if (face->tetra1->mark != KILLED) card ++ ;
43     if (face->tetra2 != NULL)
44     if (face->tetra2->mark != KILLED) card ++ ;
45     if (card != 2)
46     {
47     if (debug)
48     {
49 francois 272 sprintf(mess,"%s\n","MAILLAGE NON CONFORME ") ;
50 5 //aff_text(mess);
51     }
52     m3d_erreur(ERR_SYST) ;
53     return(FAUX) ;
54     }
55     }
56     }
57     }
58     return(VRAI) ;
59     }