Noah Petherbridge
215ed5c847
* The loading screen for Edit and Play modes is stable and the risk of game crash is removed. The root cause was the setupAsync() functions running on a background goroutine, and running SDL2 draw functions while NOT on the main thread, which causes problems. * The fix is all SDL2 Texture draws become lazy loaded: when the main thread is presenting, any Wallpaper or ui.Image that has no texture yet gets one created at that time from the cached image.Image. * All internal game logic then uses image.Image types, to cache bitmaps of Level Chunks, Wallpaper images, Sprite icons, etc. and the game is free to prepare these asynchronously; only the main thread ever Presents and the SDL2 textures initialize on first appearance. * Several functions had arguments cleaned up: Canvas.LoadLevel() does not need the render.Engine as (e.g. wallpaper) textures don't render at that stage. |
||
---|---|---|
.. | ||
actor_animation.go | ||
actor_collision.go | ||
actor_events.go | ||
actor.go | ||
canvas_actors.go | ||
canvas_cursor.go | ||
canvas_editable.go | ||
canvas_link_tool.go | ||
canvas_present.go | ||
canvas_scrolling.go | ||
canvas_strokes.go | ||
canvas_wallpaper.go | ||
canvas_zoom.go | ||
canvas.go | ||
scripting.go |