Jump to content
  • Advertisement
Sign in to follow this  
gael

Loading a font

This topic is 4554 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, I want to load a font situed in a directory called 'data/'. the D3DXCreateFont function requires a font name, not a path. How can I do to load a font from a specific directory? Thanks in advance.

Share this post


Link to post
Share on other sites
Advertisement
Bad news :(

When I use the function, my app crashes.

AddFontResource("data/AgencyB.TTF");

Any idea?

Share this post


Link to post
Share on other sites
The application freezes or simple quits when I call AddFontResource() which is documented to return an integer but when I want to check it I receive the compilator message 'void value not ignored as it ought to be'. Apparently, it returns nothing...

Share this post


Link to post
Share on other sites
The prototype in WinGDI.h definitely shows this function as returning an int. So, if you're compiler says it returns void, then you've got something wacked with your installation.

What compiler are you using?

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!