2 * garbage_thick_edge.cxx
3 * Daniel Nelson - 9/1/0
5 * Copyright (C) 2000 Daniel Nelson
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version 2
10 * of the License, or (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21 * Daniel Nelson - aluminumangel.org
25 * Generates a display list for the edge of thick garbage.
38 #include "Displayer.h"
40 GLuint
Displayer::garbage_thick_edge_list
;
42 void Displayer::generateGarbageThickEdgeList ( )
44 garbage_thick_edge_list
= glGenLists(1);
46 glEnableClientState(GL_VERTEX_ARRAY
);
47 glEnableClientState(GL_NORMAL_ARRAY
);
48 glEnableClientState(GL_TEXTURE_COORD_ARRAY
);
50 glNewList(garbage_thick_edge_list
, GL_COMPILE
);
52 GLfloat vertices_0
[3 * 12] = {
67 GLfloat normals_0
[3 * 12] = {
83 GLfloat tex_coords_0
[3 * 12];
84 for (int n
= 3 * 12; n
--; )
85 tex_coords_0
[n
] = vertices_0
[n
] * DC_GARBAGE_LIGHTMAP_COORD_CONVERTER
;
87 glVertexPointer(3, GL_FLOAT
, 0, vertices_0
);
88 glNormalPointer(GL_FLOAT
, 0, normals_0
);
89 glTexCoordPointer(3, GL_FLOAT
, 0, tex_coords_0
);
90 glDrawArrays(GL_TRIANGLE_STRIP
, 0, 12);
94 glDisableClientState(GL_VERTEX_ARRAY
);
95 glDisableClientState(GL_NORMAL_ARRAY
);
96 glDisableClientState(GL_TEXTURE_COORD_ARRAY
);