Simulating dynamic and geometry-informed early reflections with Wwise Reflect in Unreal

사운드 디자인 / 공간 음향 / Wwise에 대한 팁과 도구

 

Among the new spatial audio features introduced with Wwise 2017.1, the Wwise Reflect plug-in helps users feel the space they are in by hearing real-time computed reflections of sounds bouncing off walls and objects placed in the game. Let's take a first-person game as an example. When your character emits a sound, the sound should reflect from the walls of the room that you are in. These reflections will be different depending on the shape of the room and the position of the listener. Being far away from a wall will have a delayed reflection compared to being near it. This behavior can be simulated with the new Wwise Reflect plug-in. In this blog post, we will guide you through the steps you need to take to get an immersive acoustic rendering with Wwise Reflect using the Unreal integration and the Wwise Audio Lab (WAL).  Coming soon, WAL is a first person perspective Unreal game that let's you play and experiment with our features.

Wwise Project

In the Wwise project, we need to configure the sound effect that will be reflected from the geometry. In WAL, the first-person character carries a ball launcher. All of its sounds are in the Weapon Actor-Mixer shown in the image below. The Reflect plug-in is meant to be inserted on an Auxiliary Bus. For the weapon's sounds to be routed to the aux bus with Reflect applied, we need to enable Use game-defined auxiliary sends in the General Settings of the Property Editor.

1ActorMixerUseGameDefinedAuxSends.png

Then, we need to add an aux bus with the Reflect plug-in. In our example, the aux bus is called FirstPerson, as displayed in the image below.

2MasterMixerHierarchy.png

This aux bus needs to have Enable Positioning checked with the 2D option. Reflect already takes care of the positioning in 3D; we don't want Wwise to position it again on top of that.

3AuxBusPositioning.png

WAL

In the game, we need to specify the walls of the room where sound will be reflected. In the Unreal integration, the Surface Reflector component is used for this purpose. For your convenience, the Unreal integration also comes with the AkSpatialAudioVolume, which has this component attached; you need to have at least Enable Surface Reflectors checked. In WAL, we're going to place one of these volumes on a building called the mezzanine, depicted in the next image.

4MezzanineIntViewport.png

The mezzanine building can be easily represented with a cubic volume. Each reflective surface is numbered, as we can see more clearly in the image below. There is no surface reflector volume for the mezzanine itself yet; we will come back to it at the end of this blog.

5MezzanineIntNumbersViewport.png

In the Acoustic Surfaces section of the component, you can apply a different Acoustic Texture to each surface. Acoustic Textures are frequency-dependent absorption properties that are modeled using filters and gains. For example, reflections in a metal room won't sound the same as in a wooden room. For the time being, you can leave the Acoustic Texture at None until you are satisfied with the sound design of your early reflection. A None texture will completely reflect all frequencies of the emitted sound; no filter will be applied.

6MezzanineIntAcousticSurfaces.png

To configure the weapon to use the Reflect plug-in, we need to change the options of the AkComponent attached to the first-person character. In the component's details, under Spatial Audio, we need to add the FirstPerson aux bus to Early Reflection Aux BusYou can also change the maximum reflection order computed by the algorithm with these properties. A second-order reflection, for example, refers to a sound having bounced on two reflective surfaces. An interesting feature of the component is the Debug Draw options. Enabling one of them will let you see rays going from the component to the non-obstructed reflective surfaces on which the sound is going to be reflected. The surfaces touched by rays will also have their name show up on screen. This can really help when mixing for Reflect; it can help you see which triangles are being sent to the plug-in. More about this in the next section, where we'll present the Reflect Plug-in Editor.

7WeaponAkComponentPropertiesBP.png

In the following images, you can see first-order reflections drawn for the weapon component in the mezzanine. One image when playing, the other when viewing the player from a third-person perspective.

8DebugDrawFirstOrder2.png

9DebugDrawFirstOrder.png

Below is an example of the reflections we would get with second-order reflections.

10DebugDrawSecondOrder.png

Wwise Reflect

At this point, we can connect the game to Wwise and start the mixing. Use the Profiler layout's Voices Graph to find the FirstPerson Auxiliary Bus. If the sound you make is too short, you may need to go back in time by moving the cursor in the Performance Monitor. In the mezzanine, the WAL's graph looks something like the picture below.

11VoiceGraphWeaponFire01Mezzanine2.png

We will explain this graph in more detail in a future blog but, for now, we want to double-click the FirstPerson Auxiliary Bus, which is marked as using the Wwise Reflect Effect. This will open the Auxiliary Bus Editor and let you open the Reflect Effect Editor. We can now play with the parameters of the plug-in to get a satisfying mix for our early reflections.

As you can see in the image below, reflections in Wwise Reflect are described as image sources. An image source represents an image of the emitter positioned at equal distance behind a reflective surface; as if the surface is a mirror. A direct path between the image source and the listener crosses the wall at the exact place where the sound would have bounced. The distance of this path is also equal to the distance the sound would have travelled when bouncing off the wall before reaching the listener. The curious reader can find more information on Wwise Reflect's use of image sources in the Wwise Reflect documentation and the Wwise SDK documentation.

12WALFP1stOrderReflectEffectEditor.png

When making a sound from the weapon while being connected to the game and following capture time, you will see reflections appear in the Wwise Reflect Effect Editor's list as well as flags on the curve graph;  this means that these reflections are currently making a sound. The different columns in the list show the reflection's name, the name of the game object that emitted the sound being reflected, the texture(s) with which the emitted sound is filtered, and the total distance travelled by the sound before reaching the listener. As you can see in the image above, the name of a reflection is a concatenation of the name of the AkSpatialAudioVolume, the surface's number, and the surface's triangle number. For debugging purposes, you can also enable two other columns, the image source ID, which is unique for each reflection, and the game object ID, which can differentiate two game objects that could have the same name.

Mixing the reflections is done by changing the curves on the graph. As sound travels in space, it loses energy throughout the audio spectrum and we can model it with the Distance Attenuation (Image Source vs. Listener) curve. In our first-person example, this curve will change the volume of the reflection depending on the distance the character has with a wall of the mezzanine. In the Effect Editor's image above, the curve was changed to lower the volume of reflections when the character moves away from a wall. To model air absorption, you can tweak the Distance Low-pass Filter and Distance High-pass Filter curves. For example, they can be modified to simulate a faster attenuation for high frequencies compared to low frequencies.

To help you change the curves, you can slow down the speed of sound, which is in game units per second, to differentiate the reflection sounds from the dry sound. Reflections can also be muted or soloed by clicking the buttons in the list. These mute and solo buttons only work within the scope of this Effect ShareSet. For example, if you solo one of those reflections, you will not hear any other reflections from this aux bus, but you will still hear other sounds from other busses or aux busses. It is good practice to first solo the aux bus on which the Wwise Reflect effect is inserted and then mute or solo reflections.

While soloing the Reflect aux bus, and soloing one of the room's walls, you can move around in the game and change the curve to reflect (pun intended) the kind of distance attenuation you have in mind. Having a flag indicating the reflection's distance on the curves can really help in this process.

If there are too many reflections at the same time, or when you only want to see the soloed reflection, you can use the filtering bar. You can filter by name, game object name, texture, and even IDs. On the left of the filtering, there are mute and solo reset buttons. Sometimes, the muted or soloed reflection is not active anymore, so you can use these buttons to reset everything.

What's Next?

Now that you have a satisfying mix for early reflections, you can start adding Acoustic Textures to surfaces to create multiple variations between rooms. With 2017.1, you can use Factory Presets for Acoustic Textures. They are located in ShareSets under Virtual Acoustics.

The mezzanine's walls are all made of wood. When adding a texture on the AkSpatialAudioVolume, each texture will have a different color and the name of the texture will be printed instead of the surface's number.

13MezzanineIntWoodViewport.png

Here are some differences depending on the texture used in the mezzanine building.

Wood mezzanine

Anechoic mezzanine

Carpet mezzanine

None

Now that we have finished mixing for one room, it is time to add more rooms and volumes to our game. In the mezzanine building, we can try to add a volume for the mezzanine floor. But, as you can see, the shape of this floor cannot be represented by a simple cube. A simple solution is to add a cubic volume for most of the floor and add a trapezoidal shape for the little balcony. Only the floor surface is enabled, so that we don't get reflections from the other surfaces. The only drawback of this solution is that the balustrade won't reflect sounds. Everything depends on the needs of your game.

14MezzanineFloorVolumesViewport.png

We also added a volume around the complete building with brick textures to simulate reflections on the mezzanine building when we're outside.

15MezzanineExtViewport.png

 

In a future blog, we will cover the implementation of Wwise Reflect, how it depends on 3D busses, and how it can work together with other plug-ins.

 

Subscribe

 

Additional Resources:

Using Wwise Spatial Audio in Unreal

Wwise Reflect documentation

 

Thalie Keklikian

Software Developer R&D

Audiokinetic

Thalie Keklikian

Software Developer R&D

Audiokinetic

Thalie Keklikian is an electrical engineering graduate with a masters in general-purpose GPU computation. After optimizing image processing algorithms on GPU, she is now part of the Audiokinetic Research and Development team, implementing spatial audio solutions. Thalie enjoys gaming (from boardgames to live streaming on Twitch) and DIY projects like crafting her own cosplays.

 @thalieloz

댓글

hanson huang

September 06, 2017 at 09:18 am

Have made Wwise Reflect video tutorial?

Thalie Keklikian

September 22, 2017 at 09:37 am

We are planning some video tutorials with the Wwise Audio Lab. Stay tuned!

댓글 달기

이메일 주소는 공개되지 않습니다.

다른 글

누구나 사용할 수 있는 WAAPI - 제 1부: 개요

안녕하세요. 저는 왕양 (汪洋) 이라고 합니다 (혹은 ‘씨 예’, 溪夜라고도 불립니다). 저는 작년 하반기에 WAAPI에 대해 알게 되었습니다 (Wwise 저작 API). 저같이...

30.3.2021 - 작성자: 토마스 왕 (THOMAS WANG, 汪洋)

Wwise 2021.1에서 시도해볼 10 가지

Wwise 런처에서 Wwise 2021.1을 다운로드할 수 있게 되었다는 소식입니다. 오브젝트 기반 파이프라인, 방사 이미터(radial emitter), WAQL을 포함한 다양한...

9.6.2021 - 작성자: 매스 마라티 소노로 (MADS MARETTY SØNDERUP)

눈이 보이지 않는 사람에게 Wwise 가르치기

원거리에 있는 학생들에게 게임 오디오를 가르치는 것은 쉬운 일이 아닙니다. 앞을 보지 못하는 원거리 학생에게 게임 오디오를 가르치는 것은 심지어 더 어렵겠죠. 바로 이 과제가 저희...

15.2.2022 - 작성자: 에릭 버진스(Eric Berzins)

ReaWwise 개발 | 제 2부 - 구현

이 글은 2부작으로 제작된 블로그 시리즈의 제 2부입니다. 제 1부에서는 ReaWwise의 사전 제작에 대해 알아보았고, 제 2부에서는 이 확장의 개발에 대해 알아보게 됩니다.거의...

3.11.2022 - 작성자: 앤드류 코스타 (Andrew Costa)

대사 | Wwise와 Unreal Engine에서의 나레이션

현대 게임의 필수 요소 중 하나인 보이스오버 대사는 플레이어가 캐릭터를 특정 목소리와 연관지을 수 있을 뿐만 아니라 전반적인 억양을 통해 캐릭터의 감정을 더 잘 이해할 수 있게...

11.4.2023 - 작성자: Jake Gamelin (제이크 겜린)

올바른 코덱 선택에 대한 안내

게임 오디오에서는 항상 오디오 파일을 압축해야 했습니다. 우리가 꿈꾸는 그대로의 오디오 환경을 모두 압축되지 않은 오디오 샘플로 두기에는 여전히 디스크 공간이나 메모리가 부족하다는...

14.5.2024 - 작성자: 마튜 장 (Mathieu Jean)

다른 글

누구나 사용할 수 있는 WAAPI - 제 1부: 개요

안녕하세요. 저는 왕양 (汪洋) 이라고 합니다 (혹은 ‘씨 예’, 溪夜라고도 불립니다). 저는 작년 하반기에 WAAPI에 대해 알게 되었습니다 (Wwise 저작 API). 저같이...

Wwise 2021.1에서 시도해볼 10 가지

Wwise 런처에서 Wwise 2021.1을 다운로드할 수 있게 되었다는 소식입니다. 오브젝트 기반 파이프라인, 방사 이미터(radial emitter), WAQL을 포함한 다양한...

눈이 보이지 않는 사람에게 Wwise 가르치기

원거리에 있는 학생들에게 게임 오디오를 가르치는 것은 쉬운 일이 아닙니다. 앞을 보지 못하는 원거리 학생에게 게임 오디오를 가르치는 것은 심지어 더 어렵겠죠. 바로 이 과제가 저희...