implementation of glyph coherence and compression