Skip to content
Snippets Groups Projects
  • Bastien Montagne's avatar
    440216cf
    OBJ Import: Improve parsing performances (overall 5% speedup). · 440216cf
    Bastien Montagne authored
    This commits mainly add a specific, optimized handling for vertex data
    (coos, nors, UVs) expressed on single lines. Nearly all OBJ files I've
    come accross use a single line per vertex data.
    
    This code cand be up to 40% quicker on vertex data parsing, making
    typical parsing about 8% quicker, and typical import about 5% quicker.
    
    Note that I tried applying same kind of optimizations on faces parsing,
    but we need to perform rather more complex checks there, so could not
    get any interesting improvements.
    
    Also, fixing some logical flaw in invalid nor/uvtex indices, which also
    gives marginal speed improvements.
    440216cf
    History
    OBJ Import: Improve parsing performances (overall 5% speedup).
    Bastien Montagne authored
    This commits mainly add a specific, optimized handling for vertex data
    (coos, nors, UVs) expressed on single lines. Nearly all OBJ files I've
    come accross use a single line per vertex data.
    
    This code cand be up to 40% quicker on vertex data parsing, making
    typical parsing about 8% quicker, and typical import about 5% quicker.
    
    Note that I tried applying same kind of optimizations on faces parsing,
    but we need to perform rather more complex checks there, so could not
    get any interesting improvements.
    
    Also, fixing some logical flaw in invalid nor/uvtex indices, which also
    gives marginal speed improvements.