MediaChannel.Direction Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets the current channel direction.
public:
property Microsoft::Rtc::Collaboration::AudioVideo::MediaChannelDirection Direction { Microsoft::Rtc::Collaboration::AudioVideo::MediaChannelDirection get(); };
public Microsoft.Rtc.Collaboration.AudioVideo.MediaChannelDirection Direction { get; }
member this.Direction : Microsoft.Rtc.Collaboration.AudioVideo.MediaChannelDirection
Public ReadOnly Property Direction As MediaChannelDirection
Property Value
Examples
The following example disconnects the call if media channel direction changes to some value different than SendReceive or Inactive.
C# Verifying MediaChannel's properties.
audioVideoFlow.ConfigurationChanged += delegate(object sender, AudioVideoFlowConfigurationChangedEventArgs arg)
{
AudioVideoFlow avFlow = (AudioVideoFlow)sender;
// check directions
AudioChannel audioChannel = (AudioChannel)avFlow.Audio.GetChannels()[ChannelLabel.AudioMono];
if ((audioChannel.Direction != MediaChannelDirection.SendReceive)
&& (audioChannel.Direction != MediaChannelDirection.Inactive))
{
AudioVideoCall call = avFlow.Call;
call.EndTerminate(call.BeginTerminate(null, null));
}
};
Applies to
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for