We’re seeing a significant number of errors on PS4, mostly in the form of:
Failed allocating e:\jk\workspace\Build__1.6rel__UE4Libs_PS4\lowlevel_api\src\fmod_output_software.cpp line 307. Wanted 76888 bytes, current 5651005/0
Failed allocating e:\jk\workspace\Build__1.6rel__UE4Libs_PS4\lowlevel_api\src\fmod_pluginfactory.cpp line 1298. Wanted 600 bytes, current 5689322/0
Failed allocating …\lowlevel_api\src\fmod_memory.h line 273. Wanted 1032 bytes, current 5689791/0
We figured that /0 is referring to poolmem/poollen in Memory_Initialize, but setting those variables doesn’t fix the issue. Are we using Memory_Initialize incorrectly, or is there another fix for this issue?
If you specify a pool memory pointer, it must have a length. Memory_Initialize would probably return an error if one was there without the other.
/0 to me looks like you’re not using any memory pool, and its just using the internal memory system, that is failing internally because external code is using up all of the memory?
We’ve tried setting poollen. I believe that the code we’re using is correct, but I believe the location is wrong. The Memory_Initialize documentation says that it “must be called before any FMOD System object is created”, but I don’t know when that is. If I call it too early, I get a prx error and crash. If I call it too late, it doesn’t seem to do anything. Do you know when Memory_Initialize should be called in UE4?
I recognise that this is quite old but we’ve encountered the same issue in a recent build. Is it enough to call Memory_Initialise like in the code sample below, or am I missing a vital step (or five)?
…
if (LoadLibraries())
{
FMOD_RESULT result = FMOD::Memory_Initialize(malloc(4 * 1024 * 1024), 4 * 1024 * 1024, 0, 0, 0);
// Create sandbox system just for asset loading
AssetTable.Create();
…