Jan 23, 2012 at 11:20 AM
Edited Jan 23, 2012 at 11:41 AM
There seems to be a bug in the SMFPlayer.SubscribeToDataStreams(params string streamNames) method that causes it to always throw an exception for the following reasons:
This method calls
ActiveAdaptiveMediaPlugin.ModifySegmentSelectedStreams(ActiveAdaptiveMediaPlugin.CurrentSegment, streamsToSelect, null)
But that method calls
where the streamsToRemove is the last parameter in this function. Because this function was called with that parameter as null, it causes an exception (you cannot call
Cast<T> on a null reference) and the method aborts.
To fix this, one could ensure that SMFPlayer.SubscribeToDataStreams(params string streamNames)
actually sends in an empty List<IMediaStream> as the last parameter of
ActiveAdaptiveMediaPlugin.ModifySegmentSelectedStreams. And it will also be necessary to the same in
SMFPlayer.UnsubscribeToDataStreams(params string streamNames), just with with the second parameter in this case.