Skip to content

ngrilly/zig3d

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Zig 3D

A repository where I'm playing with Zig, raylib and OpenGL.

Build and run from source

Install Zig (tested with Zig 0.12.0)

$ git clone "https://github.com/ngrilly/zig3d.git"
$ cd zig3d
$ zig build run

Learnings

Steps I followed to use raylib

  1. Add raylib as a dependency:
    zig fetch --save=raylib https://github.com/raysan5/raylib/archive/9d628d1d499f8ad9c0e6fbed69914cecb611d6cd.tar.gz
    
  2. Add the following in build.zig:
    const raylib_dep = b.dependency("raylib", .{});
    exe.linkLibrary(raylib_dep.artifact("raylib"));
    
  3. Import it in main.zig:
    const raylib = @cImport({
        @cInclude("raylib.h");
    });
    

How does the above compare to using an external Go module?

Glossary

LOD: Level Of Detail VBO: Vertex Buffer Object

References

Game physis

Problems

Todo

  • Fly using newtonian physics
  • Check lighting is right
  • Structure the code
  • Sound (engine, collisions, etc.)
  • Collisions

Credits

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published