more performance improvements to stlviewer