ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/REPOS_ERICCA/acismesh/oc_boite_straight.cpp
Revision: 1
Committed: Mon Jun 11 22:53:07 2007 UTC (17 years, 11 months ago)
File size: 2158 byte(s)
Log Message:

File Contents

# Content
1 /*****************************************************************
2
3 oc_boite_straight.c Type:Func
4
5 Mise en boite d une ligne
6
7 Date de creation : Wed Jun 25 16:27:55 1997
8
9 Derniere version : Wed Jul 2 09:04:53 1997
10
11
12
13 Vincent FRANCOIS
14
15 *****************************************************************/
16
17
18
19
20
21 /**************************/
22 /* include */
23 #include <stdio.h>
24 #include <string.h>
25 #include "const.h"
26 #include "memoire.h"
27 #include "struct.h"
28 #include "prototype.h"
29
30 /**************************/
31 /* variables globales */
32 extern struct s_acis *acis;
33 extern struct environnement env;
34 extern struct s_mesh *mesh;
35 extern struct s_param *para;
36
37
38
39 /**************************/
40 /* programme principal */
41
42 void oc_boite_straight(struct s_edge *edge,struct s_straight *straight,float *bxmin,float *bymin,float *bzmin,float *bxmax,float *bymax,float *bzmax)
43 {
44 struct s_vertex *vertex1,*vertex2;
45
46 vertex1=edge->start_vertex;
47 vertex2=edge->end_vertex;
48 MINI(*bxmin,*bxmin,vertex1->point->coord[0]);
49 MINI(*bymin,*bymin,vertex1->point->coord[1]);
50 MINI(*bzmin,*bzmin,vertex1->point->coord[2]);
51 MAXI(*bxmax,*bxmax,vertex1->point->coord[0]);
52 MAXI(*bymax,*bymax,vertex1->point->coord[1]);
53 MAXI(*bzmax,*bzmax,vertex1->point->coord[2]);
54 MINI(*bxmin,*bxmin,vertex2->point->coord[0]);
55 MINI(*bymin,*bymin,vertex2->point->coord[1]);
56 MINI(*bzmin,*bzmin,vertex2->point->coord[2]);
57 MAXI(*bxmax,*bxmax,vertex2->point->coord[0]);
58 MAXI(*bymax,*bymax,vertex2->point->coord[1]);
59 MAXI(*bzmax,*bzmax,vertex2->point->coord[2]);
60 }