liquidfun

Crates.ioliquidfun
lib.rsliquidfun
version0.8.0
sourcesrc
created_at2015-11-15 18:47:11.555455
updated_at2015-12-29 01:30:43.14246
descriptionRust bindings for LiquidFun.
homepage
repositoryhttps://github.com/rjanicek/liquidfun-rust
max_upload_size
id3431
size972,545
Richard Janicek (rjanicek)

documentation

http://rjanicek.github.io/liquidfun-rust/liquidfun/

README

LiquidFun Rust

Rust bindings for LiquidFun.

  • Model LiquidFun C++ API as closely as possible in idiomatic Rust.
  • Documentation for C++ API should be usable for Rust API.
  • Document places where Rust API varries from C++ API.

Documentation

LiquidFun Programmer's Guide

LiquidFun C++ API Documentation

Cargo Crate

Usage

First, add the following to your Cargo.toml:

[dependencies]
liquidfun = "*"

Next, add this to your crate root:

extern crate liquidfun;

Example

extern crate liquidfun;

use liquidfun::box2d::common::math::*;
use liquidfun::box2d::dynamics::world::*;

#[test]
fn hello_world() {

	// Define the gravity vector.
	let gravity = Vec2::new(0.0, -10.0);

	// Construct a world object, which will hold and simulate the rigid bodies.
	let mut world = World::new(&gravity);
	assert_eq!(gravity, world.get_gravity());

}

Status

The LiquidFun Hello World example compiles and runs. More bindings will be added as needed by projects that depend on LiquidFun Rust.

Thank You

Erin Catto for Box2D

Google for LiquidFun

Nicolas Silva for box2d.rs

Commit count: 9

cargo fmt