1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
use crate::color::Color;
use crate::pipeline::*;

#[allow(unused)]
#[derive(Debug, Clone)]
pub enum Commands {
    Size {
        width: u32,
        height: u32,
    },
    Viewport {
        x: f32,
        y: f32,
        width: f32,
        height: f32,
    },
    Begin {
        color: Option<Color>,
        depth: Option<f32>,
        stencil: Option<i32>,
    },
    End,
    Pipeline {
        id: u64,
        options: PipelineOptions,
    },
    BindBuffer {
        id: u64,
    },
    BindTexture {
        id: u64,
        slot: u32,
        location: u32,
    },
    Scissors {
        x: f32,
        y: f32,
        width: f32,
        height: f32,
    },
    Draw {
        primitive: DrawPrimitive,
        offset: i32,
        count: i32,
    },
    DrawInstanced {
        primitive: DrawPrimitive,
        offset: i32,
        count: i32,
        length: i32,
    },
}