Skip to main content

parse_obj_text

Function parse_obj_text 

Source
pub fn parse_obj_text(source: &str) -> Result<ObjMesh<'_>, ObjError>
Expand description

Parses a supported OBJ text mesh as a zero-copy borrowed view.

The supported profile accepts v x y z vertices, triangular f faces, and common metadata statements. Face indices are converted from OBJ one-based indexing into zero-based Triangle32 values.

ยงErrors

Returns ObjError when the source contains unsupported statements, malformed vertices, malformed faces, or out-of-range face indices.