This commit was generated by cvs2svn to compensate for changes in r2,
[u/mrichter/AliRoot.git] / GEANT321 / gdraw / gdrect.F
1 *
2 * $Id$
3 *
4 * $Log$
5 * Revision 1.1.1.1  1995/10/24 10:20:27  cernlib
6 * Geant
7 *
8 *
9 #include "geant321/pilot.h"
10 *CMZ :  3.21/02 29/03/94  15.41.27  by  S.Giani
11 *-- Author :
12       SUBROUTINE GDRECT(P1,P2,P3,P4)
13 C.
14 C.    ******************************************************************
15 C.    *                                                                *
16 C.    *       Draw a rectangle of points P1,P2,P3,P4                   *
17 C.    *                                                                *
18 C.    *    ==>Called by : GDRAWS                                       *
19 C.    *       Author : P.Zanarini   *********                          *
20 C.    *                                                                *
21 C.    ******************************************************************
22 C.
23 CM
24 #include "geant321/gcdraw.inc"
25 CM
26       DIMENSION P1(3),P2(3),P3(3),P4(3),U(5),V(5),X(3,4)
27       DIMENSION Q1(3),Q2(3),Q3(3),Q4(3)
28       EQUIVALENCE (Q1(1),X(1,1)),(Q2(1),X(1,2))
29       EQUIVALENCE (Q3(1),X(1,3)),(Q4(1),X(1,4))
30 C.
31 C.    ------------------------------------------------------------------
32 C.
33       DO 10 I=1,3
34          Q1(I)=P1(I)
35          Q2(I)=P2(I)
36          Q3(I)=P3(I)
37          Q4(I)=P4(I)
38    10 CONTINUE
39 C
40       CALL GDFR3D(X,4,U,V)
41 C
42 CM             Short circuit in case of GMR
43 C
44       IF ( IGMR .NE. 0 ) GO TO 999
45 CM
46       U(5)=U(1)
47       V(5)=V(1)
48       CALL GDRAWV(U,V,5)
49 C
50   999 RETURN
51       END