3 releases

0.1.2 Sep 11, 2020
0.1.1 Sep 11, 2020
0.1.0 Sep 11, 2020

#36 in Data formats

Apache-2.0 AND MIT

447 lines


crates.io crates.io

A Wavefront OBJ parser and utility crate.

wavefront = "x.y.z"


let model = wavefront::Obj::from_file("tests/ship.obj").unwrap();

for [a, b, c] in model.triangles() {
    // No index lookup required: wavefront handles this for you!
    println!("{:?} {:?} {:?}", a.position(), b.position(), c.position());

A parsec isn't a unit of time, Han


  • Ergonomic API for parsing OBJs from files and readers.

  • Wrapper types that automatically perform indexing and hide the annoyances of the OBJ format if you just want to grab some triangles.

  • Correct handling of complex polygons.


  • Materials and the MTL support.

  • Object, group, polygon, vertex and vertex attribute insertion

  • Saving

  • Arbitrary geometry support.

Why not [alternative]?

wavefront was born of a general feeling that the API of existing OBJ parsers were either unnecessarily verbose or didn't properly handle the heirarchical structure of the OBJ format. wavefront aims to couple correct handling of the format's features with a clean, terse API that allows you to jump straight to the thing you want to do: rendering your model.


wavefront is distributed under either of:

at the disgression of the user.

No runtime deps