Page 1 of 1

Add a video stream

Posted: Mon Feb 06, 2012 5:46 am
by ric
Good morning. I'm trying to activate a video stream between an Axis IP camera and my iX application. With the developing PC I didn't find any problem, with a Media Element object and this script line:

void Video_Opened(System.Object sender, System.EventArgs e)
{
pbVideo1.Source = new Uri("axrtsphttp://192.168.1.101/mpeg4/media.amp", UriKind.Absolute);
}

Running the application on Windows 7 with iX Developer there's no problem. But when I try to run the application in Windows XP with ix Runtime I don't see anything e the stream doesn't start.

Any suggestion?

Thank's,
Ric

Re: Add a video stream

Posted: Mon Feb 06, 2012 11:16 am
by Ron L.
It could be an Ethernet issue connecting from this other PC. Are you able to ping 192.168.1.101?

I would also put a try/catch block around the function call to see what information you can get from the exception. The code looks something like this.

void Video_Opened(System.Object sender, System.EventArgs e)
{
try {
pbVideo1.Source = new Uri("axrtsphttp://192.168.1.101/mpeg4/media.amp", UriKind.Absolute);
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}

}

Re: Add a video stream

Posted: Fri Feb 17, 2012 9:00 am
by ric
Ok, it wasn't an iX problem but just caused from an old version of Windows Media Player and Axis Media Control.

Re: Add a video stream

Posted: Fri Jun 07, 2013 2:36 am
by charlyprouteau
Dear Sir,
When I try to add the scrip code I have this error message:
"Unable to convert implicitly type 'System.Uri' to 'String'.

Could you explain how solve this error.

thanks for your support.

Re: Add a video stream

Posted: Fri Jun 07, 2013 8:08 am
by mark.monroe
System.URI is not supported on WinCE .NET framework. If you are not targeting a Windows PC or TxC, you will get this error. I currently do not know of a way to stream video to the Media player on a WinCE HMI. We are currently trying to find a way.