SDL ttf
SDL_ttf | |
---|---|
Library project | |
Developer | Sam Lantinga |
Released | |
Updated | 2.0 |
Status | Stable |
Licensing | |
P. Language | |
Platforms | Windows, Linux |
Dependencies | SDL,FreeType |
Official site of SDL_ttf |
- This page is a stub. Please help RogueBasin by expanding it. Click here to edit this page.
About SDL_ttf
SDL_ttf is an SDL project allowing for display and manipulation of true type fonts.
Creating a SDL_ttf project with VC++
1. Add a "main.c" (or whatever) file and copy a simple SDL program into it. (e.g. the demonstration code here).
2. This requires SDL to be installed and linked to your project.
See SDL pages for details.
3. Download SDL_ttf-devel-2.0.9-VC8.zip and unzip.
4. The 'include' directory needs to be added to "Additional Include Directories".
Rather then add another directory I copied the contents of the SDL_ttf include directory to "C:\p\include" (See SDL instructions).
5. The 'lib' directory needs to be added to "Additional Library Directories".
Rather then add another directory I copied the contents of the SDL_ttf lib directory to "C:\p\include" (See SDL instructions).
6. SDL_ttf.lib needs to be added to the "Additional Dependencies".
See "Project -> Properites -> Linker -> Additional Dependencies".
7. Any font required needs to be in the project folder (e.g. "CircleOfDust.ttf" for the demo code linked above).
8. Compile and run the project.
N.B. The demo code linked above a) Needs CircleOfDust passed to it as a command line argument and b) Is buggy. Use better demo code if you can find it. ;-)