public static uint PostEvent(uint eventId, UnityEngine.GameObject gameObject, uint flags, AkCallbackManager.EventCallback callback, object cookie, uint numSources, AkExternalSourceInfo externalSources, uint playingId) { if (numSources > 1) { numSources = 1; UnityEngine.Debug.LogError("WwiseUnity: This version of PostEvent only sends 1 external source to the sound engine."); } var array = new AkExternalSourceInfoArray((int)numSources); if (numSources > 0) { array[0] = externalSources; } return(PostEvent(eventId, gameObject, flags, callback, cookie, numSources, array, playingId)); }
public static uint PostEvent(string eventName, UnityEngine.GameObject gameObject, uint flags, AkCallbackManager.EventCallback callback, object cookie, uint numSources, AkExternalSourceInfo externalSources) { if (numSources > 1) { UnityEngine.Debug.LogError("WwiseUnity: This version of PostEvent only sends 1 external source to the sound engine."); } if (numSources == 0) { return(PostEvent(eventName, gameObject, flags, callback, cookie)); } var array = new AkExternalSourceInfoArray(1); array[0] = externalSources; return(PostEvent(eventName, gameObject, flags, callback, cookie, 1, array)); }
public virtual void Dispose() { AkExternalSourceInfo info = this; lock (info) { if (this.swigCPtr != IntPtr.Zero) { if (this.swigCMemOwn) { this.swigCMemOwn = false; AkSoundEnginePINVOKE.CSharp_delete_AkExternalSourceInfo(this.swigCPtr); } this.swigCPtr = IntPtr.Zero; } GC.SuppressFinalize(this); } }
public AKRESULT Enqueue(uint in_audioNodeID, int in_msDelay, IntPtr in_pCustomInfo, uint in_cExternals, AkExternalSourceInfo in_pExternalSources) { return((AKRESULT)AkSoundEnginePINVOKE.CSharp_Playlist_Enqueue__SWIG_0(this.swigCPtr, in_audioNodeID, in_msDelay, in_pCustomInfo, in_cExternals, AkExternalSourceInfo.getCPtr(in_pExternalSources))); }
public AKRESULT Enqueue(uint in_audioNodeID, int in_msDelay, IntPtr in_pCustomInfo, uint in_cExternals, AkExternalSourceInfo in_pExternalSources) { AKRESULT ret = (AKRESULT)AkSoundEnginePINVOKE.CSharp_Playlist_Enqueue__SWIG_0(swigCPtr, in_audioNodeID, in_msDelay, in_pCustomInfo, in_cExternals, AkExternalSourceInfo.getCPtr(in_pExternalSources)); return ret; }
public AKRESULT SetExternalSources(uint in_nExternalSrc, AkExternalSourceInfo in_pExternalSrc) { AKRESULT ret = (AKRESULT)AkSoundEnginePINVOKE.CSharp_PlaylistItem_SetExternalSources(swigCPtr, in_nExternalSrc, AkExternalSourceInfo.getCPtr(in_pExternalSrc)); return ret; }
public static uint PostEvent(string in_pszEventName, UnityEngine.GameObject in_gameObjectID, uint in_uFlags, AkCallbackManager.EventCallback in_pfnCallback, object in_pCookie, uint in_cExternals, AkExternalSourceInfo in_pExternalSources) { uint tempin_gameObjectID; if ( in_gameObjectID != null ) { tempin_gameObjectID = (uint)in_gameObjectID.GetInstanceID(); // Note: if AkGameObjectTracker is already attached, the following code will be bypassed. if (in_gameObjectID.GetComponent<AkGameObject>() == null) { in_gameObjectID.AddComponent<AkGameObject>(); } } else { tempin_gameObjectID = unchecked((uint)-1); } in_pCookie = new AkCallbackManager.EventCallbackPackage(in_pfnCallback, in_pCookie); { uint ret = AkSoundEnginePINVOKE.CSharp_PostEvent__SWIG_7(in_pszEventName, tempin_gameObjectID, in_uFlags, (IntPtr)0, (IntPtr)in_pCookie.GetHashCode(), in_cExternals, AkExternalSourceInfo.getCPtr(in_pExternalSources)); return ret; } }
public static uint PostEvent(string in_pszEventName, UnityEngine.GameObject in_gameObjectID, uint in_uFlags, AkCallbackManager.EventCallback in_pfnCallback, object in_pCookie, uint in_cExternals, AkExternalSourceInfo in_pExternalSources) { AkAutoObject tempObj = null; uint tempin_gameObjectID = (uint)AutoRegisterAkGameObj(in_gameObjectID, ref tempObj); in_pCookie = AkCallbackManager.EventCallbackPackage.Create(in_pfnCallback, in_pCookie, ref in_uFlags); { uint ret = AkSoundEnginePINVOKE.CSharp_PostEvent__SWIG_7(in_pszEventName, tempin_gameObjectID, in_uFlags, in_uFlags != 0 ? (IntPtr)1 : (IntPtr)0, in_pCookie != null ? (IntPtr)in_pCookie.GetHashCode() : (IntPtr)0, in_cExternals, AkExternalSourceInfo.getCPtr(in_pExternalSources)); AkCallbackManager.SetLastAddedPlayingID(ret); return ret; } }
public static uint PostEvent(string in_pszEventName, GameObject in_gameObjectID, uint in_uFlags, AkCallbackManager.EventCallback in_pfnCallback, object in_pCookie, uint in_cExternals, AkExternalSourceInfo in_pExternalSources) { WWiseAudioBridge.Logger.Debug($"in_pszEventName = '{in_pszEventName}' in_gameObjectID = {in_gameObjectID}, in_uFlags = {in_uFlags}, in_pfnCallback = {in_pfnCallback}, in_pCookie = {in_pCookie}, in_cExternals = {in_cExternals}, in_pExternalSources = {in_pExternalSources}"); WWiseAudioBridge.Logger.Debug($"String key, patched"); var name = WWiseAudioBridge.PostEventOrReturnWWiseEventName((ID)in_pszEventName.ToLowerInvariant(), in_gameObjectID); if (name == null) { return(0); } return(orig_PostEvent(in_pszEventName, in_gameObjectID, in_uFlags, in_pfnCallback, in_pCookie, in_cExternals, in_pExternalSources)); }
public static uint PostEvent(uint in_eventID, GameObject in_gameObjectID, uint in_uFlags, AkCallbackManager.EventCallback in_pfnCallback, object in_pCookie, uint in_cExternals, AkExternalSourceInfo in_pExternalSources, uint in_PlayingID) { WWiseAudioBridge.Logger.Debug($"in_eventID = {in_eventID}, in_gameObjectID = {in_gameObjectID}, in_uFlags = {in_uFlags} in_pfnCallback = {in_pfnCallback} in_pCookie = {in_pCookie} in_cExternals = {in_cExternals} in_pExternalSources = {in_pExternalSources} in_PlayingID = {in_PlayingID}"); return(orig_PostEvent(in_eventID, in_gameObjectID, in_uFlags, in_pfnCallback, in_pCookie, in_cExternals, in_pExternalSources, in_PlayingID)); }
public AKRESULT SetExternalSources(uint in_nExternalSrc, AkExternalSourceInfo in_pExternalSrc) { AKRESULT ret = (AKRESULT)AkSoundEnginePINVOKE.CSharp_PlaylistItem_SetExternalSources(swigCPtr, in_nExternalSrc, AkExternalSourceInfo.getCPtr(in_pExternalSrc)); return(ret); }
public static uint PostEvent(string in_pszEventName, UnityEngine.GameObject in_gameObjectID, uint in_uFlags, AkCallbackManager.EventCallback in_pfnCallback, object in_pCookie, uint in_cExternals, AkExternalSourceInfo in_pExternalSources) { AkAutoObject tempObj = null; uint tempin_gameObjectID; if ( in_gameObjectID != null ) { tempin_gameObjectID = (uint)in_gameObjectID.GetInstanceID(); if (in_gameObjectID.activeInHierarchy) { if (in_gameObjectID.GetComponent<AkGameObj>() == null) { in_gameObjectID.AddComponent<AkGameObj>(); } } else { //Object not active. AkGameObj will not work. Use a temporary game object. //This will automatically unregister at the end of this scope. tempObj = new AkAutoObject(in_gameObjectID); tempin_gameObjectID = (uint)tempObj.m_id; //Silence warning } } else { tempin_gameObjectID = unchecked((uint)-1); } in_pCookie = AkCallbackManager.EventCallbackPackage.Create(in_pfnCallback, in_pCookie, ref in_uFlags); { uint ret = AkSoundEnginePINVOKE.CSharp_PostEvent__SWIG_7(in_pszEventName, tempin_gameObjectID, in_uFlags, in_uFlags != 0 ? (IntPtr)1 : (IntPtr)0, in_pCookie != null ? (IntPtr)in_pCookie.GetHashCode() : (IntPtr)0, in_cExternals, AkExternalSourceInfo.getCPtr(in_pExternalSources)); AkCallbackManager.SetLastAddedPlayingID(ret); return ret; } }
public void Clone(AkExternalSourceInfo other) { AkSoundEnginePINVOKE.CSharp_AkExternalSourceInfo_Clone(swigCPtr, AkExternalSourceInfo.getCPtr(other)); }
internal static IntPtr getCPtr(AkExternalSourceInfo obj) { return((obj != null) ? obj.swigCPtr : IntPtr.Zero); }
public static uint PostEvent(string in_pszEventName, UnityEngine.GameObject in_gameObjectID, uint in_uFlags, AkCallbackManager.EventCallback in_pfnCallback, object in_pCookie, uint in_cExternals, AkExternalSourceInfo in_pExternalSources, uint in_PlayingID) { uint tempin_gameObjectID; if ( in_gameObjectID != null && in_gameObjectID.activeInHierarchy ) { tempin_gameObjectID = (uint)in_gameObjectID.GetInstanceID(); // Note: if AkGameObjectTracker is already attached, the following code will be bypassed. if (in_gameObjectID.GetComponent<AkGameObj>() == null) { in_gameObjectID.AddComponent<AkGameObj>(); } } else { tempin_gameObjectID = unchecked((uint)-1); } in_pCookie = AkCallbackManager.EventCallbackPackage.Create(in_pfnCallback, in_pCookie, ref in_uFlags); { uint ret = AkSoundEnginePINVOKE.CSharp_PostEvent__SWIG_6(in_pszEventName, tempin_gameObjectID, in_uFlags, in_uFlags != 0 ? (IntPtr)1 : (IntPtr)0, in_pCookie != null ? (IntPtr)in_pCookie.GetHashCode() : (IntPtr)0, in_cExternals, AkExternalSourceInfo.getCPtr(in_pExternalSources), in_PlayingID); AkCallbackManager.SetLastAddedPlayingID(ret); return ret; } }
internal static IntPtr getCPtr(AkExternalSourceInfo obj) { return((obj == null) ? IntPtr.Zero : obj.swigCPtr); }
public static uint PostEvent(string in_pszEventName, UnityEngine.GameObject in_gameObjectID, uint in_uFlags, AkCallbackManager.EventCallback in_pfnCallback, object in_pCookie, uint in_cExternals, AkExternalSourceInfo in_pExternalSources) { uint tempin_gameObjectID; if ( in_gameObjectID != null ) { tempin_gameObjectID = (uint)in_gameObjectID.GetInstanceID(); // Note: if AkGameObjectTracker is already attached, the following code will be bypassed. if (in_gameObjectID.GetComponent<AkGameObject>() == null) { in_gameObjectID.AddComponent<AkGameObject>(); // Note: We have missed AkGameObject.Awake() of this run to register. // So we take over its work by inlining it here. AkSoundEngine.RegisterGameObj(in_gameObjectID, in_gameObjectID.name); //Set the original position AkSoundEngine.SetObjectPosition( in_gameObjectID, in_gameObjectID.transform.position.x, in_gameObjectID.transform.position.y, in_gameObjectID.transform.position.z, in_gameObjectID.transform.forward.x, in_gameObjectID.transform.forward.y, in_gameObjectID.transform.forward.z ); } } else { tempin_gameObjectID = unchecked((uint)-1); } in_pCookie = new AkCallbackManager.EventCallbackPackage(in_pfnCallback, in_pCookie); { uint ret = AkSoundEnginePINVOKE.CSharp_PostEvent__SWIG_7(in_pszEventName, tempin_gameObjectID, in_uFlags, (IntPtr)0, (IntPtr)in_pCookie.GetHashCode(), in_cExternals, AkExternalSourceInfo.getCPtr(in_pExternalSources)); return ret; } }
internal static HandleRef getCPtr(AkExternalSourceInfo obj) { return (obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr; }
public static extern uint orig_PostEvent(uint in_eventID, GameObject in_gameObjectID, uint in_uFlags, AkCallbackManager.EventCallback in_pfnCallback, object in_pCookie, uint in_cExternals, AkExternalSourceInfo in_pExternalSources, uint in_PlayingID);
internal static HandleRef getCPtr(AkExternalSourceInfo obj) { return((obj == null) ? new HandleRef(null, IntPtr.Zero) : obj.swigCPtr); }
internal static global::System.IntPtr getCPtr(AkExternalSourceInfo obj) { return((obj == null) ? global::System.IntPtr.Zero : obj.swigCPtr); }
internal static IntPtr getCPtr(AkExternalSourceInfo obj) { return (obj == null) ? IntPtr.Zero : obj.swigCPtr; }
public static extern uint orig_PostEvent(string in_pszEventName, GameObject in_gameObjectID, uint in_uFlags, AkCallbackManager.EventCallback in_pfnCallback, object in_pCookie, uint in_cExternals, AkExternalSourceInfo in_pExternalSources);