diff --git a/vendor/raylib/LICENSE b/vendor/raylib/v6.0/LICENSE similarity index 100% rename from vendor/raylib/LICENSE rename to vendor/raylib/v6.0/LICENSE diff --git a/vendor/raylib/README.md b/vendor/raylib/v6.0/README.md similarity index 93% rename from vendor/raylib/README.md rename to vendor/raylib/v6.0/README.md index 00929215c..1f9740f6d 100644 --- a/vendor/raylib/README.md +++ b/vendor/raylib/v6.0/README.md @@ -56,25 +56,22 @@ features basic example -------------- -This is a basic raylib example, it creates a window and draws the text `"Congrats! You created your first window!"` in the middle of the screen. Check this example [running live on web here](https://www.raylib.com/examples/core/loader.html?name=core_basic_window). -```c -#include "raylib.h" +This is a basic raylib example, it creates a window and it draws the text `"Congrats! You created your first window!"` in the middle of the screen. Check this example [running live on web here](https://www.raylib.com/examples/core/loader.html?name=core_basic_window). +```odin +package example -int main(void) -{ - InitWindow(800, 450, "raylib example - basic window"); +import rl "vendor:raylib" - while (!WindowShouldClose()) - { - BeginDrawing(); - ClearBackground(RAYWHITE); - DrawText("Congrats! You created your first window!", 190, 200, 20, LIGHTGRAY); - EndDrawing(); - } +main :: proc() { + rl.InitWindow(800, 450, "raylib [core] example - basic window") - CloseWindow(); - - return 0; + for !rl.WindowShouldClose() { + rl.BeginDrawing() + rl.ClearBackground(rl.RAYWHITE) + rl.DrawText("Congrats! You created your first window!", 190, 200, 20, rl.LIGHTGRAY) + rl.EndDrawing() + } + rl.CloseWindow() } ``` diff --git a/vendor/raylib/easings.odin b/vendor/raylib/v6.0/easings.odin similarity index 100% rename from vendor/raylib/easings.odin rename to vendor/raylib/v6.0/easings.odin diff --git a/vendor/raylib/raygui.odin b/vendor/raylib/v6.0/raygui.odin similarity index 100% rename from vendor/raylib/raygui.odin rename to vendor/raylib/v6.0/raygui.odin diff --git a/vendor/raylib/raylib.odin b/vendor/raylib/v6.0/raylib.odin similarity index 99% rename from vendor/raylib/raylib.odin rename to vendor/raylib/v6.0/raylib.odin index 57aa13085..137dc82ab 100644 --- a/vendor/raylib/raylib.odin +++ b/vendor/raylib/v6.0/raylib.odin @@ -1137,7 +1137,7 @@ foreign lib { IsKeyUp :: proc(key: KeyboardKey) -> bool --- // Detect if a key is NOT being pressed GetKeyPressed :: proc() -> KeyboardKey --- // Get key pressed (keycode), call it multiple times for keys queued GetCharPressed :: proc() -> rune --- // Get char pressed (unicode), call it multiple times for chars queued - GetKeyName :: proc(key: c.int) -> cstring --- // Get name of a QWERTY key on the current keyboard layout (eg returns string 'q' for KEY_A on an AZERTY keyboard) + GetKeyName :: proc(key: KeyboardKey) -> cstring --- // Get name of a QWERTY key on the current keyboard layout (eg returns string 'q' for KEY_A on an AZERTY keyboard) SetExitKey :: proc(key: KeyboardKey) --- // Set a custom key to exit program (default is ESC) // Input-related functions: gamepads @@ -1483,7 +1483,7 @@ foreign lib { SetTextLineSpacing :: proc(spacing: c.int) --- // Set vertical line spacing when drawing with line-breaks MeasureText :: proc(text: cstring, fontSize: c.int) -> c.int --- // Measure string width for default font MeasureTextEx :: proc(font: Font, text: cstring, fontSize: f32, spacing: f32) -> Vector2 --- // Measure string size for Font - MeasureTextCodepoints :: proc(font: Font, codepoints: [^]c.int, length: c.int, fontSize, spacing: f32) --- // Measure string size for an existing array of codepoints for Font + MeasureTextCodepoints :: proc(font: Font, codepoints: [^]c.int, length: c.int, fontSize, spacing: f32) -> Vector2 --- // Measure string size for an existing array of codepoints for Font GetGlyphIndex :: proc(font: Font, codepoint: rune) -> c.int --- // Get glyph index position in font for a codepoint (unicode character), fallback to '?' if not found GetGlyphInfo :: proc(font: Font, codepoint: rune) -> GlyphInfo --- // Get glyph font info data for a codepoint (unicode character), fallback to '?' if not found GetGlyphAtlasRec :: proc(font: Font, codepoint: rune) -> Rectangle --- // Get glyph rectangle in font atlas for a codepoint (unicode character), fallback to '?' if not found diff --git a/vendor/raylib/raymath.odin b/vendor/raylib/v6.0/raymath.odin similarity index 100% rename from vendor/raylib/raymath.odin rename to vendor/raylib/v6.0/raymath.odin diff --git a/vendor/raylib/rlgl/rlgl.odin b/vendor/raylib/v6.0/rlgl/rlgl.odin similarity index 99% rename from vendor/raylib/rlgl/rlgl.odin rename to vendor/raylib/v6.0/rlgl/rlgl.odin index 5aa7726d9..d1655d363 100644 --- a/vendor/raylib/rlgl/rlgl.odin +++ b/vendor/raylib/v6.0/rlgl/rlgl.odin @@ -484,7 +484,7 @@ foreign lib { @(link_prefix="rlgl") Close :: proc() --- // De-initialize rlgl (buffers, shaders, textures) LoadExtensions :: proc(loader: rawptr) --- // Load OpenGL extensions (loader function required) - GetProcAddress :: proc(procName: cstring) // Get OpenGL procedure address + GetProcAddress :: proc(procName: cstring) -> rawptr --- // Get OpenGL procedure address GetVersion :: proc() -> GlVersion --- // Get current OpenGL version SetFramebufferWidth :: proc(width: c.int) --- // Set current framebuffer width GetFramebufferWidth :: proc() -> c.int --- // Get default framebuffer width