Make TexImage2D and TexSubImage2D struct variants

This commit is contained in:
Anthony Ramine 2018-11-15 10:32:20 +01:00
parent da43e35ab2
commit 65d1b11929
3 changed files with 70 additions and 47 deletions

View file

@ -272,8 +272,27 @@ pub enum WebGLCommand {
VertexAttribPointer(u32, i32, u32, bool, i32, u32),
VertexAttribPointer2f(u32, i32, bool, i32, u32),
SetViewport(i32, i32, i32, i32),
TexImage2D(u32, i32, i32, i32, i32, u32, u32, IpcBytesReceiver),
TexSubImage2D(u32, i32, i32, i32, i32, i32, u32, u32, IpcBytesReceiver),
TexImage2D {
target: u32,
level: u32,
internal_format: u32,
width: u32,
height: u32,
format: u32,
data_type: u32,
receiver: IpcBytesReceiver,
},
TexSubImage2D {
target: u32,
level: u32,
xoffset: i32,
yoffset: i32,
width: u32,
height: u32,
format: u32,
data_type: u32,
receiver: IpcBytesReceiver,
},
DrawingBufferWidth(WebGLSender<i32>),
DrawingBufferHeight(WebGLSender<i32>),
Finish(WebGLSender<()>),