drawing_gl 0.8.0

OpenGL backend for 2D graphics library
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#[repr(C, packed)]
#[derive(Copy, Clone)]
pub struct TexturedVertex {
    pub pos: [f32; 2],
    pub tex_coords: [f32; 2],
    pub color: [f32; 4],
}

impl TexturedVertex {
    pub fn new(pos: [f32; 2], tex_coords: [f32; 2], color: [f32; 4]) -> Self {
        TexturedVertex {
            pos,
            tex_coords,
            color,
        }
    }
}