# Possible DSP parameter data related regression in 2.02.10 and above (FMOD\_ERR\_INTERNAL)

**URL:** <https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679>\
**Category:** FMOD Engine\
**Created:** [December 27, 2022, 1:33pm UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679 "2022-12-27T13:33:27Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![someonesomewhere](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/someonesomewhere/32/4410_2.png) [@someonesomewhere](https://qa.fmod.com/u/someonesomewhere)\
**Post date:** [December 27, 2022, 1:33pm UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/1 "2022-12-27T13:33:27Z")

</div>

Hi,

I upgraded the version of FMOD to 2.02.11 in my project recently and started getting random FMOD\_ERR\_INTERNALs, and after installing various versions of FMOD it appears to be an issue introduced in 2.02.10. My code does the following:

1. Create an instance of an event with the Steam Audio spatializer effect
2. In an instance create callback, find the Steam Audio DSP and call setParameterData for the SIMULATION\_OUTPUTS parameter.
3. After playback has stopped, release the event instance.

The next time StudioSystem::update is called, it will return FMOD\_ERR\_INTERNAL and log the following:

```auto
FMOD: assertion: 'mImpl->mRefCount > 0' failed
 (C:\buildagent2\work\b8b6893b00c565e4\studio_api\src\fmod_effect.cpp:assert, 132)
FMOD: System::update returned error 28.
(C:\buildagent2\work\b8b6893b00c565e4\studio_api\src\fmod_asyncmanager.cpp:AsyncManager::asyncThreadLoop, 815)
FMOD error: An error occurred that wasn't supposed to. Contact support.

```

Additionally, this can sometimes result in a crash in StudioSystem::release when shutting down, but this doesn’t always occur.  
I’ve done a full trace log at [FMOD log - Pastebin.com](https://pastebin.com/ikbjjTJd). I’m not 100% sure that this isn’t the result of something being poorly implemented in the plugin, but after going through the source of the plugin I’m not sure how it could cause this, and versions 2.02.09 and below still work.

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [January 3, 2023, 10:47pm UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/2 "2023-01-03T22:47:01Z")

</div>

Hi,

Unfortunately, I was unable to reproduce the issue. Are you able to reproduce the issue if you try it with a different DSP? Or would it be possible to get a copy of the code uploaded to your profile?

---

<div class="post-metadata">

**Author:** ![malcolminyo](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/malcolminyo/32/4706_2.png) [@malcolminyo](https://qa.fmod.com/u/malcolminyo)\
**Post date:** [March 5, 2023, 4:42pm UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/3 "2023-03-05T16:42:37Z")

</div>

I was recently experiencing this same issue and was able to create a minimal Unity project to reproduce it. I assumed it was a but with Steam Audio, so I posted an issue to its GItHub Issues page: [[Unity + FMOD] Error when exiting Play Mode while a Steam Audio Source is attached to an FMOD Studio Event Emitter · Issue #244 · ValveSoftware/steam-audio · GitHub](https://github.com/ValveSoftware/steam-audio/issues/244)

My report from there:

Video:

[![](https://img.youtube.com/vi/Rbq3gPS47bI/maxresdefault.jpg "Steam Audio + FMOD + Unity Bug Demonstration") ](https://www.youtube.com/watch?v=Rbq3gPS47bI)

I created a minimal project using:

- Unity 2021.3.18f1
- FMOD Studio integration 2.02.12 from FMOD’s website
- Steam Audio version 4.1.3 from the GitHub releases

If the FMOD Event has the Steam Audio Spatializer attached to it, and the Steam Audio Source component is enabled on the Game Object with the FMOD Studio Event Emitter component, then an error will appear upon exiting Play Mode.

The only modification I made to any of the files was a fix for FMOD, so that it would properly recognize the phonon\_fmod plugin. I explained the fix here: [Bug with loading .bundle plugins on macOS (and the fix for it)](https://qa.fmod.com/t/bug-with-loading-bundle-plugins-on-macos-and-the-fix-for-it/19933)  
Otherwise, the files are unmodified.

The complete project (both Unity and FMOD Studio) can be downloaded here: [Steam Audio Bug Repro 2.zip - Google Drive](https://drive.google.com/file/d/1GO-QiUZTA1doE6APtlb9_RRUS-7CnChp/view?usp=sharing)

The error messages themselves, from `Editor.log`, are:

```auto
[FMOD] assert : assertion: 'mImpl->mRefCount > 0' failed
UnityEngine.StackTraceUtility:ExtractStackTrace () (at /Users/bokken/build/output/unity/unity/Runtime/Export/Scripting/StackTrace.cs:37)
UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[])
UnityEngine.Logger:Log (UnityEngine.LogType,object)
UnityEngine.Debug:LogError (object)
FMODUnity.RuntimeUtils:DebugLogError (string) (at Assets/Plugins/FMOD/src/RuntimeUtils.cs:574)
FMODUnity.RuntimeManager:DEBUG_CALLBACK (FMOD.DEBUG_FLAGS,intptr,int,intptr,intptr) (at Assets/Plugins/FMOD/src/RuntimeManager.cs:77)

(Filename: Assets/Plugins/FMOD/src/RuntimeUtils.cs Line: 574)

[FMOD] AsyncManager::asyncThreadLoop : System::update returned error 28.
UnityEngine.StackTraceUtility:ExtractStackTrace () (at /Users/bokken/build/output/unity/unity/Runtime/Export/Scripting/StackTrace.cs:37)
UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[])
UnityEngine.Logger:Log (UnityEngine.LogType,object)
UnityEngine.Debug:LogError (object)
FMODUnity.RuntimeUtils:DebugLogError (string) (at Assets/Plugins/FMOD/src/RuntimeUtils.cs:574)
FMODUnity.RuntimeManager:DEBUG_CALLBACK (FMOD.DEBUG_FLAGS,intptr,int,intptr,intptr) (at Assets/Plugins/FMOD/src/RuntimeManager.cs:77)

(Filename: Assets/Plugins/FMOD/src/RuntimeUtils.cs Line: 574)

```

I hope this is able to help with diagnosing and fixing the issue!

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [March 9, 2023, 4:02am UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/4 "2023-03-09T04:02:27Z")

</div>

Hi,

Thank you for such detailed findings and a project. We really appreciate it. I have passed this onto our development team to look into further. If there is any progress I will let you know.

---

<div class="post-metadata">

**Author:** ![malcolminyo](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/malcolminyo/32/4706_2.png) [@malcolminyo](https://qa.fmod.com/u/malcolminyo)\
**Post date:** [March 9, 2023, 4:10am UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/5 "2023-03-09T04:10:43Z")

</div>

Thanks for the response! 😃

---

<div class="post-metadata">

**Author:** ![dquartz](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/dquartz/32/4978_2.png) [@dquartz](https://qa.fmod.com/u/dquartz)\
**Post date:** [May 2, 2023, 7:34pm UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/6 "2023-05-02T19:34:53Z")

</div>

FWIW, I am also seeing this in Unreal when using `setParameterData` on the “Resonance Audio Listener” DSP unit. In my case, I am searching for the DSP every frame by iterating over all loaded banks and busses until I find it, and then configuring a `vraudio::RoomProperties` variable and passing it to `setParameterData`. If this is caused by trying to set the parameter while the DSP is in the process of being destroyed, what would be a good way to determine that state since DSP doesn’t have an `isValid` method?

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [May 4, 2023, 3:02am UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/7 "2023-05-04T03:02:20Z")

</div>

Hi,

Are you using the same version of FMOD?

You can check the result of the FMOD functions using `FMOD_RESULT` which provides useful debug information. The result we are looking for is `FMOD_ERR_INVALID_HANDLE` which lets us know the DSP is no longer valid.

```auto
FMOD_RESULT result = myDsp.setParameterData()

```

What is happening in your game for you to receive the assertion?

---

<div class="post-metadata">

**Author:** ![dquartz](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/dquartz/32/4978_2.png) [@dquartz](https://qa.fmod.com/u/dquartz)\
**Post date:** [May 4, 2023, 6:22pm UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/8 "2023-05-04T18:22:58Z")

</div>

We are using 2.02.13. I don’t check the result of calling `setParameterData` because I call it more or less immediately after retrieving it from the bus ChannelGroup, but I will add a check and see if the result changes from FMOD\_OK before seeing the assertions.

In our game, I am configuring the room dynamically and updating the DSP. When exiting PIE I see the assertion and people running Release Editor builds experience a crash. This happens even if I disable updating the DSP before exiting PIE.

---

<div class="post-metadata">

**Author:** ![dquartz](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/dquartz/32/4978_2.png) [@dquartz](https://qa.fmod.com/u/dquartz)\
**Post date:** [May 4, 2023, 6:51pm UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/9 "2023-05-04T18:51:00Z")

</div>

I wrapped the `setParameterData` call in `verifyfmod` and do not see any warnings/errors logged from that call when exiting PIE.

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [May 5, 2023, 1:16am UTC](https://qa.fmod.com/t/possible-dsp-parameter-data-related-regression-in-2-02-10-and-above-fmod-err-internal/19679/10 "2023-05-05T01:16:35Z")

</div>

Thank you for confirming. We are currently working on the issue and it is targeted to be released with the next update. I will post here if there is any progress.
