커뮤니티 Q&A

Audiokinetic의 커뮤니티 Q&A 포럼에 오신 것을 환영합니다. 이 포럼은 Wwise와 Strata 사용자들이 서로 도움을 주는 곳입니다. Audiokinetic의 직접적인 도움을 얻으려면 지원 티켓 페이지를 사용하세요. 버그를 보고하려면 Audiokinetic 런처에서 Bug Report 옵션을 사용하세요. (Q&A 포럼에 제출된 버그 보고는 거절됩니다. 전용 Bug Report 시스템을 사용하면 보고 내용이 담당자에게 정확히 전달되어 문제 해결 가능성이 크게 높아집니다.)<segment 6493>

빠르고 정확한 답변을 얻으려면 질문을 올릴 때 다음 팁을 참고하세요.

  • 구체적인 내용을 적어주세요: 무엇을 하려는지, 혹은 어떤 특정 문제에 부딪혔는지 설명하세요.
  • 핵심 정보를 포함하세요: Wwise와 게임 엔진 버전, 운영체제 등 관련 정보를 함께 제공하세요.
  • 시도한 방법들을 알려주세요: 문제 해결을 위해 이미 어떤 단계를 시도해봤는지 설명해주세요.
  • 객관적인 사실에 초점을 맞추세요: 문제의 기술적 사실을 중심으로 설명하세요. 문제에 집중할수록 다른 사람들이 더 빠르게 해결책을 찾을 수 있습니다.

+1 투표
I have a character that has ambient sounds come from them. Unfortunately these, and all other sounds, stop when leaving a level streaming volume in UE4. The stop all event is called.  Where can we intercept this and make it so that the stop all function is not called? Or a way that we can change it, that if a level is unloaded/destroyed in this fashion?

 

-Rob
General Discussion Robert M. (4.6k 포인트) 로 부터
수정 Robert M. 로 부터

2 답변

+3 투표
Hi Rob, i'm having a similar issue. What i found out is that AkAudioDevice registers to the LevelRemovedFromWorld callback. If this callback is called, AkAudioDevice will call its flush method and, like you said, will call StopAll from wwise api.

In our case, we are streaming levels when moving forward in the map. When the streaming happens, the callback gets called.

I didn't find any solution for our specific case. I might try filtering the Flush method if some specific levels are removed but not all.

I would be curious to know if you found any solution to your problem.

Cheers,
Francois P. (200 포인트) 로 부터
We ran into a similar problem and had to comment out the implementation of FAkAudioDevice::OnLevelRemoved to avoid the unwanted StopAll calls interfering with, say, looping ambient sounds as various unrelated sub-levels were loaded and unloaded into the main level.  Rather, we called Flush directly from higher-level logic in our game module explicitly associated with the main level unload.  Game-specific to be sure, but equivalent to Fracois’ suggestion of adjusting OnLevelRemoved’s behaviour dependent on Inlevel.
+1 투표
void FAkAudioDevice::OnLevelRemoved(ULevel* InLevel, UWorld* InWorld)
{
    if (InLevel && InLevel->IsPersistentLevel())
    {
        Flush(NULL);
    }
}

 

 

Hey guys ^ that is the code my programmer was able to implement in akaudiodevice.cpp. He just recently learned about level unloading and loading so was finally able to help me out on this one. But this code basically checks if the level is the main persistent level. If so then unload, if not then don't unload. This has one draw back though, certain sounds say like ambient sounds in a room that should not continue on in another room do not turn off. So you will just have to create a custom BP to take care of that for you so you don't overload the system.

 

-Rob
Robert M. (4.6k 포인트) 로 부터
Thanks for following up Robert. This should do the trick. On our side, we simply removed the flush since they were no drawback of doing so in the context of our game.
Thanks for the follow up Robert as I just discovered this today.

Sadly I haven't got time to dig more into this to see how it's should be properly be used.
Hi there, we are in 2022, am I wrong saying this issue is still true ? I have the exact same issue and can't figure out other solution than maybe adding this piece of code...
In our system, we could see that this bug was fixed in 2016.1.2 as "WG-30304 Fixed: "Unload stream level" no longer posts a global "Stop All" to the SoundEngine."
https://www.audiokinetic.com/library/2019.2.14_7616/?source=UE4&id=releasenotes_2016_1_2.html
If you are encountering this issue, you might be facing a different issue or this issue came back as a side-effect of other changes. You can report the issue through a Bug Report (https://www.audiokinetic.com/library/edge/?source=InstallGuide&id=reporting_bugs) where you can share how you reproduce the issue and which versions of the product you are using.
...