Cardboard使用空间音频(一)原文翻译

最近项目里要用到全景声,gvr里面的空间音频接口提供了场景声,所以研究了一下,以下是我用有道词典直接翻译的:


Using Spatial Audio
使用空间音

To get started with Google VR's spatial audio support in Unity, first add the first add theGvrAudioListener component to the same GameObject that Unity's AudioListener component is attached to. In most cases this will be the Main Camera.

开始使用谷歌虚拟现实空间音频支持的统一,首先添加第一个添加GvrAudioListener组件相同的GameObject团结的AudioListener组件相连。在大多数情况下,这将是主要的相机。

When you hit Play in the Editor, GvrAudioListener initializes the Google VR Audio system automatically.

当你在编辑器中点击播放,GvrAudioListener自动初始化谷歌VR音频系统。 

Note: For Unity 5.2+ users, you must select Gvr Audio Spatializer as the Spatializer Plugin in the Edit > Project Settings > Audio : Spatializer Plugin dropdown menu. This step is not required for users with Unity 5.1 or earlier.

注意:对于统一5.2 +用户,您必须选择Gvr音频声场定位技术的声场定位技术插件编辑>项目设置>音频:声场定位技术插件下拉菜单。这一步不需要用户提供统一5.1或更早。

Adding sources with Google VR Audio support

To add an audio source with Google VR Audio support, attach a GvrAudioSource component to a GameObject. Then, you can modify the properties of the source in similar way to Unitys AudioSource and press Play to hear the outcome immediately over headphones.

You can also add the GvrAudioSource prefab provided in the plugin package directly to your scene. This will add a GameObject with a generic GvrAudioSource attached to it.

添加资源与谷歌VR音频支持    

添加一个音频源与谷歌VR音频支持,附上GvrAudioSource GameObject组件。然后,您可以修改源的属性相似的方式统一的AudioSource和媒体发挥听到结果立即在耳机。    

您还可以添加GvrAudioSource预制提供的插件包直接向你的场景。这将添加一个GameObject附带通用GvrAudioSource

Adding room effects

The Google VR Audio system offers a sophisticated yet easy-to-use room simulation component to enhance the VR experience. In order to add a room to your project, add the GvrAudioRoom prefab to your scene. It consists of a GameObject with a generic GvrAudioRoom component attached to it.

You can also attach a GvrAudioRoom component manually to any GameObject you wish to use. To do so, select the GameObject in the Hierarchy panel, and select Add Component > Google VR > GvrAudioRoom in the Inspector panel. This component automatically takes the Transform properties of the GameObject set in the Inspector panel and simulates environmental effects accordingly. You can also adjust additional room properties to get the correct sound from a room. The GvrAudioRoom interface allows you to select surface materials which affect the sound in the scene according to their physical properties, alongside reflectivity and reverberation settings to fine tune the desired environment.

GvrAudioRoom applies the corresponding environmental effects whenever the GvrAudioListener components GameObject is inside the boundaries of the room. A yellow rectangular box Gizmo shows the adjusted boundaries of the room in the Scene view.

增加房间的效果
 
谷歌VR音频系统提供了一个复杂却又简单易用的房间模拟组件增强虚拟现实体验。为了一个房间添加到您的项目,将GvrAudioRoom组合式添加到你的场景。它由一个GameObject通用GvrAudioRoom组件连接到它。

您还可以将手动GvrAudioRoom组件附加到任何GameObject你想使用。为此,选择层次结构中的GameObject面板,并选择Add组件>谷歌VR > GvrAudioRoom检查员面板。这个组件自动将转换的属性GameObject监视器面板中设置和模拟相应的环境影响。您还可以调整额外的空间属性,得到正确的声音从一个房间。GvrAudioRoom接口允许您选择表面材料影响声音场景中根据他们的物理性质,与反射率和混响设置调整所需的环境。

GvrAudioRoom适用相应的环境影响每当GvrAudioListener组件的GameObject房间的边界内。一个黄色的矩形小发明显示了调整房间的边界在场景视图中。

Integrating Google VR Audio with an existing project

Follow the guidelines in this document.

Replace each existing AudioSource in your scene with GvrAudioSource using the Hierarchy and Inspector panels. Modify the source properties accordingly. For scripts, renaming AudioSource to GvrAudioSource should be enough.

 与现有项目整合谷歌VR音频

遵循指导方针在本文档中。
取代你的场景中每个现有AudioSource GvrAudioSource使用Hierarchyand检查员面板。相应地修改源属性。脚本,renamingAudioSource GvrAudioSource应该够了。

Note: Unity's own Reverb Zones are bypassed when you use Google VR Audio. The corresponding effect - with improved performance and realism - can be implemented by using a GvrAudioRoom.

注:统一的混响区域绕过当你使用谷歌VR音频。相应的效应——改进的性能和现实主义——可以通过使用GvrAudioRoom实现。

 

 

 

 

你可能感兴趣的:(vr)