Add repr(C) to GPU types
This commit is contained in:
parent
805c5ad0cd
commit
67570a0a1d
2 changed files with 4 additions and 0 deletions
|
|
@ -427,6 +427,7 @@ pub struct Image {
|
||||||
pub scale: [f32; 2],
|
pub scale: [f32; 2],
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[repr(C)]
|
||||||
#[derive(Clone, Copy)]
|
#[derive(Clone, Copy)]
|
||||||
pub struct Vertex {
|
pub struct Vertex {
|
||||||
_position: [f32; 2],
|
_position: [f32; 2],
|
||||||
|
|
@ -449,6 +450,7 @@ const QUAD_VERTS: [Vertex; 4] = [
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
#[repr(C)]
|
||||||
#[derive(Clone, Copy)]
|
#[derive(Clone, Copy)]
|
||||||
struct Instance {
|
struct Instance {
|
||||||
_position: [f32; 2],
|
_position: [f32; 2],
|
||||||
|
|
|
||||||
|
|
@ -248,6 +248,7 @@ impl Pipeline {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[repr(C)]
|
||||||
#[derive(Clone, Copy)]
|
#[derive(Clone, Copy)]
|
||||||
pub struct Vertex {
|
pub struct Vertex {
|
||||||
_position: [f32; 2],
|
_position: [f32; 2],
|
||||||
|
|
@ -270,6 +271,7 @@ const QUAD_VERTS: [Vertex; 4] = [
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
#[repr(C)]
|
||||||
#[derive(Debug, Clone, Copy)]
|
#[derive(Debug, Clone, Copy)]
|
||||||
pub struct Quad {
|
pub struct Quad {
|
||||||
pub position: [f32; 2],
|
pub position: [f32; 2],
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue