mirror of
https://github.com/Ed94/Odin.git
synced 2026-07-27 09:50:03 +00:00
Fix slicing bug on dynamic arrays
This commit is contained in:
@@ -47,6 +47,7 @@ GetProcAddress :: proc(name: string) -> proc() #cc_c {
|
||||
GenBuffers: proc(count: i32, buffers: ^u32) #cc_c;
|
||||
GenVertexArrays: proc(count: i32, buffers: ^u32) #cc_c;
|
||||
GenSamplers: proc(count: i32, buffers: ^u32) #cc_c;
|
||||
DeleteBuffers: proc(count: i32, buffers: ^u32) #cc_c;
|
||||
BindBuffer: proc(target: i32, buffer: u32) #cc_c;
|
||||
BindVertexArray: proc(buffer: u32) #cc_c;
|
||||
BindSampler: proc(position: i32, sampler: u32) #cc_c;
|
||||
@@ -108,6 +109,7 @@ init :: proc() {
|
||||
set_proc_address(^GenBuffers, "glGenBuffers\x00");
|
||||
set_proc_address(^GenVertexArrays, "glGenVertexArrays\x00");
|
||||
set_proc_address(^GenSamplers, "glGenSamplers\x00");
|
||||
set_proc_address(^DeleteBuffers, "glDeleteBuffers\x00");
|
||||
set_proc_address(^BindBuffer, "glBindBuffer\x00");
|
||||
set_proc_address(^BindSampler, "glBindSampler\x00");
|
||||
set_proc_address(^BindVertexArray, "glBindVertexArray\x00");
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
#import win32 "sys/windows.odin";
|
||||
#import fmt "fmt.odin";
|
||||
|
||||
Handle :: int;
|
||||
File_Time :: u64;
|
||||
|
||||
+11
-2
@@ -51,8 +51,17 @@ Glyph_Metrics_Float :: struct #ordered {
|
||||
cell_inc_y: f32,
|
||||
}
|
||||
|
||||
Create_Context_Attribs_ARB_Type :: #type proc(hdc: Hdc, hshareContext: rawptr, attribList: ^i32) -> Hglrc;
|
||||
Choose_Pixel_Format_ARB_Type :: #type proc(hdc: Hdc, attrib_i_list: ^i32, attrib_f_list: ^f32, max_formats: u32, formats: ^i32, num_formats : ^u32) -> Bool #cc_c;
|
||||
CreateContextAttribsARB_Type :: #type proc(hdc: Hdc, h_share_context: rawptr, attribList: ^i32) -> Hglrc;
|
||||
ChoosePixelFormatARB_Type :: #type proc(hdc: Hdc, attrib_i_list: ^i32, attrib_f_list: ^f32, max_formats: u32, formats: ^i32, num_formats : ^u32) -> Bool #cc_c;
|
||||
SwapIntervalEXT_Type :: #type proc(interval : i32) -> bool #cc_c;
|
||||
GetExtensionsStringARB_Type :: #type proc(Hdc) -> ^byte #cc_c;
|
||||
|
||||
|
||||
CreateContextAttribsARB: CreateContextAttribsARB_Type;
|
||||
ChoosePixelFormatARB: ChoosePixelFormatARB_Type;
|
||||
SwapIntervalEXT: SwapIntervalEXT_Type;
|
||||
GetExtensionsStringARB: GetExtensionsStringARB_Type;
|
||||
|
||||
|
||||
|
||||
CreateContext :: proc(hdc: Hdc) -> Hglrc #foreign opengl32 "wglCreateContext";
|
||||
|
||||
Reference in New Issue
Block a user