ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/REPOS_ERICCA/acismesh/struct.h
Revision: 1
Committed: Mon Jun 11 22:53:07 2007 UTC (17 years, 11 months ago)
Content type: text/plain
File size: 12473 byte(s)
Log Message:

File Contents

# User Rev Content
1 1 /*****************************************************************
2    
3     struct.h Type:Inc
4    
5     Structure
6    
7     Date de creation : Mon Nov 25 13:26:40 1996
8    
9     Derniere version : Tue Aug 5 13:50:09 1997
10    
11    
12    
13    
14    
15    
16     Vincent FRANCOIS
17    
18     *****************************************************************/
19    
20     /* structure ACIS */
21    
22    
23     typedef char *ligne, **text;
24    
25    
26     struct s_acis
27     {
28     void **entity;
29     text type_entite;
30     struct s_attrib **attrib;
31     struct s_body **body;
32     struct s_lump **lump;
33     struct s_shell **shell;
34     struct s_face **face;
35     struct s_loop **loop;
36     struct s_subshell **subshell;
37     struct s_wire **wire;
38     struct s_coedge **coedge;
39     struct s_edge **edge;
40     struct s_vertex **vertex;
41     struct s_cone **cone;
42     struct s_ellipse **ellipse;
43     struct s_pcurve **pcurve;
44     struct s_plane **plane;
45     struct s_point **point;
46     struct s_straight **straight;
47     struct s_transform **transform;
48     int nb_entity;
49     int nb_attrib;
50     int nb_body;
51     int nb_lump;
52     int nb_shell;
53     int nb_face;
54     int nb_loop;
55     int nb_subshell;
56     int nb_wire;
57     int nb_coedge;
58     int nb_edge;
59     int nb_vertex;
60     int nb_cone;
61     int nb_ellipse;
62     int nb_pcurve;
63     int nb_plane;
64     int nb_point;
65     int nb_straight;
66     int nb_transform;
67     };
68    
69    
70     struct s_attrib /* laisse tomber */
71     {
72     int num;
73     };
74    
75    
76     struct s_body
77     {
78     struct s_attrib *attrib;
79     struct s_lump *first_lump;
80     struct s_wire *first_wire;
81     struct s_transform *transform;
82     int num;
83     };
84    
85    
86     struct s_lump
87     {
88     struct s_attrib *attrib;
89     struct s_lump *next_lump;
90     struct s_shell *first_shell;
91     struct s_body *body;
92     int num;
93     };
94    
95     struct s_shell
96     {
97     struct s_attrib *attrib;
98     struct s_shell *next_shell;
99     struct s_subshell *first_subshell;
100     struct s_face *first_face;
101     struct s_lump *owning_lump;
102     int num;
103     };
104    
105     struct s_face
106     {
107     struct s_attrib *attrib;
108     struct s_face *next_face;
109     struct s_loop *first_loop;
110     struct s_shell *owning_shell;
111     struct s_subshell *owning_subshell;
112     int surface;
113     int sense;
114     int simple;
115     int ext;
116     int num_face;
117     /* rapport maillage */
118     struct s_triangle **triangle;
119     int nb_triangle;
120     int num;
121     /* limite des parametres */
122     float uinf;
123     float usup;
124     float vinf;
125     float vsup;
126     float rev_u;
127     float rev_v;
128     /* rapport face face*/
129     int *rap_face;
130     };
131    
132     struct s_loop
133     {
134     struct s_attrib *attrib;
135     struct s_loop *next_loop;
136     struct s_coedge *first_coedge;
137     struct s_face *owning_face;
138     int num;
139     };
140    
141     struct s_subshell
142     {
143     struct s_attrib *attrib;
144     struct s_subshell *parent_subshell;
145     struct s_subshell *next_subshell;
146     struct s_subshell *first_subshell;
147     struct s_face *first_face;
148     struct s_wire *first_wire;
149     int num;
150     };
151    
152     struct s_wire
153     {
154     struct s_attrib *attrib;
155     struct s_wire *next_wire;
156     struct s_coedge *first_coedge;
157     void *owning;
158     int num;
159     };
160    
161     struct s_coedge
162     {
163     struct s_attrib *attrib;
164     struct s_coedge *next_coedge;
165     struct s_coedge *previous_coedge;
166     struct s_coedge *partner_coedge;
167     struct s_edge *edge;
168     int sense;
169     struct s_loop *owning_loop;
170     struct s_pcurve *pcurve;
171     int num;
172     };
173    
174     struct s_edge
175     {
176     struct s_attrib *attrib;
177     struct s_vertex *start_vertex;
178     struct s_vertex *end_vertex;
179     struct s_coedge *owning_coedge;
180     int curve;
181     int sense;
182     int num;
183     int num_edge;
184     /* paramatre de la parametrisation */
185     float t1,t2;
186     /* rapport maillage */
187     struct s_segment **segment;
188     int nb_segment;
189     /* interpolation influence densite */
190     float *dens_influ;
191     int nb_dens;
192     /* rapport courbe courbe */
193     int *rap_edge;
194     };
195    
196     struct s_vertex
197     {
198     struct s_attrib *attrib;
199     struct s_edge *owning_edge;
200     struct s_point *point;
201     int num;
202     /* aide au remaillage */
203     struct s_edge **edge;
204     int nb_edge;
205     /* rapport maillage */
206     struct s_noeud *noeud;
207     };
208    
209     struct s_cone
210     {
211     struct s_attrib *attrib;
212     float center[3];
213     float normal[3];
214     float major[3];
215     float ratio;
216     float cosalph;
217     float sinalph;
218     int u_rev;
219     int num;
220     /* acces a la parametrisation */
221     struct s_par_cone *param;
222     };
223    
224     struct s_ellipse
225     {
226     struct s_attrib *attrib;
227     float center[3];
228     float normal[3];
229     float major[3];
230     float ratio;
231     int num;
232     /* acces a la parametrisation */
233     struct s_par_ellipse *param;
234     };
235    
236     struct s_pcurve /* laisse tomber */
237     {
238     int num;
239     };
240    
241     struct s_plane
242     {
243     struct s_attrib *attrib;
244     float root[3];
245     float normal[3];
246     float u_deriv[3];
247     int v_rev;
248     int num;
249     /* acces a la parametrisation */
250     struct s_par_plane *param;
251     };
252    
253     struct s_point
254     {
255     struct s_attrib *attrib;
256     float coord[3];
257     int num;
258     };
259    
260     struct s_straight
261     {
262     struct s_attrib *attrib;
263     float root[3];
264     float dir[3];
265     int num;
266     /* acces a la parametrisation */
267     struct s_par_straight *param;
268     };
269    
270     struct s_transform
271     {
272     struct s_attrib *attrib;
273     float rotation[3][3];
274     float trans[3];
275     float scaling_factor;
276     int rotate;
277     int reflection;
278     int shear;
279     int num;
280     };
281    
282     /* structure de construction de maillage */
283    
284     struct s_noeud
285     {
286     float x;
287     float y;
288     float z;
289     float u;
290     float v;
291     float dens;
292     int num;
293     int creation;
294     char type;
295     int num_ent;
296     struct s_tetra **tetra;
297     int nb_tetra;
298     struct s_triangle **triangle;
299     struct s_triangle *tete_tri_petit;
300     struct s_triangle *queue_tri_petit;
301     struct s_tetra *tete_tet_petit;
302     struct s_tetra *queue_tet_petit;
303     int nb_triangle;
304     struct s_segment **segment;
305     int nb_segment;
306     float pos;
307     int indice;
308     int an_num;
309     int etat;
310     int renum;
311     };
312    
313    
314     struct s_segment
315     {
316     int n1;
317     int n2;
318     float longueur;
319     char type;
320     int num_ent;
321     int front;
322     int num;
323     };
324    
325    
326    
327    
328     struct s_triangle
329     {
330     int n1;
331     int n2;
332     int n3;
333     int num;
334     float crit;
335     int num_ent;
336     char type;
337     int front;
338     struct s_tetra *tetra[2];
339     struct s_segment *segment[3];
340     struct s_triangle *suivant;
341     struct s_triangle *precedent;
342     struct s_facette *facette;
343     struct s_front3d *ft;
344     int opt;
345     int origine;
346     int creation;
347     struct s_triangle *suiv;
348     };
349    
350    
351    
352     struct s_tetra
353     {
354     int n1;
355     int n2;
356     int n3;
357     int n4;
358     int num;
359     float crit;
360     float vol;
361     int num_ent;
362     int type;
363     int opt;
364     int etat;
365     char front[10];
366     struct s_triangle *triangle[4];
367     struct s_tetra *suivant;
368     struct s_tetra *precedent;
369     struct s_tetra *suiv;
370     };
371    
372    
373    
374     struct s_frontiere
375     {
376     struct s_noeud *no1;
377     struct s_noeud *no2;
378     struct s_segment *seg;
379     int num;
380     };
381    
382     struct s_front
383     {
384     int n1;
385     int n2;
386     struct s_segment *seg;
387     struct s_front *suiv;
388     struct s_front *prec;
389     struct s_front *suivant;
390     struct s_front *precedent;
391     int etat;
392     int num;
393     };
394    
395     struct s_frontiere3d
396     {
397     struct s_noeud *no1;
398     struct s_noeud *no2;
399     struct s_noeud *no3;
400     struct s_triangle *tri ;
401     int num;
402     };
403    
404    
405     struct s_voisin
406     {
407     struct s_front3d *ft;
408     float angle;
409     };
410    
411    
412     struct s_front3d
413     {
414     int n1;
415     int n2;
416     int n3;
417     float longueur;
418     struct s_triangle *tri;
419     struct s_front3d *suivant;
420     struct s_front3d *precedent;
421     struct s_voisin voisin[3];
422     int etat;
423     int num;
424     int type;
425     };
426    
427    
428     struct s_quadtree
429     {
430     float u,v,t_u,t_v;
431     struct s_noeud **noeud;
432     struct s_segment **segment;
433     struct s_triangle **triangle;
434     struct s_frontiere **frontiere;
435     struct s_front **front;
436     int nb_front;
437     int nb_noeud;
438     int nb_segment;
439     int nb_frontiere;
440     int nb_triangle;
441     struct s_quadtree *fils[4];
442     int feuille;
443     int num;
444     };
445    
446    
447     struct s_octree
448     {
449     float x,y,z,taille;
450     struct s_noeud **noeud;
451     struct s_segment **segment;
452     struct s_triangle **triangle;
453     struct s_tetra **tetra;
454     struct s_vertex **vertex;
455     struct s_edge **edge;
456     struct s_face **face;
457     struct s_mnoeud **mnoeud;
458     struct s_msegment **msegment;
459     struct s_mtriangle **mtriangle;
460     struct s_mtetra **mtetra;
461     struct s_frontiere3d **frontiere3d;
462     struct s_front3d **front3d;
463     int nb_front3d;
464     int nb_frontiere3d;
465     int nb_face;
466     int nb_edge;
467     int nb_vertex;
468     int nb_noeud;
469     int nb_segment;
470     int nb_triangle;
471     int nb_tetra;
472     int nb_mnoeud;
473     int nb_msegment;
474     int nb_mtriangle;
475     int nb_mtetra;
476     struct s_octree *fils[8];
477     int feuille;
478     int num;
479     float dens;
480     };
481    
482     struct s_facette
483     {
484     int num;
485     int nb_triangle;
486     struct s_triangle **triangle;
487     int etat;
488     };
489    
490     struct s_zone
491     {
492     int type;
493     int reference;
494     struct s_octree *oct;
495     float dens;
496     int type_entite;
497     int num;
498     int nb_entite;
499     int entite[2];
500     };
501    
502     struct s_mesh
503     {
504     struct s_noeud **noeud;
505     struct s_segment **segment;
506     struct s_triangle **triangle;
507     struct s_triangle *tete_triangle,*tete_triangle2;
508     struct s_facette **facette;
509     struct s_frontiere **frontiere;
510     struct s_frontiere3d **frontiere3d;
511     struct s_front **front;
512     struct s_front3d **front3d;
513     struct s_quadtree **quadtree;
514     struct s_quadtree *root;
515     struct s_octree **octree;
516     struct s_octree *first;
517     struct s_front *tete_front;
518     struct s_front *vide_front;
519     struct s_front3d *tete_front3d[12];
520     struct s_front3d *queue_front3d[12];
521     struct s_tetra *tete_tetra[10];
522     struct s_tetra *queue_tetra[10];
523     struct s_front3d *vide_front3d;
524     struct s_tetra **tetra;
525     struct s_zone **zone;
526     int nb_zone;
527     int nb_tetra;
528     int nb_quadtree;
529     int nb_octree;
530     int nb_triangle;
531     int nb_noeud;
532     int nb_segment;
533     int nb_frontiere;
534     int nb_frontiere3d;
535     int nb_facette;
536     int nb_facette_attache;
537     int nb_bodyette_attache;
538     int nb_front;
539     int nb_front3d;
540     int nb_front_tot;
541     int nb_front3d_tot;
542     int nb_feuille;
543     float rev_u;
544     float rev_v;
545     float critmin;
546     float critmax;
547     float critmoy;
548     int tabcrit[4];
549     int theorique;
550     int nb_noeud_traite;
551     };
552    
553    
554     /* structure de maillage */
555    
556     struct s_mnoeud
557     {
558     float x;
559     float y;
560     float z;
561     float u;
562     float v;
563     float dens;
564     int num;
565     char type;
566     int num_ent;
567     int etat;
568     int nv_num;
569     struct s_mtriangle **mtriangle;
570     int nb_mtriangle;
571     struct s_mtetra **mtetra;
572     int nb_mtetra;
573     };
574    
575    
576     struct s_msegment
577     {
578     int n1;
579     int n2;
580     int num;
581     char type;
582     int num_ent;
583     int etat;
584     };
585    
586    
587    
588    
589     struct s_mtriangle
590     {
591     int n1;
592     int n2;
593     int n3;
594     int num;
595     int num_ent;
596     int type;
597     int etat;
598     struct s_mfacette *mfacette;
599     };
600    
601    
602     struct s_mbodyette
603     {
604     int num;
605     int nb_mtetra;
606     struct s_mtetra **mtetra;
607     int etat;
608     };
609    
610     struct s_mfacette
611     {
612     int num;
613     int nb_mtriangle;
614     struct s_mtriangle **mtriangle;
615     int etat;
616     };
617    
618     struct s_mtetra
619     {
620     int n1;
621     int n2;
622     int n3;
623     int n4;
624     int num;
625     int etat;
626     struct s_mbodyette *mbodyette;
627     };
628    
629    
630    
631    
632     struct s_maillage
633     {
634     struct s_mnoeud **mnoeud;
635     struct s_msegment **msegment;
636     struct s_mtriangle **mtriangle;
637     struct s_mfacette **mfacette;
638     struct s_mbodyette **mbodyette;
639     struct s_mtetra **mtetra;
640     int nb_mbodyette;
641     int nb_mtetra;
642     int nb_mfacette;
643     int nb_mtriangle;
644     int nb_mnoeud;
645     int nb_msegment;
646     };
647    
648     /* structure de parametrisation */
649    
650     struct s_par_ellipse
651     {
652     float a,b;
653     float u[3],v[3],w[3];
654     float centre[3];
655     };
656    
657    
658    
659     struct s_par_straight
660     {
661     float root[3],dir[3];
662     };
663    
664     struct s_par_cone
665     {
666     float a,b,tg;
667     float u[3],v[3],w[3];
668     float centre[3];
669     };
670    
671    
672    
673     struct s_par_plane
674     {
675     float root[3],dir1[3],dir2[3];
676     };
677    
678    
679     struct s_param
680     {
681     struct s_par_ellipse **par_ellipse;
682     struct s_par_straight **par_straight;
683     struct s_par_plane **par_plane;
684     struct s_par_cone **par_cone;
685     int nb_par_plane;
686     int nb_par_cone;
687     int nb_par_ellipse;
688     int nb_par_straight;
689     };
690    
691    
692     /* autre structure */
693     struct environnement
694     {
695     char fich[255];
696     char fich2[255];
697     float dens;
698     int version;
699     float epsilon;
700     int opti;
701     int opti2;
702     int analyse;
703     int remesh;
704     float zone;
705     double cpu;
706     int d3;
707     int relatif;
708     int geo;
709     float eps_ref;
710     float eps_ref1;
711     float eps_ref2;
712     };
713    
714     struct r_vertex
715     {
716     int gtrouve;
717     int num;
718     float x;
719     float y;
720     float z;
721     };
722    
723     struct r_edge
724     {
725     int type;
726     int nb_carac;
727     int gtrouve;
728     int num;
729     float carac[20];
730     int nint[6];
731     float x[12];
732     float y[12];
733     float z[12];
734     };
735    
736     struct r_face
737     {
738     int type;
739     int nb_carac;
740     float carac[20];
741     int gtrouve;
742     int num;
743     };
744    
745    
746    
747    
748    
749