API reference

MetaXRAcousticMap Class

Extends MonoBehaviour
Class used to analyze the scene and generate a precomputed Acoustic Map.

Internal Fields

customPointsEnabled : bool
If enabled, the Acoustic Map will be generated using the custom points added by the user. If disabled the points will be autogenerated.
Signature
bool MetaXRAcousticMap.customPointsEnabled
DISTANCE_PARAMETER_MAX : const float
Signature
const float MetaXRAcousticMap.DISTANCE_PARAMETER_MAX
FILE_EXTENSION : const string
Signature
const string MetaXRAcousticMap.FILE_EXTENSION
The flags for how the Acoustic Map is computed.
Signature
AcousticMapFlags MetaXRAcousticMap.Flags
HeadHeight : float
The ideal height off the ground surface in meters where points should be placed. If the ceiling is shorter than this height, the point will be placed midway between the floor and ceiling.
Signature
float MetaXRAcousticMap.HeadHeight
IsLoaded : bool
Signature
bool MetaXRAcousticMap.IsLoaded
mapHandle : IntPtr
Signature
IntPtr MetaXRAcousticMap.mapHandle
MaxHeight : float
The maximum distance in meters that a point can be located off the ground if No Floating is unchecked. Any points higher than this will not be included in the scene map.
Signature
float MetaXRAcousticMap.MaxHeight
MaxSpacing : float
The maximum distance in meters that should be between points placed by the automatic scene mapping. This parameter controls the spacing between points in open areas. Setting this value lower will produce many more points in open areas. Setting this value higher will place points more sparsely. Note that creating more points does not correlate to higher quality, especially in open areas. The accurary of the simulation is usually better if the max spacing is larger as long as there is still a point in each area reachable by the play or sound sources.
Signature
float MetaXRAcousticMap.MaxSpacing
MinSpacing : float
The approximate size in meters of the smallest space where a point should be placed using the automatic mapping. This should be roughly the same as the width of the game's character controller, so that any places reachable by the player will have acoustic data points placed there. Setting this value too low will result in more points which increases the data size. Setting it too high would result in points missing from places that are reachable by the player or sound sources. Reasonable starting values are in the range 0.5 - 1.0 meters.
Signature
float MetaXRAcousticMap.MinSpacing
ReflectionCount : uint
The preprocessing parameters.
The number of early reflections that should be precomputed for each of the points. More reflections uses more memory, but would produce higher quality results. The default is 6, which is enough for one 1st-order reflection from each wall of a box-shaped room.
Signature
uint MetaXRAcousticMap.ReflectionCount
RelativeFilePath : string
Signature
string MetaXRAcousticMap.RelativeFilePath
SceneGroup : MetaXRAcousticSceneGroup
This is an optional way to incorporate multiple scenes into a single baking for large spaces that use additive scene loading for streaming geometry. If there is no scene group specified, then the map will bake the scene it's in.
Signature
MetaXRAcousticSceneGroup MetaXRAcousticMap.SceneGroup
Success : const int
Signature
const int MetaXRAcousticMap.Success

Properties

AbsoluteFilePath : string
[Get][Set]
Signature
string MetaXRAcousticMap.AbsoluteFilePath
Diffraction : bool
[Get][Set]
This control determines which diffraction method is used by the Acoustic Map. If enabled, the resulting diffraction will be higher quality at the cost of longer precompute time and greater file sizes. If disabled, the Acoustic Map will use a fallback method to compute diffraction which will have a smaller file size more efficient resource usage but will result in lower quality sound. Edge diffraction uses more memory and CPU than the other data store in the acoustic map, so it may be useful to disable it in resource-constrained applications. In order for diffraction to function in precompute mode it must be enabled on any of the geometries that you want to have sound propagate around, as well as in the MetaXRAcousticSettings (where it is on by default).
Signature
bool MetaXRAcousticMap.Diffraction
GravityVector : Vector3
[Get][Set]
Signature
Vector3 MetaXRAcousticMap.GravityVector
NoFloating : bool
[Get][Set]
If enabled, points far above the floor will not be baked into the map.
Signature
bool MetaXRAcousticMap.NoFloating
StaticOnly : bool
[Get][Set]
If enabled this causes the baking to omit any objects that are not marked as static. This can be used to include only static objects and geometry in the baked data. Dynamic objects (such as doors) will be disregarded during the bake, so that sound propagates from room to room as if the door were not there. At runtime, dynamic objects will affect direct sound occlusion, but have no impact on reflections or reverb. This option is disabled by default, meaning that all geometries are used for acoustics.
Signature
bool MetaXRAcousticMap.StaticOnly

Internal Methods

DestroyInternal ()
Signature
void MetaXRAcousticMap.DestroyInternal()
Returns
void
StartInternal ( autoLoad )
Signature
void MetaXRAcousticMap.StartInternal(bool autoLoad=true)
Parameters
autoLoad: bool
Returns
void