microsoftgraph / microsoftgraph/microsoft-graph-comms-samples
InvalidOperationException : MediaPlatform was not initialized
Nobody has claimed this yet.
- Dominant language
- No language data
- Stars
- 253
- Forks
- 275
- Avg merge
- 1d 5h
- Merged PRs (30d)
- 1
Description
-
We have developed a WPF .Net framework application and created a ‘Call’ button to initiate Microsoft Teams calling:
-
On the click of 'Call' button 'calling' method got called and in this calling method we have used below code to create 'MediaConfig' for 'AppHostedMediaConfig':
AudioSocketSettings audioSockSettings = new AudioSocketSettings
{
CallId = Guid.NewGuid().ToString(),
SupportedAudioFormat = AudioFormat.Pcm16K,
StreamDirections = StreamDirection.Sendrecv
};
AudioSocket audioSock = new AudioSocket(audioSockSettings);
var mediaConfig = MediaPlatform.CreateMediaConfiguration(audioSock);
var call = new Call
{
MediaConfig = new AppHostedMediaConfig
{
Blob = mediaConfig.ToString(Newtonsoft.Json.Formatting.None)
},
}
-
When we use 'StreamDirection.Sendrecv' we are getting below error while applying it to 'AudioSocket':
-
When we use the 'StreamDirection.Sendonly', Then the instance of 'AudioSocket' class is created successfully. But we get below error calling 'MediaPlatform.CreateMediaConfiguration(audioSock)':
-
The package reference being installed in the application are as follow:
Both these errors seems to be related with 'Microsoft.Skype.Bot.Media' dll.
Please provide a solution for these exceptions
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the WPF .NET Framework calling method and the Microsoft.Skype.Bot.Media package references shown in the issue. Reproduce both AudioSocket configurations, then inspect where MediaPlatform initialization is expected before CreateMediaConfiguration; done means both reported exceptions have a documented, verified resolution.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- audio-video-rtc
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100