Crate off_rs

Source
Expand description

A simple .off file parser.

§Usage

   let off_string = r#"
OFF
3 1
1.0 0.0 0.0
0.0 1.0 0.0
0.0 0.0 1.0
4  0 1 2 3  255 0 0 # red
"#;

let mesh = off_rs::parse(
   off_string,
   Default::default() // optional ParserOptions
);

Modules§

geometry
parser

Enums§

Error
Contains errors that occur during parsing.

Functions§

from_path
Parse a crate::geometry::mesh::Mesh from a std::path::Path pointing to an .off file.
parse
Directly parse a crate::geometry::mesh::Mesh from an off string.

Type Aliases§

Result
This result may contain the parsed crate::geometry::mesh::Mesh or the self::Result that occurred.