• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

GameMaker What creates new textures?

Hello1423

Member
It seemed like I had a pretty severe memory leak, so I checked the debugger and after about a minute it's listing 2000 textures and growing. Only one of these textures has a given size (1.34 MB), but is this insane increase in the number of textures the memory leak (or at least part of it)? What creates new textures?

After reaching 1244 textures, the debugger lists a total memory use of 2683.17 MB, so I would guess that the textures aren't enough to cause that much damage, unless the reason that it doesn't list a size for almost all of the textures is because those are bigger files and they are just taking longer to scan.
 
Last edited:

Bart

WiseBart
There are only a few ways to create new textures, and they're the result of adding sprites or surfaces.
Adding fonts creates a texture page as well, if I'm not mistaken.
 

Simon Gust

Member
- creating a surface
- having a miniature texture page size
- marking every sprite use for 3D
- not deleting sprite_add() / background_add()
- not freeing surfaces but losing the refrence.
- increasing the texture border width to infinity.
 
Top