커뮤니티 Q&A

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

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

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

0 투표
I am trying to start events at a certain point, not just from the start of the sound. Is there any way to do this from UE, potentially thru some RPTC's?

 

Also curious on how to get the length of an event from in UE4.

 
Thank you!
General Discussion Evan B. (170 포인트) 로 부터

1 답변

+1 투표
 
우수 답변
Hi Evan B!

So yes.... with a little bit of hacking. You have to hack it into AKComponent. If you're savvy enough to jump into the code I can try and help you out!

 

-Rob
Robert M. (4.6k 포인트) 로 부터
선택됨 Evan B. 로 부터
Hey Robert,

Thanks for getting back to me. I would love a little help figuring this out. I was already in the AKComponent.h/cpp files, and duplicated the GetAttenuationRadius() method, changing it to GetLength(), but for some reason when I built, there were no new Blueprint nodes.

Looking forward to hearing back from ya!

Thanks
Cool. For the first problem it is probably because you did not have "blueprint callable" in the ufunction. OR you did not generate project files on your engine/project. First do those things and tell me if it works.
Hey, so definitely had blueprintcallable.

I will try generate project files, but I am pretty sure I did.

Can you explain a little how to expose seek and where the length value is stored?

I sorta have two issues, one is the blueprints not showing up, and two is not being exactly sure of where the data I need exists.

I installed via the wwise launcher, and then wwise showed up in my plugins dir, but it could potentially be using the engine version.
Try also giving the event a category as well, that could also be a reason.
So you have to write it in yourself in the AK component files. at the bottom of this message is the cpp addition I added.

The data you will need is just the ID number of the event/sound file. The function also gets fed in how long (in ms) you want to seek in the event. If you over do it you'll actually end up looping it.

 if you want the length of time that the event runs, is you'll have to parse the XML file that is created when you generate sound banks. (to enable that go to ProjectSettings> SOund banks> generate XML data)

.cpp:

void UAkComponent::Seek(int32 MilliSeconds, const FString& IDNumber)
{
    AkTimeMs MilliSec = MilliSeconds;
    AkUniqueID AkIDNumber = FCString::Atoi64(*IDNumber);
    AK::SoundEngine::SeekOnEvent(AkIDNumber, (AkGameObjectID) this, MilliSec, false, (AkPlayingID)AK_INVALID_PLAYING_ID);
}
Thank you! I will work on implementing this.

Is the length exposable from the blueprints at all? I imagine Event->Length might work?
No unfortunately not
Touching on that other issue w/ the plugin not updating the blueprints exposed, for some reason I cannot generate project files when Wwise is enabled. It throws this error:

'ERROR: Unable to instantiate instance of 'AkAudio' object type from compiled assembly 'MicrodoseVRModuleRules,'

When I disable the plugin, it works...but therein lies the problem. Any idea what may be causing this? If I install thru the Wwise launcher, doesn't it just put the plugin in my plugins directory and use that?

Thanks for your time!
Hmm I think that may be a problem with your (project).build.cs file.

PrivateDependencyModuleNames.AddRange{"AKAudio"}; should be the fix i think
I put that in there, and now I'm getting this error:

'EXEC : error : Expecting to find a type to be declared in a module rules named 'AKAudio' in MicrodoseVRModuleRules'

Any ideas? Sorry to keep coming back!
Looks like the SDK files didn't copy over properly while installing the plugin. Modified and re-did and now its working. Thank you much!
Hey, so now I can get it to build, but the updates and additions to the Wwise plugin are not showing after building/compiling. Any ideas?
does the function have a category? it won'ts how up sometimes if you dont. also generate project files.
Hey Robert, turned out I had to delete the bin and intermediate folders in the plugin directory..then it would build. thanks for all your help!

Is there any chance I could get you to show me an example (like u did above) of how to expose SetMultiplePositions()? I have been researching for weeks and cannot get it to build properly.

Thanks so much!
Unfortunately no. :( sorry mate.
.cpp:

void UAkComponent::Seek(int32 MilliSeconds, const FString& IDNumber)
{
    AkTimeMs MilliSec = MilliSeconds;
    AkUniqueID AkIDNumber = FCString::Atoi64(*IDNumber);
    AK::SoundEngine::SeekOnEvent(AkIDNumber, (AkGameObjectID) this, MilliSec, false, (AkPlayingID)AK_INVALID_PLAYING_ID);
}


Hey Robert,

sorry to come back to this, but it seems seeking is still not supported in your UE4.16 integration. What are your plans to add this to the plugin ?


Thank you,
Oliver
Hey! I actually got version frozen on .14 unfortunately so I can't help you there :/ I haven't gotten the time to check it out sorry. This was a work around that I was able to do in the code myself. I am not a dev hehe so I can't just add it in directly to the plug in
Could you elaborate on how to get this working, i tried adding this to UAkComponent:

void UAkComponent::Seek(int32 MilliSeconds, const FString& IDNumber)
{
    AkTimeMs MilliSec = MilliSeconds;
    AkUniqueID AkIDNumber = FCString::Atoi64(*IDNumber);
    AK::SoundEngine::SeekOnEvent(AkIDNumber, (AkGameObjectID) this, MilliSec, false, (AkPlayingID)AK_INVALID_PLAYING_ID);
}

And the corresponding declaration in .h and can get the function to call from BP but nothing is happening when i for example spawn an ak event, seek and then post it, or if i spawn it, post it, then seek.

I suspect there is soemthing from with the line:
AK::SoundEngine::SeekOnEvent(AkIDNumber, (AkGameObjectID) this, MilliSec, false, (AkPlayingID)AK_INVALID_PLAYING_ID);

I added UE_LOGs at AudioDevice.cpp that has some SeekOnEvents but they never get printed.
...