wasm shell + destructuring
This commit is contained in:
@@ -86,6 +86,12 @@ glReadPixels : (s32, s32, s32, s32, u32, u32, *void) -> void = ---;
|
||||
glActiveTexture : (u32) -> void = ---;
|
||||
glUniform1i : (s32, s32) -> void = ---;
|
||||
glPixelStorei : (u32, s32) -> void = ---;
|
||||
glTexSubImage2D : (u32, s32, s32, s32, s32, s32, u32, u32, *void) -> void = ---;
|
||||
glDeleteTextures : (s32, *u32) -> void = ---;
|
||||
|
||||
GL_TEXTURE_WRAP_S :u32: 0x2802;
|
||||
GL_TEXTURE_WRAP_T :u32: 0x2803;
|
||||
GL_CLAMP_TO_EDGE :u32: 0x812F;
|
||||
|
||||
// Loader: call once after creating GL context
|
||||
// Pass in a proc loader (e.g. SDL_GL_GetProcAddress)
|
||||
@@ -133,6 +139,8 @@ load_gl :: (get_proc: ([*]u8) -> *void) {
|
||||
glActiveTexture = xx get_proc("glActiveTexture");
|
||||
glUniform1i = xx get_proc("glUniform1i");
|
||||
glPixelStorei = xx get_proc("glPixelStorei");
|
||||
glTexSubImage2D = xx get_proc("glTexSubImage2D");
|
||||
glDeleteTextures = xx get_proc("glDeleteTextures");
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user