#rendering-engine #3d-rendering #terrain #built #primary #visualizing #goal

bin+lib gilgamesh

A small 3D rendering engine built upon WGPU with the primary goal of visualizing procedural terrains

8 unstable releases (3 breaking)

0.4.0 May 12, 2023
0.3.0 May 9, 2023
0.2.2 May 8, 2023
0.1.2 May 8, 2023

#802 in Graphics APIs

Download history 17/week @ 2024-09-22

74 downloads per month

Apache-2.0

220KB
1K SLoC

Rust 1K SLoC // 0.0% comments WebGPU Shader Language 116 SLoC // 0.0% comments

Gilgamesh

Rust

A small 3D rendering engine built upon WGPU with the primary goal of visualizing procedural terrains.

Loosely based on Dr. Xu youtube series

Gilgamesh

Getting Started

Here is a quick example of how to use Gilgamesh to render a procedural terrain:

extern crate gilgamesh;

use gilgamesh::{init_gilgamesh, start_gilgamesh};
use gilgamesh::mesh::Mesh;

fn main() {
    let mut app = init_gilgamesh();

    let sphere = Mesh::new_procedural_sphere(5.0, 32, &|x, y, z| {
        f32::powi(f32::sin(60.0 * x * y * z), 2) / 2.0
    }, 0.5, &mut app.engine);

    app.scene.add_mesh(sphere);

    start_gilgamesh(app);
}

Dependencies

~12–26MB
~446K SLoC