Skip to content

bbodi/rust-voxlap-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rust Voxlap Test

Showcase and sample application for rust-voxlap, which is Voxlap binding for Rust.

Overview

Voxlap is a voxel engine by Ken Silverman: http://advsys.net/ken/voxlap.htm

This demo demonstrates how to use Voxlap engine in Rust through rust-voxlap binding.

I tried to pack a lot of showcase feature in this demo, so the scene is a little bit chaotic.

Requirements

32-bit Rust Nightly installer

Voxlap functionality is curently provided through a 32-bit dll file, so you need the 32-bit Rust Nightly installer.

This repository contains all the necessary library files for Windows (voxlap.lib, voxlap.dll), SDL2 is provided via bundled feature, and Cargo (Rust package manager) handles all the dependencies, so you don't need to care a lot about the following requirements.

SDL2

rust-voxlap is independent from any system dependencies, but the demo uses Rust-SDL2 for

  • creating window
  • copying the buffer which contains the rendered scene calculated by Voxlap to the screen (including 2D texts and images)
  • handling input
  • TODO: handling sound

Installation

Use the Rust Nightly installer and cargo to run the demo:

git clone https://github.com/bbodi/rust-voxlap-test.git
cd rust-voxlap-test
cargo run

For x86_64 platform you should run with:

rustup target add i686-pc-windows-msvc
cargo run --target=i686-pc-windows-msvc

Voxlap libraries

This repository contains all the necessary library files for Windows, but if you need to compile your own files, here is a little help:
The voxlap.lib was compiled based on this repository with Visual Studio 2010. I find this repo the easiest to compile, but you can use other sources too.
But be aware, this repo contains two commits, but you only need the first one!
(The second commit tries to raise the map size from 1024x1024 to 2048x2048, but the modifications are incomplete, and you cannot load .vxl files correctly with this second commit.)
After you checked it out and reversed to the first commit, you need to create a .lib from the voxlap project in Visual Studio.

Images

Empty room with a green voxel

About

Testing the Voxlap binding for Rust

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages