if (btnStart.Tag.ToString() == "0")
{
if (_VedioAndController == null)
_VedioAndController = new IpCameraHelper(GetConfigValue("RoundVedioIp"), GetConfigValue("RoundVedioUserName"), GetConfigValue("RoundVedioPassWord"),
new Action<ImageEventArgs>((arg) =>
{
img.Source = arg.FrameReadyEventArgs.BitmapImage;
}));
_VedioAndController.StartProcessing();
btnStart.Content = "关闭";
btnStart.Tag = "1";
}
else
{
if (_VedioAndController != null)
_VedioAndController.StopProcessing();
btnStart.Content = "打开";
btnStart.Tag = "0";