FTGL OpenGL code of Chastity White Rose

This page will be dedicated to animations I made that involve text with the FTGL library. FTGL is a wrapper around freetype that allows drawing text directly onto an OpenGl context. I will add more information as I find time.

FTGL has allowed me to add text where I want in my OpenGL programs. I had similar means of doing graphics with SDL and Allegro but now that I've moved to using OpenGL for all graphics projects I needed a reliable way to make text because OpenGL is only about basic shapes and is fine when drawing a polygon but not simply displaying text to a part of the screen. In fact it's easy to overlook the imporance of text at first, but because I hope of making a video game, I need a way of displaying on the screen some instructions to tell players how to play the game. I'm not sure what kind of game I will make but I do know that I intend to use either FreeGLUT or GLFW as the library for creating a window with an OpenGL context and FTGL for rendering text to that context. At this time I still don't know of a way to load image files and display them on the screen, but that will definitely be something I want to learn before I make whatever game I do. The source code that makes the above animation is available on this page below.

main.c
makefile

However, to get the program compiled and running to create the same animation as shown in the video above, you will either need the Hack font installed or you will need to change the source code to point to whatever font you would prefer to use. The source code and makefile above could prove to be very useful because the main.c file contains everything for drawing the regular polygons and also the way of using FTGL to draw text. As usual the makefile has the right command to compile and link the source. I've tested it on both of my computers running Linux. Windows users may need a different setup.