private void Disconnect( )
{
if ( videoSourcePlayer.VideoSource != null )
{
// stop video device
videoSourcePlayer.SignalToStop( );
videoSourcePlayer.WaitForStop( );
videoSourcePlayer.VideoSource = null;
if ( videoDevice.ProvideSnapshots )
{
videoDevice.SnapshotFrame -= new NewFrameEventHandler( videoDevice_SnapshotFrame );
}
EnableConnectionControls( true );
}
}