raylib_imgui_rs

Crates.ioraylib_imgui_rs
lib.rsraylib_imgui_rs
version
sourcesrc
created_at2024-11-15 22:19:47.76136
updated_at2024-12-02 00:14:15.436215
descriptionA Raylib integration with DearImGui in Rust!
homepagehttps://github.com/Fullbrik/raylib_imgui_rs
repositoryhttps://github.com/Fullbrik/raylib_imgui_rs
max_upload_size
id1449675
Cargo.toml error:TOML parse error at line 18, column 1 | 18 | autolib = false | ^^^^^^^ unknown field `autolib`, expected one of `name`, `version`, `edition`, `authors`, `description`, `readme`, `license`, `repository`, `homepage`, `documentation`, `build`, `resolver`, `links`, `default-run`, `default_dash_run`, `rust-version`, `rust_dash_version`, `rust_version`, `license-file`, `license_dash_file`, `license_file`, `licenseFile`, `license_capital_file`, `forced-target`, `forced_dash_target`, `autobins`, `autotests`, `autoexamples`, `autobenches`, `publish`, `metadata`, `keywords`, `categories`, `exclude`, `include`
size0
Mcp613 (Fullbrik)

documentation

README

raylib_imgui_rs

Crates.io Version

raylib logo animated A Raylib integration with DearImGui in Rust!

Based on rlImgui

Setup:

In Cargo.toml:

[dependencies]
raylib_imgui_rs = "<Latest version here>"

In main.rs:

use imgui::{Context, FontSource};
use raylib::prelude::*;
use raylib_imgui_rs::Renderer;

fn main() {
    // Init raylib
    let (mut rl, thread) = raylib::init()
        .size(640, 480)
        .title("Hello, World")
        .build();

    let mut imgui = Context::create();
    imgui.fonts().add_font(&[FontSource::DefaultFontData { config: None }]);

    let mut renderer = Renderer::create(&mut imgui, &mut rl, &thread);

    while !rl.window_should_close() {
        renderer.update(&mut imgui, &mut rl);
        
        {
            let ui = imgui.new_frame();
            // Draw Imgui stuff here
        }
        
        {
            let mut d = rl.begin_drawing(&thread);

            d.clear_background(Color::WHITE);
            // Draw raylib stuff here

            renderer.render(&mut imgui, &mut d);
        }
    }
}
Commit count: 6

cargo fmt