|
116
|
1 /* Iris - visualization plugin for XMMS
|
|
|
2 * Copyright (C) 2000-2002 Cédric DELFOSSE (cdelfosse@free.fr)
|
|
|
3 *
|
|
|
4 * This program is free software; you can redistribute it and/or modify
|
|
|
5 * it under the terms of the GNU General Public License as published by
|
|
|
6 * the Free Software Foundation; either version 2 of the License, or
|
|
|
7 * (at your option) any later version.
|
|
|
8 *
|
|
|
9 * This program is distributed in the hope that it will be useful,
|
|
|
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
12 * GNU General Public License for more details.
|
|
|
13 *
|
|
|
14 * You should have received a copy of the GNU General Public License
|
|
|
15 * along with this program; if not, write to the Free Software
|
|
|
16 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
17 */
|
|
|
18
|
|
|
19 #include "iris.h"
|
|
|
20
|
|
|
21
|
|
|
22 void
|
|
|
23 bar_top_or_bottom (GLfloat height, xz * xz1, xz * xz2, xz * xz3, xz * xz4)
|
|
|
24 {
|
|
|
25 glVertex3f (xz1->x, height, xz1->z);
|
|
|
26 glVertex3f (xz2->x, height, xz2->z);
|
|
|
27 glVertex3f (xz4->x, height, xz4->z);
|
|
|
28 glVertex3f (xz3->x, height, xz3->z);
|
|
|
29 }
|
|
|
30
|
|
|
31
|
|
|
32 void
|
|
|
33 bar_side (GLfloat height, xz * xz1, xz * xz2)
|
|
|
34 {
|
|
|
35 glVertex3f (xz1->x, height, xz1->z);
|
|
|
36 glVertex3f (xz1->x, 0, xz1->z);
|
|
|
37 glVertex3f (xz2->x, 0, xz2->z);
|
|
|
38
|
|
|
39 glVertex3f (xz2->x, height, xz2->z);
|
|
|
40 }
|
|
|
41
|
|
|
42
|
|
|
43 void
|
|
|
44 bar_full (GLfloat height, xz * xz1, xz * xz2, xz * xz3, xz * xz4)
|
|
|
45 {
|
|
|
46 bar_top_or_bottom (height, xz1, xz2, xz3, xz4);
|
|
|
47 bar_side (height, xz1, xz2);
|
|
|
48 bar_side (height, xz3, xz4);
|
|
|
49 bar_side (height, xz1, xz2);
|
|
|
50 bar_side (height, xz3, xz4);
|
|
|
51 }
|