• Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

Windows The windowed mode texture surface is back again

  • Thread starter Deleted member 16767
  • Start date
D

Deleted member 16767

Guest
When I change to windowed mode in the paint app I made, the texture page is put on the surface again. Not sure why this has happened again. Full screen is working like easy cake.
 
Last edited by a moderator:

Nocturne

Friendly Tyrant
Forum Staff
Admin
Suggests you're not clearing the surface before drawing to it. Every time you change anything related to the window (drag, fullscreen, size, etc...) all surfaces are cleared and recreated, so they'll occupy a different space in memory each time. If you don't clear the surface after this, then it will hold whatever was in the position in memory beforehand.
 
D

Deleted member 16767

Guest
Ah, thank you.

In the create event, and it works now.

GML:
if !surface_exists(global.final_surf)
{
surface_create(room_width,room_height)
}

if surface_exists(global.final_surf)
{
    surface_free(global.final_surf)
}
 
Top