Why FreeImage?

Blitz3D Forums/Blitz3D Beginners Area/Why FreeImage?

Why do we use FreeImage? Would the memory automatically be destroyed when the window closes without FreeImage?

What if you want to get rid of a temporary image but don't want to end the game?

Exactly. All the "FreeSomething" commands are while you're in-game and want to spare mahmory. No need to do them as the last thing in your game, as most people do (like, a FreeAll() function, then END).

As stated/implied above, all resources used by a program are closed, destroyed, etc, automatically when the program ends.

Just to finish the subject, is there any memory resource that may be kept after the program finishes? something like a Bank, or Type, or Array?

Or is everything finished?

Everything is destroyed. There might be some data left in a cache somewhere, but that information is overwritten when nessesary.

Thank you, Ross C.

So, in fact, you don't have to create a FreeAll function to destroy all meshes, sounds, type-instances, textures, pictures, ... when you end the game?

Or does the "End" command do all that internally (frees all loaded meshes, sounds, types, ...)?

No you don't.
And we know there's like millions of people that do it...

I believe the END command does nothing other than end the program, IMO.
I think the one who purges the resources is Windows, after realising that the program has ended.

Again, up to someone with more in-depth knowledge to answer definately.