What is state-of-the-art for text rendering in OpenGL as of version 4.1? [closed]

There are already a number of questions about text rendering in OpenGL, such as:

  • How to do OpenGL live text-rendering for a GUI?

But mostly what is discussed is rendering textured quads using the fixed-function pipeline. Surely shaders must make a better way.

I’m not really concerned about internationalization, most of my strings will be plot tick labels (date and time or purely numeric). But the plots will be re-rendered at the screen refresh rate and there could be quite a bit of text (not more than a few thousand glyphs on-screen, but enough that hardware accelerated layout would be nice).

What is the recommended approach for text-rendering using modern OpenGL? (Citing existing software using the approach is good evidence that it works well)

  • Geometry shaders that accept e.g. position and orientation and a character sequence and emit textured quads
  • Geometry shaders that render vector fonts
  • As above, but using tessellation shaders instead
  • A compute shader to do font rasterization

5 Answers
5

Leave a Comment