Monogame Freezes on GetData call

I just updated to Monogame 3.6 from 3.5 and I’ve been having issues.

First off, I can’t load Texture2D’s from a stream anymore on a separate thread. It’s not that big of an issue, but it worked before. Secondly whenever I load Textures from a stream on the UI thread, then call GetData on it, the game drawing freezes. The Update and Draw method are still called, but the device does not update the display. The Android build still works just fine. If anyone has answers it would be greatly appreciated.


I fixed this issue by getting a copy of Monogame source code and removing the UI thread check for Texture2D.GetData.

Hmm, when you run graphics operations on the UI thread, it should just execute immediately i.e. for UI thread operations it shouldn’t make a difference if that check is there. Do you know what’s different or why it might fail with the UI thread check?

I haven’t tried running it on the UI thread without the UI check, but I do know it would freeze when I call GetData from the UI thread while the check was there. Before I was doing it on a separate thread, so I just went back to that. Also, if it helps, I’m doing all of this outside of LoadContent