示例#1
0
 public void RemoveAudioSourceConfiguration(Media.Profile profile)
 {
     if (profile.AudioSourceConfiguration != null)
     {
         profile.AudioSourceConfiguration.UseCount = profile.AudioSourceConfiguration.UseCount - 1;
         profile.AudioSourceConfiguration          = null;
     }
 }
示例#2
0
 public void RemoveVideoEncoderConfiguration(Media.Profile profile)
 {
     if (profile.VideoEncoderConfiguration != null)
     {
         profile.VideoEncoderConfiguration.UseCount = profile.VideoEncoderConfiguration.UseCount - 1;
         profile.VideoEncoderConfiguration          = null;
     }
 }
示例#3
0
 public void AddAudioSourceConfiguration(Media.Profile profile, Media.AudioSourceConfiguration configuration)
 {
     configuration.UseCount = configuration.UseCount + 1;
     if (profile.AudioSourceConfiguration != null)
     {
         profile.AudioSourceConfiguration.UseCount = profile.AudioSourceConfiguration.UseCount - 1;
     }
     profile.AudioSourceConfiguration = configuration;
 }
示例#4
0
 public void AddVideoEncoderConfiguration(Media.Profile profile, Media.VideoEncoderConfiguration configuration)
 {
     configuration.UseCount = configuration.UseCount + 1;
     if (profile.VideoEncoderConfiguration != null)
     {
         profile.VideoEncoderConfiguration.UseCount = profile.VideoEncoderConfiguration.UseCount - 1;
     }
     profile.VideoEncoderConfiguration = configuration;
 }
示例#5
0
        public void DeleteProfile(Media.Profile profile)
        {
            if (profile.VideoEncoderConfiguration != null)
            {
                profile.VideoEncoderConfiguration.UseCount = profile.VideoEncoderConfiguration.UseCount - 1;
            }
            if (profile.VideoSourceConfiguration != null)
            {
                profile.VideoSourceConfiguration.UseCount = profile.VideoSourceConfiguration.UseCount - 1;
            }
            if (profile.AudioEncoderConfiguration != null)
            {
                profile.AudioEncoderConfiguration.UseCount = profile.AudioEncoderConfiguration.UseCount - 1;
            }
            if (profile.AudioSourceConfiguration != null)
            {
                profile.AudioSourceConfiguration.UseCount = profile.AudioSourceConfiguration.UseCount - 1;
            }

            _profiles.Remove(profile);
        }