OpenGL 3 implementation of glfontstash.h #23
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Made these changes awhile ago but in case a broader audience is interested.
Especially for us poor Mac users a full VAO/VBO/Shader implemenation is needed to render once you switch over to OpenGL 3. As a result I enhanced glfontstash.h by adding a basic shader, create the needed buffers and make it work. Eventually I decided to add this as a new include file called gl3fontstash.h
It is basically a drop in replacement for the old one with only one function added called gl3fonsProjection that allows you to set an orthographical projection matrix to render the text in the correct position.