EndGraphics
Parameters
| None. |
Description
|
Closes the current graphics mode and returns to the small default window. This puts the program back in the state it starts up in, before any Graphics call - a plain 400x300 window. It is rarely needed: to change resolution or switch between fullscreen and windowed you can simply call Graphics again with new settings, which replaces the display in one step. Like Graphics, EndGraphics rebuilds the display, so all loaded images are freed and any image handles you were holding become invalid. Reload what you need afterwards. See also: Graphics, Graphics3D. |
Example
; EndGraphics Example ; ------------------- Graphics 640,480,0,2 SetBuffer BackBuffer() x=0 While Not KeyHit(57) Cls ; A moving box makes it obvious we are in graphics mode x=(x+2) Mod 640 Rect x,220,40,40,1 Text 0,0,"Currently in graphics mode" Text 0,20,"Space: return to non-graphics mode with EndGraphics" Flip Wend ; Close the graphics display and return to the start-up console state EndGraphics Print "EndGraphics called - back in the non-graphics start-up state." Print "" Print "Press any key to close the example" WaitKey End
Index