Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / D3D_Func d3d_font memory usage grows after set display mode

Author
Message
Ben_UK78
16
Years of Service
User Offline
Joined: 10th Jul 2010
Location:
Posted: 12th Mar 2012 00:42
Hi All,

I have a funny problem that I don't seem to be able to solve.

In my program I toggle between windowed and fullscreen. After using set window size I use set display mode. I then reload media and use d3d_init, plus reload all the d3d_fonts.
My program memory usage then increases by about 20mb.

I rem'd out all the code for loading the media and d3d and the program size remained roughly constant. I can add all the media back in and it remains roughly constant.
I then add back d3d_init and the d3d_font commands and it starts growing again by 20mb.

I can leave the d3d_init line in and the program does not grow, so it seems its all down to the 7 fonts I load.

Does anyone know whether there is a way to clear the font memory, or whether there is a precise way the fonts need loading to stop this happening? What am I doing wrong?

Login to post a reply

Server time is: 2026-07-11 02:02:48
Your offset time is: 2026-07-11 02:02:48