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

File Contents

# User Rev Content
1 1 /*****************************************************************
2    
3     prototype.h Type:Inc
4    
5     fonctions prototypes
6    
7     Date de creation : Tue Apr 22 11:31:02 1997
8    
9     Derniere version : Fri Aug 1 10:24:21 1997
10    
11    
12    
13    
14    
15     Vincent FRANCOIS
16    
17     *****************************************************************/
18    
19    
20     /* portabilite */
21     void aff_text(char *mess);
22     void cal_cpu(void);
23     void voir(void);
24     void minimize(void);
25     void restore(void);
26    
27     /* fonction ACIS */
28     void acis_charge(void);
29    
30    
31     /* fonctions mathematiques */
32     float eval_cone(struct s_face *face,struct s_par_cone *param,float *u,float *v,int type,float *x,float *y,float *z,float du);
33     void eval_decale(float *ud,float du,float u,int flag);
34     void eval_dens_reel(struct s_mnoeud *mnoe);
35     float eval_distance(struct s_face *face,float u1,float v1,float u2,float v2,float du,float dv);
36     void eval_ellipse(struct s_par_ellipse *param,float t,int type,float *coord);
37     float eval_fdn1_eps(struct s_edge *edge,float t);
38     float eval_fdn1(struct s_edge *edge,float t);
39     void eval_normal(struct s_face *face,float *norm, float u,float v);
40     float eval_plane(struct s_face *face,struct s_par_plane *param,float *u,float *v,int type,float *x,float *y,float *z);
41     void eval_straight(struct s_par_straight *param,float t,int type,float *coord);
42     void eval_edge(struct s_edge *edge,float t,int type,float *coord);
43     float eval_face(struct s_face *face,float *u,float *v,int type,float *x,float *y,float *z,float du,float dv);
44     float eval_fdn2a(struct s_face *face,float u,float v);
45     float eval_fdn2_eps(struct s_face *face,float u,float v);
46     float eval_fdn2b(struct s_face *face,float u,float v,int type);
47     float eval_fdn3(float x,float y,float z);
48     void eval_vecteur(float *vec);
49     float eval_dis_point_face(struct s_face *face,float *x,float u,float v,int type);
50     float eval_dis_point_edge(struct s_edge *edge,float *x,float t,int type);
51     float eval_dis_edge_edge(struct s_edge *edge1,float t1,struct s_edge *edge2,float t2,int type);
52     float eval_dis_face_face(struct s_face *face1,float u1,float v1,struct s_face *face2,float u2,float v2,int type);
53     float eval_dis_no_tri(float x,float y,float z,struct s_triangle *tri);
54     void eval_mindis_face(struct s_face *face, float *x,float *dis, float *par);
55     void eval_mindis_edge(struct s_edge *edge, float *x,float *dis, float *par);
56     void eval_mindis_edge_edge(struct s_edge *edge1, struct s_edge *edge2,float *dis, float *par);
57     void eval_mindis_face_face(struct s_face *face1, struct s_face *face2,float *dis, float *par);
58    
59    
60     /* fonctions geometriques */
61     int geo_int_stra_plane(struct s_edge *edge,struct s_straight *straight,float x1,float y1,float z1,float x2,float y2,float z2,float x3,float y3,float z3,float *x,float *y,float *z);
62     int geo_int_elli_plane(struct s_edge *edge,struct s_ellipse *ellipse,float x1,float y1,float z1,float x2,float y2,float z2,float x3,float y3,float z3,float *x,float *y ,float *z);
63     int geo_point_interieur(float u,float v);
64     int geo_app_point_face(struct s_face *face,struct s_mnoeud *mno);
65     float geo_ind_point_edge(struct s_edge *edge,struct s_noeud *no);
66     int geo_app_point_body(float x,float y,float z);
67    
68    
69    
70    
71    
72    
73     /* fonctions de maillage en 0D */
74     void m0d(void);
75    
76     /* fonctions de maillage en 1D */
77     void m1d(void);
78     void m1d_dis(void);
79     void m1d_enreg(void);
80     void m1d_geo(void);
81     void m1d_lissage(int segment1,int segment2);
82     void m1d_param_ellipse(struct s_edge *edge,struct s_ellipse *ellipse);
83     void m1d_param_straight(struct s_edge *edge,struct s_straight *straight);
84    
85     /* fonctions de maillage en 2D */
86     void m2d(void);
87     void m2d_ana_dens(struct s_face *face,int debut, int fin);
88     void m2d_ac_front(struct s_front **ele,int operation);
89     void m2d_c_quad(struct s_face *face,float rev_u,float rev_v);
90     float m2d_cal_qual(int n1,int n2,int n3);
91     void m2d_d_segment(struct s_segment **seg);
92     void m2d_enreg(void);
93     int m2d_ex_sol(float sol1,float sol2,int ntype_sol);
94     void m2d_fin(void);
95     void m2d_frontiere(struct s_face *face);
96     int m2d_gen_noe(struct s_face *face,struct s_front *ele,struct s_front **ele2,int *numo);
97     void m2d_gest_front(struct s_face *face);
98     int m2d_i_segment(struct s_face *face,struct s_segment **nv_seg,int n1,int n2,int type);
99     void m2d_i_triangle(struct s_face *face,int n1,int n2,int n3,int origine);
100     void m2d_ini_front(struct s_face *face);
101     int m2d_int_seg_seg(int a,int b,int m,int n);
102     int m2d_int_triangle(int n1,int n2,int n3,int n);
103     void m2d_resultat(int num);
104     void m2d_ord_front(struct s_front *ele);
105     void m2d_param_plane(struct s_face *face,struct s_plane *plane);
106     void m2d_param_cone(struct s_face *face,struct s_cone *cone);
107    
108     /* fonctions de maillage en 3D */
109     void m3d(void);
110     void m3d_analyse(void);
111     void m3d_ac_front(struct s_front3d **ele,int operation);
112     float m3d_angle_front2(struct s_front3d *ft,struct s_segment *seg);
113     float m3d_angle_front(struct s_front3d *ft1, struct s_front3d *ft2);
114     void m3d_c_octree(void);
115     float m3d_cal_qual(int n1,int n2,int n3,int n4);
116     float m3d_cal_vol(int n1,int n2,int n3,int n4);
117     int m3d_d_tetra(struct s_front3d *ft,struct s_tetra *tetra);
118     void m3d_enreg(int type);
119     void m3d_enreg2(void);
120     void m3d_fin(void);
121     void m3d_frontiere(void);
122     void m3d_ini_front(void);
123     void m3d_insere_cas(int type,int num_no,int numero,float angle,int *nb_cas,struct cas_front *cas);
124     int m3d_int_faces(int n1, int n2, int n3, int n4, int n5, int n6);
125     int m3d_int_seg_face(int n1,int n2,int n3,int n4,int n5);
126     int m3d_int_seg_seg(int a,int b,int m,int n);
127     int m3d_int_triangle(int n1,int n2,int n3,float x,float y,float z);
128     void m3d_i_triangle(struct s_triangle **tri,int n1, int n2, int n3,int type);
129     void m3d_i_segment(struct s_segment **seg,int n1,int n2);
130     int m3d_i_tetra(struct s_tetra **tetr,struct s_front3d *ft,int n4,int type,struct s_front3d **list_inter,int *nb_inter);
131     int m3d_intersection(int n1,int n2,int n3,int n4,int n5,int n6,int n7);
132     int m3d_gen_noe(struct s_front3d *ft,int *num,int type);
133     void m3d_gest_front(void);
134     void m3d_ord_front(struct s_front3d *ele,int type);
135     void m3d_ord_tet(struct s_tetra *tet);
136     int m3d_traite_destruction(struct s_front3d *ft,struct s_front3d **list_inter,int nb_inter);
137     int m3d_traite_front(int type,struct s_front3d *ft,struct cas_front *cas,int nb_cas,int *liste_cas,int nb_liste_cas);
138     void m3d_update_front(struct s_front3d **ft,struct s_front3d *ftbase,struct s_tetra *tet,int type);
139    
140    
141     /* fonctions d optimisation de maillage 2D*/
142     void o2d(struct s_face *face);
143     int o2d_opt_point(struct s_face *face,struct s_noeud *no,float *crit,float *nu,float *nv,float *nx,float *ny,float *nz);
144     void o2d_ord_tri(struct s_triangle *ele);
145     void o2d_ord_tri2(struct s_triangle *ele);
146    
147    
148     /* fonctions d optimisation de maillage 3D*/
149     int o3d_deraffine(struct s_noeud *no);
150     void o3d_move(int nump,float *coord_res,float *crit);
151     void o3d(void);
152     float o3d_cal_qual(int n1,int n2,int n3,int n4);
153     void o3d_data(void);
154     void o3d_data2(void);
155     int o3d_inv_face(struct s_tetra *tet);
156     void o3d_mail_coq(int n1,int n2, float *crit, struct coquille *coque);
157     void o3d_update_coq(struct coquille *coque);
158    
159     /* fonctions de manipulations de quadtree */
160     struct s_quadtree *qu_ins(float u,float v,float tailleu,float taillev,struct s_noeud **tab_noeud,int nb_tab_noeud);
161     void qu_ins_obj(int type,int num,struct s_quadtree *quad);
162     void qu_parcour(float umin,float vmin,float umax,float vmax,struct s_quadtree *quad,struct s_quadtree **liste,int *nb_liste,int *liste_quad);
163     void qu_parcour2(float bumin,float bvmin,float bumax,float bvmax,struct s_quadtree *quad,int type,int num);
164     void qu_rechercher(float u,float v,float rayon,struct s_quadtree *quad,struct s_quadtree **liste,int *nb_liste);
165    
166     /* fonctions de manipulations d octree */
167     struct s_octree *oc_ins(float x,float y, float z,float taille,struct s_noeud **tab_noeud,int nb_noeud);
168     void oc_ins_obj(int type,int num,struct s_octree *octree);
169     void oc_boite_ellipse(struct s_edge *edge,struct s_ellipse *ellipse,float *bxmin,float *bymin,float *bzmin,float *bxmax,float *bymax,float *bzmax);
170     void oc_boite_straight(struct s_edge *edge,struct s_straight *straight,float *bxmin,float *bymin,float *bzmin,float *bxmax,float *bymax,float *bzmax);
171     void oc_place_boite(int type,void *entite,float bxmin,float bymin,float bzmin,float bxmax,float bymax,float bzmax,struct s_octree *octree);
172     void oc_rechercher(float x,float y,float z,float rayon,struct s_octree *oc,struct s_octree **liste,int *nb_liste);
173     void oc_enreg(void);
174    
175    
176     /* fonctions de remaillage */
177     void r3d_file(char *mess);
178     void r3d_c_octree(void);
179     void r3d_comp(void);
180     void r3d_comp_vertex(struct s_octree *oct,int nb_vertex,float dens);
181     void r3d_comp_edge(struct s_octree *oct,int nb_edge,float dens);
182     void r3d_comp_face(struct s_octree *oct,int nb_face,float dens);
183     void r3d_comp_detruit(int type);
184     void r3d_comp_detruit2(struct s_zone *zone,float x,float y,float z,char type_ent,int num_ent,float rayon,float dens,float *norm,struct s_octree **liste);
185     struct s_segment *r3d_dis(struct s_edge *edge,struct s_noeud *no1,struct s_noeud *no2);
186     void r3d_gene(void);
187     int r3d_gene_noeud(struct s_mnoeud *mno,struct s_octree **liste,int nb_liste);
188     void r3d_gene_segment(struct s_octree **liste ,int nb_liste);
189     void r3d_gene_triangle(void);
190     void r3d_gene_tetra(void);
191     void r3d_m0d(void);
192     void r3d_m1d(void);
193     void r3d_m2d(struct s_octree **liste);
194     void r3d_m3d(struct s_octree **liste);
195     void r3d_ins_segment(struct s_face *face,int n1,int n2,struct s_segment **seg);
196     void r3d_ins_triangle(struct s_face *face,int nb_facette,int *tab_facette,struct s_octree **liste_oct);
197     void r3d_ins_face(int n1,int n2,int n3);
198     void r3d_rech_facette(struct s_face *face,int *nb_facette,int *tab_facette);
199     void r3d_zone(int type,int reference,struct s_octree *oct,float dens,int type_entite,int num,int nb_entite,int *l_entite);
200    
201    
202     void trirea(float *a,int *la,int *ir);
203    
204    
205    
206    
207    
208    
209    
210    
211    
212    
213    
214    
215    
216    
217    
218    
219