/// <summary> /// Assigns a session to a grouping of sessions. /// <seealso cref="GroupingParam"/> /// </summary> /// <param name="groupingParam"></param> /// <param name="eventContext"></param> /// <returns>HRESULT</returns> /// <remarks>For some more information about grouping parameters, see <see href="http://msdn.microsoft.com/en-us/library/windows/desktop/dd370848(v=vs.85).aspx"/>.</remarks> public unsafe int SetGroupingParamNative(Guid groupingParam, Guid eventContext) { return(InteropCalls.CallI(UnsafeBasePtr, &groupingParam, &eventContext, ((void **)(*(void **)UnsafeBasePtr))[9])); }
/// <summary> /// Indicates whether the session is a system sounds session. /// <seealso cref="IsSystemSoundSession"/> /// </summary> /// <returns>HRESULT; S_OK = true, S_FALSE = false</returns> public unsafe int IsSystemSoundSessionNative() { return(InteropCalls.CallI(UnsafeBasePtr, ((void **)(*(void **)UnsafeBasePtr))[15])); }
/// <summary> /// Enables or disables the default stream attenuation experience (auto-ducking) provided by the system. /// </summary> /// <param name="enableSystemAutoDucking">A <see cref="NativeBool"/> variable that enables or disables system auto-ducking.</param> /// <returns>HRESULT</returns> public unsafe int SetDuckingPreferenceNative(NativeBool enableSystemAutoDucking) { return(InteropCalls.CallI(UnsafeBasePtr, enableSystemAutoDucking, ((void **)(*(void **)UnsafeBasePtr))[16])); }
/// <summary> /// Deletes the registration of a notification interface that the client registered in a previous call to the <see cref="RegisterEndpointNotificationCallback"/> method. /// </summary> /// <param name="notificationClient">Implementation of the <see cref="IMMNotificationClient"/> which should be unregistered from any notifications.</param> /// <returns>HRESULT</returns> public unsafe int UnregisterEndpointNotificationCallbackNative(IMMNotificationClient notificationClient) { return(InteropCalls.CallI(UnsafeBasePtr, notificationClient, ((void **)(*(void **)UnsafeBasePtr))[7])); }
/// <summary> /// The ReleaseBuffer method releases the buffer. For more information, see <see href="http://msdn.microsoft.com/en-us/library/dd370861(v=vs.85).aspx"/>. /// </summary> /// <param name="framesRead"> /// The number of audio frames that the client read from the /// capture buffer. This parameter must be either equal to the number of frames in the /// previously acquired data packet or 0. /// </param> /// <returns>HRESULT</returns> public unsafe int ReleaseBufferNative(int framesRead) { return(InteropCalls.CallI(UnsafeBasePtr, framesRead, ((void **)(*(void **)UnsafeBasePtr))[4])); }
/// <summary> /// Decrements, by one step, the volume level of the audio stream /// that enters or leaves the audio endpoint device. /// </summary> /// <param name="eventContext">EventContext which can be accessed in the event handler.</param> /// <returns>HRESULT</returns> public unsafe int VolumeStepDownNative(Guid eventContext) { return(InteropCalls.CallI(UnsafeBasePtr, &eventContext, ((void **)(*(void **)UnsafeBasePtr))[18])); }
/// <summary> /// Registers a client's notification callback interface. /// </summary> /// <param name="notificationClient">Implementation of the <see cref="IMMNotificationClient"/> which is should receive the notificaitons.</param> /// <returns>HRESULT</returns> public unsafe int RegisterEndpointNotificationCallbackNative(IMMNotificationClient notificationClient) { int result = InteropCalls.CallI(UnsafeBasePtr, notificationClient, ((void **)(*(void **)UnsafeBasePtr))[6]); return(result); }
/// <summary> /// Sets the normalized, audio-tapered volume level /// of the specified channel in the audio stream that enters or leaves the audio endpoint /// device. /// </summary> /// <param name="level"> /// The volume level. The volume level is expressed as a normalized /// value in the range from 0.0 to 1.0. /// </param> /// <param name="eventContext">EventContext which can be accessed in the event handler.</param> /// <param name="channel"> /// The channel number. If the audio stream contains n channels, the channels are numbered from 0 to /// n–1. /// </param> /// <returns>HRESULT</returns> public unsafe int SetChannelVolumeLevelScalarNative(int channel, float level, Guid eventContext) { return(InteropCalls.CallI(UnsafeBasePtr, channel, level, &eventContext, ((void **)(*(void **)UnsafeBasePtr))[11])); }
/// <summary> /// Sets the muting state of the audio stream that enters or leaves the /// audio endpoint device. /// </summary> /// <param name="mute"><c>True</c> mutes the stream. <c>False</c> turns off muting.</param> /// <param name="eventContext">EventContext which can be accessed in the event handler.</param> /// <returns>HRESULT</returns> public unsafe int SetMuteNative(NativeBool mute, Guid eventContext) { return(InteropCalls.CallI(UnsafeBasePtr, mute, &eventContext, ((void **)(*(void **)UnsafeBasePtr))[14])); }
/// <summary> /// Sets the master volume level of the audio stream /// that enters or leaves the audio endpoint device. The volume level is expressed as a /// normalized, audio-tapered value in the range from 0.0 to 1.0. /// </summary> /// <param name="level"> /// The new master volume level. The level is expressed as a normalized /// value in the range from 0.0 to 1.0. /// </param> /// <param name="eventContext">EventContext which can be accessed in the event handler.</param> /// <returns>HRESULT</returns> public unsafe int SetMasterVolumeLevelScalarNative(float level, Guid eventContext) { return(InteropCalls.CallI(UnsafeBasePtr, level, &eventContext, ((void **)(*(void **)UnsafeBasePtr))[7])); }
/// <summary> /// The ReleaseBuffer method releases the buffer space acquired in the previous call to the /// IAudioRenderClient::GetBuffer method. /// </summary> /// <returns>HRESULT</returns> public unsafe int ReleaseBufferInternal(int numFramesWritten, AudioClientBufferFlags flags) { return(InteropCalls.CallI(_basePtr, unchecked (numFramesWritten), unchecked (flags), ((void **)(*(void **)_basePtr))[4])); }
/// <summary> /// Sets the master volume level for the audio session. /// <seealso cref="MasterVolume"/> /// </summary> /// <param name="volume">The new master volume level. Valid volume levels are in the range 0.0 to 1.0.</param> /// <param name="eventContext">EventContext which can be accessed in the event handler.</param> /// <returns>HRESULT</returns> public unsafe int SetMasterVolumeNative(float volume, Guid eventContext) { return(InteropCalls.CallI(UnsafeBasePtr, volume, &eventContext, ((void **)(*(void **)UnsafeBasePtr))[3])); }
/// <summary> /// The SetMute method sets the muting state for the audio session. /// </summary> /// <returns>HRESULT</returns> public unsafe int SetMuteInternal(NativeBool muted, Guid eventContext) { return(InteropCalls.CallI(_basePtr, muted, &eventContext, ((void **)(*(void **)_basePtr))[5])); }
/// <summary> /// The SetMasterVolume method sets the master volume level for the audio session. /// </summary> /// <returns>HRESULT</returns> public unsafe int SetMasterVolumeInternal(float volume, Guid eventContext) { return(InteropCalls.CallI(_basePtr, volume, &eventContext, ((void **)(*(void **)_basePtr))[3])); }