Forums - 3D Audio Plugin for Unity is Now Available!

16 posts / 0 new
Last post
3D Audio Plugin for Unity is Now Available!
ToolsPM
Join Date: 15 Feb 13
Posts: 386
Posted: Thu, 2018-02-01 14:35

We're pleased to announce that our 3D Audio Plugin for Unity is Now Available! You can learn more about it and request access to it here: 

https://developer.qualcomm.com/software/3d-audio-plugin-unity

Please post any questions you have on this Plugin here in this forum. Thanks. 

- Rick

  • Up0
  • Down0
ramani.d
Join Date: 20 Feb 16
Posts: 1
Posted: Thu, 2018-03-01 12:52

Is there a simple sample project? Thanks.

  • Up0
  • Down0
ToolsPM
Join Date: 15 Feb 13
Posts: 386
Posted: Thu, 2018-03-01 14:36

If you can direct message me with your email, we'll send you a simple project you can test with. 

Keep in mind missing any of the steps below could result in silence:

  1. “Go to the Project Settings in the Edit menu and select Audio.  Now, select the Q3D Audio Spatializer Plugin for sound objects, and Ambisonic Decoder Plugin for soundfields.”
  2. “Then, place a Q3DAudioListener on the same object that has your AudioListener.”

-Rick

  • Up0
  • Down0
colburn
Join Date: 28 Sep 18
Posts: 4
Posted: Mon, 2018-10-29 15:59

I'm finding that this plugin does not work for Unity 2018.3.1. Once I change the audio settings, no sound is produced. My original project was built in 2017 which worked fine. Anyone else have this experience with 2018?

  • Up0
  • Down0
nfrost Moderator
Join Date: 10 Apr 18
Posts: 6
Posted: Fri, 2019-05-03 14:10

Apologies for the very late reply, but we just released version 1.1, which has been tested on Unity 2018.x.  The download link has been updated to point to the latest: https://developer.qualcomm.com/download/software/3daudio-unity/3d-audio-...

Release notes:

https://developer.qualcomm.com/software/3d-audio-plugin-unity/release-notes

Supports Unity 2018.x (tested on 2018.3.9f1)
Allow user to specify preference for reverb processor from both the command line and in the Editor
Fixed bug where 32 samples of silence was sometimes inserted in the middle of the second 256 sample block of a sound
Reverb is now never processed if wetmix=0, saving up to ~1ms per audio frame on 845 (with reverb on CDSP) on the (recommended) Best Latency setting
Reverb default settings are now correctly set when pushing "play" in the Editor rather than often keeping previous settings
Fixed typos in tooltips
Miscellaneous, minor CPU performance optimization
* Various spurious asserts in debug/logging builds fixed
 
  • Up0
  • Down0
colburn
Join Date: 28 Sep 18
Posts: 4
Posted: Tue, 2019-06-11 16:02

I have installed the latest version 1.1 and yes it does work with Unity 2018.4. 

What does not work is the reverb room. I thought maybe the way I was trying to implement it was making it not work, but I tried just a new unity project, followed the direction of setting up the audio listener, dummy audio sources, custom mixer and reverb room and it just doesn't process the reverb. it is always dry.

  • Up0
  • Down0
nfrost Moderator
Join Date: 10 Apr 18
Posts: 6
Posted: Tue, 2019-06-11 16:49

Hi colburn,

Sorry it's not working out the box; let's try to get to the bottom of it!

 
A few things come to mind:
* sound objects are the only things that get affected by reverb -- reverb doesn't support Ambisonic soundfields
* your reverb settings may not be audibly different from a dry source; here's some obvious settings to make sure the signal processing is happening(1)
* it's possible the Audio Listener's position isn't within the radius of the Audio Reverb Zone that the Q3D Audio Room is attached to, so reverb isn't being activated
 
You could also try setting the default reverb parameters on the Q3DAudioObjectOut mixer effect to the obvious parameters(1) just to make sure reverb is processing (regardless of Audio Reverb Zone and Listener positions).
 
Another debugging option is to create a Q3DAudioGlobalSettings object and check "Log on Android" and deploy, and make sure you get something like this(2) in your adb log.  (Feel free to message me with your log if it looks suspicious).
 
Finally, if you give me an email I could send you a 2018.3.9f1 sample project that works on my Snapdragon 845 and Windows 7 machine.
 
Let me know what you think!
 
 
(1)
Gain=1
TimeAdjust=0.4
BrightAdjust=2.5
WetMix=881
RoomDimensionsX_meters=32.6
RoomDimensionsY_meters=4.28
RoomDimensionsZ_meters=15.4
RoomMaterialWalls=BRICK_BARE
RoomMaterialCeiling=CONCRETE_BLOCK_PAINTED
RoomMaterialFloor=METAL
 
(2)
Line 378: 06-11 23:18:33.998  5758  5803 I VRAudio:ShoeboxWrapper: ShoeboxEffectModuleRemote::Init sam_shoebox_driver_open success for cdsp domain
Line 379: 06-11 23:18:33.998  5758  5803 I VRAudio:ShoeboxWrapper: ShoeboxEffectModuleRemote::Init enabling remote_handle64_control latency success
Line 380: 06-11 23:18:33.998  5758  5803 I q3d_audio C++: ShoeboxEffectModule::Init()=0 (0 means success)
Line 381: 06-11 23:18:33.998  5758  5803 I q3d_audio C++: GetShoeboxEffectModuleHandle(2) returned 0xdee97c00->ShoeboxEffectModule::Init()=0 (0 means success)
Line 381: 06-11 23:18:33.998  5758  5803 I q3d_audio C++: GetShoeboxEffectModuleHandle(2) returned 0xdee97c00->ShoeboxEffectModule::Init()=0 (0 means success)
Line 382: 06-11 23:18:33.999  5758  5803 I q3d_audio C++: SAMcall: 0xdee97c00->ShoeboxEffectModule::EnableModule(1)=0
Line 384: 06-11 23:18:33.999  5758  5803 I q3d_audio C++: SAMcall:0xdee97c00->ShoeboxEffectModule::SetRoomReverbAdjustments(gain=0.000000,timeAdjust=0.000000,brightnessAdjust=0.000000,wetMix=0)=0
Line 385: 06-11 23:18:33.999  5758  5803 I q3d_audio C++: SAMcall: 0xdee97c00->ShoeboxEffectModule::SetRoomProperties(roomDimensions=[0.000000,0.000000,0.000000],roomMaterials=[0,0,0])=0
Line 387: 06-11 23:18:34.000  5758  5803 I q3d_audio C++: SAMcall:0xdee97b80->ShoeboxEffectModule::SetRoomReverbAdjustments(gain=0.000000,timeAdjust=0.000000,brightnessAdjust=0.000000,wetMix=0)=0
Line 388: 06-11 23:18:34.000  5758  5803 I q3d_audio C++: SAMcall: 0xdee97b80->ShoeboxEffectModule::EnableModule(0)=0
Line 389: 06-11 23:18:34.000  5758  5803 I q3d_audio C++: SAMcall:0xdee97b80->ShoeboxEffectModule::SetRoomReverbAdjustments(gain=0.000000,timeAdjust=0.000000,brightnessAdjust=0.000000,wetMix=0)=0
Line 391: 06-11 23:18:34.001  5758  5803 I q3d_audio C++: SAMcall:0xdee97b80->ShoeboxEffectModule::SetRoomReverbAdjustments(gain=0.000000,timeAdjust=0.000000,brightnessAdjust=0.000000,wetMix=0)=0
Line 392: 06-11 23:18:34.001  5758  5803 I q3d_audio C++: SAMcall: 0xdee97b80->ShoeboxEffectModule::SetRoomProperties(roomDimensions=[199.000000,19.000000,99.000000],roomMaterials=[0,0,0])=0
Line 394: 06-11 23:18:34.003  5758  5803 I q3d_audio C++: SAMcall: 0xdee97b80->ShoeboxEffectModule::SetRoomProperties(roomDimensions=[199.000000,19.000000,99.000000],roomMaterials=[0,0,0])=0
Line 423: 06-11 23:18:34.077  5758  5803 I q3d_audio C++: SAMcall:0xdee97b80->ShoeboxEffectModule::SetRoomReverbAdjustments(gain=1.000000,timeAdjust=0.400000,brightnessAdjust=2.500000,wetMix=791)=0
Line 424: 06-11 23:18:34.077  5758  5803 I q3d_audio C++: SAMcall: 0xdee97b80->ShoeboxEffectModule::EnableModule(1)=0
Line 425: 06-11 23:18:34.077  5758  5803 I q3d_audio C++: SAMcall: 0xdee97b80->ShoeboxEffectModule::SetRoomProperties(roomDimensions=[32.599998,4.280000,15.400000],roomMaterials=[2,5,13])=0
 
  • Up0
  • Down0
colburn
Join Date: 28 Sep 18
Posts: 4
Posted: Wed, 2019-06-12 13:23

Success! The key thing was the settings themselves. I have a few questions though. On the Q3DAudioObjectOut script, I understand Gain. The time adjust I understand too that it makes a longer reverb tail, but the Bright Adjust is puzzling. It says that it's the ratio across high and low frequencys. I would assume that if I want an even spread, I would choose 0, but that setting seems to remove the reverb. I then tried 1, thinking a 1:1 ratio and that seems too long. My project has a room that is 4x4x3 with drywall walls, acoustic ceiling and carpet floor. Qualcomm doesn't have a carpet preset, so I opted for curtain heavy. I know the rt60 of this room is .25 seconds. I'm trying to duplicate that. Given this information, what ratio should be set on bright adjust and also, what wet/dry mix would be appropriate?

also on the same script, What is the meaning of the material number zero through 22 and how to they relate to the material presets? For example, if i chose dry wall for teh walls on the audio room object, what is it's equivalent number for RoomMatWalls in the Mixer?

 

 

 

 

 

 

 

 

 

 

  • Up0
  • Down0
nfrost Moderator
Join Date: 10 Apr 18
Posts: 6
Posted: Fri, 2019-06-14 19:21

Good questions; colburn -- I asked our reverb dev for more information, and here's what she said:

BrightnessAdjust adjusts the ratio between High Frequency (~5kHz) reverb level/decay time vs. the low frequencies. If it is set to 1.0, that means the high frequencies' reverb effect/decay time is identical to the low frequencies. If it's set to 0, then there is almost no reverb effect/decay-time on the high frequencies.

(I've asked for a more precise description of what's considered "high frequencies" and whether the reverb effect is a hard cutoff or a smooth curve across frequencies, and I'll reply here when I get that information. Also, that means that the maximum value for Brightness should be 1.0 -- I'll fix this in the next release, and insert more information into the Brightness tooltip as well).

WetMix is a linear function that defines the mix ratio between dry and wet sound. A value of 0 results in dry signal only, while 1000 results in wet/reverb signal only -- 500 results in 50% wet, 50% dry, and so on.

The material number floating point values get rounded down to integers that correspond to the values from the vr_audio_room_material_type enum defined in YourProject/Assets/Q3DAudio/Q3DAudioRoom.cs; this interface is sadly a limitation of the Unity Editor. (So for example, any value from 2.0 to 2.9999 means VR_AUDIO_MATERIAL_BRICK_BARE, any value from 3.0 to 3.99999 means VR_AUDIO_MATERIAL_BRICK_PAINTED, and so on). I will insert this information into the tooltip for the next release, though.

Thanks very much for the feedback; it makes the tool better!

  • Up0
  • Down0
colburn
Join Date: 28 Sep 18
Posts: 4
Posted: Mon, 2019-06-17 10:46

Thanks for the response. based on what you are saying the following chart would correct to select the different material.

 

0 = Transparent
1 = Acoustic Ceiling Tiles
2 = Brick Bare
3 = Brick Painted
4 = Concrete Block Coarse
5 = Concrete Block Painted
6 = Curtain Heavy
7 = Fiber Glass Insulation
8 = Glass Thick
9 = Glass Thin
10 = Grass
11 = Linoleum On Concrete
12 = Marble
13 = Metal
14 = Parquet On Concrete
15 = Plaster Rough
16 = Plaster Smooth
17 = Plywood Panel
18 = Polished Concrete or Tile
19 = Sheet Rock
20 = Water or Ice Surface
21 = Wood On Ceiling
22 = Wood Panel

  • Up0
  • Down0
nfrost Moderator
Join Date: 10 Apr 18
Posts: 6
Posted: Mon, 2019-06-17 11:10

Yes, your table looks correct.

In continued conversations with the author of our reverb module, the WetMix is a simple linear function (so 500 means half dry, half wet, and so on) -- I edited my previous responese to include that fact.

She's looking into whether or not our reverb makes it possible to dial in a specific rt60 value and I'll let you know if I learn more -- but I suspect you'll need to approximate the effect through trial and error, which obviously isn't ideal.  (I can't promise we'll add a "dial-in-an-rt60 value" feature, but I can promise that I'll try to convince the right folks next chance I get!)

Thanks again, and let me know if you want to continue the conversation!

  • Up0
  • Down0
synthercat
Join Date: 27 Oct 19
Posts: 1
Posted: Thu, 2019-12-05 03:12

Hello there, I just realized that my requested version was 1.1 but right now there as a 1.2 version out there. Do I need to go through the whole request 3d audio plugin for Unity process again? Will I need to do that for every update too?

 

Thank you for your time.

  • Up0
  • Down0
nfrost Moderator
Join Date: 10 Apr 18
Posts: 6
Posted: Thu, 2019-12-05 14:16

Version 1.2 is downloadable here:

https://developer.qualcomm.com/download/software/q3daudio.1.2.unitypackage

Release notes:

https://developer.qualcomm.com/software/3d-audio-plugin-unity/release-notes

  • Unity 5.x supported again out of the box (1.1 broke this). This was tested on 5.2.0f3, the earliest Unity version that supports spatialization plugins
  • q3d_audio_update_1.2.bat now works out of the box (1.1 only worked with tedious user-path creation)
  • logarithmic falloff is now the default for sound objects, not linear (to mirror Unity's defaults)
  • Brightness parameter is now normalized between 0 and 1 (which is what the underlying code expects)
  • Additional in-Editor tooltips for clarity
  • Up0
  • Down0
nfrost Moderator
Join Date: 10 Apr 18
Posts: 6
Posted: Thu, 2019-12-05 14:21

synthercat,

Thanks for reminding me to post the 1.2 download link, and apologies for neglecting to do so earlier!

I believe you need to sign up only once, and can then freely access all version download links - which I ought to post in a more timely fashion.

 

Let me know if you run into any other trouble, and thanks again for the note!

Cheers,

Nathan

  • Up0
  • Down0
alferd.tyson
Join Date: 13 Aug 20
Posts: 1
Posted: Thu, 2020-08-13 04:47

we are happy to see this new! please add any projects as example.

  • Up0
  • Down0
robinhofficial
Join Date: 22 Mar 23
Posts: 1
Posted: Wed, 2023-03-22 03:29

The reverb room is what doesn't work. I experimented with a brand-new Unity project and followed the instructions for setting up the audio listener, dummy audio sources, custom mixer, and reverb room, but it just doesn't process the reverb. At first, I thought maybe the way I was trying to implement it was making it not work. It's always been dry.

  • Up0
  • Down0
or Register

Opinions expressed in the content posted here are the personal opinions of the original authors, and do not necessarily reflect those of Qualcomm Incorporated or its subsidiaries (“Qualcomm”). The content is provided for informational purposes only and is not meant to be an endorsement or representation by Qualcomm or any other party. This site may also provide links or references to non-Qualcomm sites and resources. Qualcomm makes no representations, warranties, or other commitments whatsoever about any non-Qualcomm sites or third-party resources that may be referenced, accessible from, or linked to this site.