Page 1 of 1

Set network-caching option in HTML together stream definition

Posted: 19 Jun 2017 12:52
by ZOvnat
The following HTML is opened in an MFC dialogbox (the code of which is IE-based).
I would like to modify the HTML below such that streaming already starts with the option ":network-caching=300"...

I.e. have the option embedded in the param name="Src" directive...
(If possible - this is MUCH preferable to opening the page with no video and then by simulating a button click invoking a Javascript function to open the stream and set the option using 'playlist.add'...)

<!DOCTYPE html>
<html>
<body>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
</head>
<object
classid="clsid:9BE31822-FDAD-461B-AD51-BE1D1C159921"
codebase="http://download.videolan.org/pub/videol ... /axvlc.cab"
id="vlc"
name="vlc"
class="vlcPlayer"
events="True">
<param name="Src" value="rtsp://192.168.200.15:8557/PSIA/Streaming/channels/2?videoCodecType=H.264" /> <!-- ie -->
</object>
</html>
</body>

Re: Set network-caching option in HTML together stream definition

Posted: 20 Jun 2017 15:56
by da2424
This code will load the video with the network-caching option:

Code: Select all

<!DOCTYPE html> <html> <body> <head> <meta http-equiv="Content-type" content="text/html; charset=utf-8" /> </head> <object classid="clsid:9BE31822-FDAD-461B-AD51-BE1D1C159921" codebase="http://download.videolan.org/pub/videolan/vlc/last/win32/axvlc.cab" id="vlc" name="vlc" class="vlcPlayer"> </object> <script type="text/javascript"> var vlc = document.getElementById("vlc"); vlc.playlist.add("rtsp://192.168.200.15:8557/PSIA/Streaming/channels/2?videoCodecType=H.264", "", ":network-caching=300"); vlc.playlist.play(); //If Autoplay is wanted </script> </body> </html>