I’ve been developing a simple app and I’ve been struggling with using the media player. I test my app builds on Bluestacks and the app does function, but when I load it onto a device it will crash everytime the media player opens the stream.
On the Pre-launch info on the android dashboard it says that the device is running out of memory.
Issue: java.lang.OutOfMemoryError: Failed to allocate a 1048588 byte allocation with 251960 free bytes and 242KB until OOM
I know this is due to the media player as I’ve managed to isolate it by loading it manually through a button press, as it will hang on Bluestacks and then play, whilst on device it outright crashes.
Could this be to do with Garbage Collection? Has anyone encountered anything similar and managed to resolve it?
All the posts I find are mostly to do with the media textures and the solutions don’t seem to work for me.
My set up is as followed: