The current approach results in the UI thread creating a graphics device whilst the core is running, leading to races on function pointers, and potentially crashing.