Delete and suppress warnings
Getty Ritter
6 years ago
14 | 14 | pub use graphics::*; |
15 | 15 | } |
16 | 16 | |
17 | #[allow(dead_code)] | |
17 | 18 | struct Vertex { |
18 | 19 | x: gl::GLfloat, |
19 | 20 | y: gl::GLfloat, |
21 | 22 | v: gl::GLfloat, |
22 | 23 | } |
23 | 24 | |
24 | impl Vertex { | |
25 | fn new( | |
26 | x: gl::GLfloat, | |
27 | y: gl::GLfloat, | |
28 | u: gl::GLfloat, | |
29 | v: gl::GLfloat, | |
30 | ) -> Vertex { | |
31 | Vertex { x, y, u, v } | |
32 | } | |
33 | } | |
34 | ||
35 | 25 | static TILE_DATA: [Vertex; 4] = [ |
36 | 26 | Vertex { x: 0.5, y: -0.5, u: 1.0, v: 0.0 }, |
37 | 27 | Vertex { x: -0.5, y: -0.5, u: 0.0, v: 0.0 }, |
38 | 28 | Vertex { x: 0.5, y: 0.5, u: 1.0, v: 1.0 }, |
39 | 29 | Vertex { x: -0.5, y: 0.5, u: 0.0, v: 1.0 }, |
40 | ]; | |
41 | ||
42 | static VERTEX_DATA: [Vertex; 3] = [ | |
43 | Vertex { x: 0.0, y: 0.5, u: 0.0, v: 0.0 }, | |
44 | Vertex { x: 0.5, y: -0.5, u: 0.0, v: 0.0 }, | |
45 | Vertex { x: -0.5, y: -0.5, u: 0.0, v: 0.0 }, | |
46 | 30 | ]; |
47 | 31 | |
48 | 32 | // Shader sources |