https://github.com/miou-zora/zix
Spline Visualiser using Raylib + Zig + Nix
https://github.com/miou-zora/zix
graphics-programming nix raylib raylib-zig splines zig
Last synced: about 1 month ago
JSON representation
Spline Visualiser using Raylib + Zig + Nix
- Host: GitHub
- URL: https://github.com/miou-zora/zix
- Owner: Miou-zora
- License: mit
- Created: 2024-04-06T20:22:07.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-04-14T16:27:09.000Z (about 2 years ago)
- Last Synced: 2025-03-26T10:12:21.525Z (about 1 year ago)
- Topics: graphics-programming, nix, raylib, raylib-zig, splines, zig
- Language: Zig
- Homepage:
- Size: 532 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Zix (Spline visualizer in Zig)
Zix is a spline visualizer written in zig that use Raylib for rendering and Nix for dev-env.
I will try to implement these functions:
- :white_check_mark: Bézier
- :white_check_mark: Catmull-Rom
- :white_check_mark: B-Spline
- :white_check_mark: Linear
## :bookmark_tabs: Requirements
- :cherry_blossom: [Nix](https://nixos.org/download.html)
> [!IMPORTANT]
> You will need to enable `nix-command` and `flakes`experimental features
> If you get an error about it, consider this command:
> `mkdir -p ~/.config/nix && echo "experimental-features = nix-command flakes" | tee ~/.config/nix/nix.conf`
## :zap: Usage
### :wrench: Setup
Clone this repository and navigate to the project directory.
```shell
git clone https://github.com/Miou-zora/Zix.git
cd Zix
```
### :construction_worker: Building
```shell
zig build
```
### :rocket: Running
```shell
# It will build the project and run it. (do nothing if the project is already built)
zig build run
# or you can run the executable directly
./zig-out/bin/Zix
```
> [!NOTE]
> `nix build` is not supported yet. If you try to use it, it will create a `result` symlink that contain the executable BUT musl isn't linked correctly to binary. It would be appreciated if someone could help me to fix this issue.
### :heavy_plus_sign: Using direnv
You may load the devShell automatically using [direnv](https://direnv.net)
shell integration.
```
echo "use flake" | tee .envrc
direnv allow
```
## :art: Result