Code Snippets Odin

Short texts Odin 🧑‍💻 Code snippets Odin ✍️ Reading lists Odin 👀

microui + raylib Demo in Odin

package microui_raylib import “core:fmt” import “core:unicode/utf8” import rl “vendor:raylib” import mu “vendor:microui” state := struct { mu_ctx: mu.Context, log_buf: [1 string { return string(state.log_buf[:state.log_buf_len]) } reset_log :: proc() { state.log_buf_updated = true state.log_buf_len = 0 } all_windows :: proc(ctx: ^mu.Context) { @static opts := mu.Options{.NO_CLOSE} if mu.window(ctx, “Demo Window”, {40, 40, 300, 450}, opts) { […]

microui + SDL Demo in Odin

package microui_sdl import “core:fmt” import SDL “vendor:sdl2” import mu “vendor:microui” state := struct { mu_ctx: mu.Context, log_buf: [1