SynthComponent does not execute OnStop() after calling Stop().
OnStop() will be called in PumpPendingMessages() via OnGeneratePCMAudio(). But after stopping the AudioComponent, the procedural SoundWave won't call GeneratePCMAudio() anymore. Therefore, the pending ESynthEvent::OnStop will be executed only after Starting TimeSynth again. As a sideeffect "bIsSynthPlaying" will stay true indefinitely.
User suggested fix: To prevent this, we could use OnEndGenerate() only to set bIsSynthPlaying, and maybe remove OnStop(). Because procedural USoundWave does not have an OnStop() function which will be called before OnEndGenerate().
Synth Example Project has been attached for repro sample.
[Link Removed]
Result:: in some cases when Stop() internally calls AudioComponent->Stop(), OnGenerateAudio won't pump pending messages in Time. In this case you will see:
Start() OnStart() Stop() Start() OnStop() OnStart()
Expected: The following sequence in the Output log:
Start() OnStart() Stop() OnStop()
Note: (Please see attached mp4 for more details)
I am not able to find world outliner how to enable it?
Undefined sysmbol: typeinfo for AActor when cross-compile linux dedicated server on windows
How can i modify the param name in EQS node
Delay nodes occasionally don't fire the "Completed" output in a nativized build
How does TextureRenderTarget2D get TArray<uint8> type data?
How to achieve HLSL Multiple Render Target in Material blueprints?
What method is used to fill polygonal regions when drawing spline mesh at run time?
How to delete some elements correctly when deleting an array loop?
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-85093 in the post.