#if !(UNITY_QNX) // Disable under unsupported platforms. //------------------------------------------------------------------------------ // // // This file was automatically generated by SWIG (https://www.swig.org). // Version 4.4.0 // // Do not make changes to this file unless you know what you are doing - modify // the SWIG interface file instead. //------------------------------------------------------------------------------ /// Defines a channel configuration. /// Examples: /// <code> AkChannelConfig cfg; /// /// Create a stereo configuration. /// cfg.SetStandard(AK_SPEAKER_SETUP_STEREO); /// /// Create a 7.1.4 configuration (7.1 plus 4 height channels). /// cfg.SetStandard(AK_SPEAKER_SETUP_AURO_11POINT1_740); /// or /// cfg.SetStandard(AK_SPEAKER_SETUP_DOLBY_7_1_4); /// /// Create a 3rd order ambisonic configuration. /// cfg.SetAmbisonic(16); // pass in the number of spherical harmonics, (N+1)^2, where N is the ambisonics order. /// /// Invalidate (usually means "As Parent") /// cfg.Clear();</code> public class AkChannelConfig : global::System.IDisposable { private global::System.IntPtr swigCPtr; protected bool swigCMemOwn; internal AkChannelConfig(global::System.IntPtr cPtr, bool cMemoryOwn) { swigCMemOwn = cMemoryOwn; swigCPtr = cPtr; } internal static global::System.IntPtr getCPtr(AkChannelConfig obj) { return (obj == null) ? global::System.IntPtr.Zero : obj.swigCPtr; } internal virtual void setCPtr(global::System.IntPtr cPtr) { Dispose(); swigCPtr = cPtr; } ~AkChannelConfig() { Dispose(false); } public void Dispose() { Dispose(true); global::System.GC.SuppressFinalize(this); } protected virtual void Dispose(bool disposing) { lock(this) { if (swigCPtr != global::System.IntPtr.Zero) { if (swigCMemOwn) { swigCMemOwn = false; AkUnitySoundEnginePINVOKE.CSharp_delete_AkChannelConfig(swigCPtr); } swigCPtr = global::System.IntPtr.Zero; } global::System.GC.SuppressFinalize(this); } } /// Number of channels. public uint uNumChannels { set { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_uNumChannels_set(swigCPtr, value); } get { return AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_uNumChannels_get(swigCPtr); } } /// Channel config type (AkChannelConfigType). public uint eConfigType { set { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_eConfigType_set(swigCPtr, value); } get { return AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_eConfigType_get(swigCPtr); } } /// Channel mask (configuration). public uint uChannelMask { set { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_uChannelMask_set(swigCPtr, value); } get { return AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_uChannelMask_get(swigCPtr); } } public uint uFullCfg { set { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_uFullCfg_set(swigCPtr, value); } get { return AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_uFullCfg_get(swigCPtr); } } /// Construct standard channel config from channel mask public static AkChannelConfig Standard(uint in_uChannelMask) { AkChannelConfig ret = new AkChannelConfig(AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_Standard(in_uChannelMask), true); return ret; } public static AkChannelConfig Anonymous(uint in_uNumChannels) { AkChannelConfig ret = new AkChannelConfig(AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_Anonymous(in_uNumChannels), true); return ret; } /// Construct ambisonic channel config from number of channels (NOT order) public static AkChannelConfig Ambisonic(uint in_uNumChannels) { AkChannelConfig ret = new AkChannelConfig(AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_Ambisonic(in_uNumChannels), true); return ret; } public static AkChannelConfig Object() { AkChannelConfig ret = new AkChannelConfig(AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_Object(), true); return ret; } /// Constructor. Clears / sets the channel config in "invalid" state (IsValid() returns false). public AkChannelConfig() : this(AkUnitySoundEnginePINVOKE.CSharp_new_AkChannelConfig__SWIG_0(), true) { } public AkChannelConfig(AkChannelConfig rCopy) : this(AkUnitySoundEnginePINVOKE.CSharp_new_AkChannelConfig__SWIG_1(AkChannelConfig.getCPtr(rCopy)), true) { } /// Constructor. Sets number of channels, and config type according to whether channel mask is defined or not. If defined, it must be consistent with the number of channels. public AkChannelConfig(uint in_uNumChannels, uint in_uChannelMask) : this(AkUnitySoundEnginePINVOKE.CSharp_new_AkChannelConfig__SWIG_2(in_uNumChannels, in_uChannelMask), true) { } /// Clear the channel config. Becomes "invalid" (IsValid() returns false). public void Clear() { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_Clear(swigCPtr); } /// Set channel config as a standard configuration specified with given channel mask. public void SetStandard(uint in_uChannelMask) { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_SetStandard(swigCPtr, in_uChannelMask); } /// Set channel config as either a standard or an anonymous configuration, specified with both a given channel mask (0 if anonymous) and a number of channels (which must match the channel mask if standard). public void SetStandardOrAnonymous(uint in_uNumChannels, uint in_uChannelMask) { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_SetStandardOrAnonymous(swigCPtr, in_uNumChannels, in_uChannelMask); } /// Set channel config as an anonymous configuration specified with given number of channels. public void SetAnonymous(uint in_uNumChannels) { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_SetAnonymous(swigCPtr, in_uNumChannels); } /// Set channel config as an ambisonic configuration specified with given number of channels. public void SetAmbisonic(uint in_uNumChannels) { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_SetAmbisonic(swigCPtr, in_uNumChannels); } /// Set channel config as an object-based configuration (implies dynamic number of objects). public void SetObject() { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_SetObject(swigCPtr); } /// Set channel config as the main mix channel configuration public void SetSameAsMainMix() { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_SetSameAsMainMix(swigCPtr); } /// Set channel config as the passthrough mix channel configuration public void SetSameAsPassthrough() { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_SetSameAsPassthrough(swigCPtr); } /// Returns true if valid, false otherwise (as when it is constructed, or invalidated using Clear()). public bool IsValid() { return AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_IsValid(swigCPtr); } /// Serialize channel config into a 32-bit word. public uint Serialize() { return AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_Serialize(swigCPtr); } /// Deserialize channel config from a 32-bit word. public void Deserialize(uint in_uChannelConfig) { AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_Deserialize(swigCPtr, in_uChannelConfig); } /// Returns a new config based on 'this' with no LFE. public AkChannelConfig RemoveLFE() { AkChannelConfig ret = new AkChannelConfig(AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_RemoveLFE(swigCPtr), true); return ret; } /// Returns a new config based on 'this' with no Front Center channel. public AkChannelConfig RemoveCenter() { AkChannelConfig ret = new AkChannelConfig(AkUnitySoundEnginePINVOKE.CSharp_AkChannelConfig_RemoveCenter(swigCPtr), true); return ret; } } #endif // #if !(UNITY_QNX) // Disable under unsupported platforms.