Source language: Translate to:

problem with streaming video and jwplayer

General questions about NeoBook

Moderator: Neosoft Support

problem with streaming video and jwplayer

Postby impulsmedia » Thu May 29, 2014 7:37 am

Hi there,
I tried hard to get a live videostream into a NB pub, but without success. I checked webbrowser object with a html-page with jwplayer embeded as well as a flash object and NBdxplayer - nothing works. You can check the url http://test.impulsmedia.de/Streamtest3.html and it will work on IE and firefox. If you put this page into a webbrowser object it will NOT work - also if you uncheck IR7 compatibility. I´m really under pressure because I have to stream a live event on Saturday.

Any idea how to get this stream in a NB pub. Thanks a lot for every hint
thanks in advance and greetings from Germany,
Walter
impulsmedia
 
Posts: 38
Joined: Wed Mar 22, 2006 9:01 am
Location: GERMANY

Re: problem with streaming video and jwplayer

Postby dec » Thu May 29, 2014 7:59 am

Hello,

I think we can have some "wrong referer" problems. Apparently the server refuse to stream the video in local files, not only if loaded into a Webbrowser object, but also if we try to use the HTML from Internet Explorer, Firefox, etc. However I found another "freak" error. Once I try with the HTML local file without success, I decide to use the URL you shown directly into the Webbrowser object:

http://test.impulsmedia.de/Streamtest3.html

This works on Internet Explorer, Firefox, etc. And I can view also working in a NeoBook webbrowser object! However, when I try to repeat the test I found this not working anymore. Here is working:

Image

And here is not working:

Image

Why sometimes working and sometimes not? I am not sure... I want to try something and inform here about what happend.
.
Enhance your NeoBook applications!
.
57 plugins, 1113 actions and 230 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: problem with streaming video and jwplayer

Postby dec » Thu May 29, 2014 8:31 am

Hello,

Well. Apparently we have this working. Let me to explain what I do. First, remember we cannot use a local HTML file. I am not sure why this do not work, but probably the problem is in the server side, because this not only do not work in the NeoBook WebBrowser, but also in Firefox nor Internet Explorer, for example. Probably the webserver only stream the video if certain "referer" is the appropiate.

So we need to try to use the URL which you provide:

http://test.impulsmedia.de/Streamtest3.html

Because this works at least in Firefox and Internet Explorer, for example. So the problem now is why this URL do not work in the NeoBook WebBrowser object. First of all we need to know that working with the WebBrowser object is a pain, not only in NeoBook but in any other software which use the Windows WebBrowser object. For example, even if we uncheck the "Run with IE7 compatibility mode" we get the above URL not working in the WebBrowser control.

But, my npConf plugin appear here to the rescue. In fact we can use the Internet Browser Emulation, setting for our publication the appropiate "emulation" value. And what is this value? I am not sure in any scenario, but my software use the latest emulation value available. And this is what I do in the publication test: use the latest available emulation value, and they works like a charm.

Yes; We can codify the bellow lines into the "Book Startup actions":

Code: Select all
npRegCreate "[RegID]"
npRegOpenKey "[RegID]" "Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION" "True" "[Result]"
npRegWriteValue "[RegID]" "LiveStream.exe" "11001" "Integer" "[Result]"
npRegDestroy "[RegID]" "[Result]"

BrowserGoTo "WebBrowser1" "http://test.impulsmedia.de/Streamtest3.html"


Note two things here. "LiveStream.exe" is the name of the sample publication which I use. This name need to match with your own publication. If your publication executable is named "Impulsmedia.exe", replace "LiveStream.exe" with "Impulsmedia.exe".

The other thing is obvious: browse to the appropiate URL after the emulation value has ben put into the Windows Registry. If you try it before you get the "configuration file error". In my test, browse to the URL after the emulation value has been set works like a charm.

Doing this you get the URL working, but, for cleaning purposes, you can put these other code lines into the "Book Shutdown actions":

Code: Select all
npRegCreate "[RegID]"
npRegOpenKey "[RegID]" "Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION" "True" "[Result]"
npRegDeleteValue "[RegID]" "LiveStream.exe" "[Result]"
npRegDestroy "[RegID]" "[Result]"


This code simply remove the previously created registry key to maintain the registry clean. Note again you need to replace the "LiveStream.exe" value with the name of your own publication executable. Bellow you can download the "LiveStream" publication sample, which include the publication source code and the compiled executable. Try it and tell here if they works for you:

http://www.neoplugins.com/Temp/LiveStream.zip

Hope this can help you in some manner Walter.
.
Enhance your NeoBook applications!
.
57 plugins, 1113 actions and 230 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: problem with streaming video and jwplayer

Postby David de Argentina » Thu May 29, 2014 10:50 am

Hi Walter,

I'm trying to put in work your streamming file using my NeoMediaPlayer plugin.

Windows Media player does not recognize the string connection of the streamming.

Perhaps, if you set the streamming mode for windows media player, like:

http://www.26noticias.com.ar/noticias/c ... anal26.wvx

you could use NeoMediaPlayer plugin to stream the file.

The download of the plugin is:

http://www.neobook.com.ar/files/NeoMediaPlayer.zip

You can see how it works with the previous streamming link

My 0.02

David de Argentina
User avatar
David de Argentina
 
Posts: 1553
Joined: Mon Apr 04, 2005 4:13 pm
Location: Buenos Aires, Argentina

Re: problem with streaming video and jwplayer

Postby impulsmedia » Thu May 29, 2014 11:59 am

Hi dec, youre th best and thanks a lot for your work. but i´m sorry, it doesn´t work. maybe I have to test different emulations, but for the moment its not working. Strange thing is, that i saw the full stream one time in the open pub in a webbrowser object - now nevermore .... slowly get crazy ... thanks again
thanks in advance and greetings from Germany,
Walter
impulsmedia
 
Posts: 38
Joined: Wed Mar 22, 2006 9:01 am
Location: GERMANY

Re: problem with streaming video and jwplayer

Postby dec » Thu May 29, 2014 12:31 pm

Hello,

Please Walter, try to add into your HTML document an "HTML" tag just after the DOCTYPE.

Instead of this:

Code: Select all
<!DOCTYPE html>
<head>


Add the HTML tag like:

Code: Select all
<!DOCTYPE html>
<html>
<head>


Then try it again and if you like comment it here when finish in order to allow us to try it.

And please, inform us also about the version of Internet Explorer installed in your system.

P.S. Of course a possible solution is to use the David de Argentina plugin if they works.
.
Enhance your NeoBook applications!
.
57 plugins, 1113 actions and 230 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: problem with streaming video and jwplayer

Postby impulsmedia » Thu May 29, 2014 12:53 pm

Hi dec, I did the test, no difference, still the same error. My IE is version 10.0.9200.16889
thanks in advance and greetings from Germany,
Walter
impulsmedia
 
Posts: 38
Joined: Wed Mar 22, 2006 9:01 am
Location: GERMANY

Re: problem with streaming video and jwplayer

Postby dec » Thu May 29, 2014 1:04 pm

Hello,

I try the HTML tag by myself upload the HTML file into my webserver. Apparently this do not work here, but, Walter, I can't see the HTML tag in your HTML document:

http://test.impulsmedia.de/Streamtest3.html

Can cause this some different? Maybe. Because we need to avoid Internet Explorer entering in "quircks" mode, as we can read into the player documentation:

Two common issues prevent smooth playback of videos in Internet Explorer 9+. First, always start your HTML document with <!DOCTYPE html> to prevent triggering IE's quirks mode. Second, serve up your videos with the video/mp4 mimetype or IE will refuse to play them.


So please, add the HTML tag and let added in order to allow us to test. On the other hand the code you used maybe is not the ultimate way to embed a video according again with the player documentation: maybe we need to chage the code to something like that:

Code: Select all
<div id="myElement">Loading the player...</div>
<script type="text/javascript">
    jwplayer("myElement").setup({
        file: "http://example.com/uploads/myVideo.mp4",
        width: 640,
        height: 360
    });
</script>


Maybe the configuration file maybe is not needed. But anyway it's a good thing to use the latest possible code available, because old code can cause the problem. After trying all above sugestion, we can have at least one more bullet:

[...] Second, serve up your videos with the video/mp4 mimetype or IE will refuse to play them.


Maybe this can also cause the problem. We need to assert the server serve the video using the right mimetype.

P.S. Some final notes for now: apparently the player need Internet Explorer 9 to work. But when we try to emulate this using the Windows Registry we found erratic results. Sometimes works, most of them not. However, here in my system with Internet Explorer 11 and the appropiate emulation key into the Windows Registry the publication always works well. Really the webbrowser control is a pain.

P.S.2. Maybe have not lucky if need to try the mimetype approach, since the URL used by the player (rtmp://46.245.180.161/live/livestream) probably do not point to a MP4 file... it's not in our server, and therefore probably we cannot change their mimetype at all. So carefully try the HTML tag and to change the Javascript code to the latest version. If this do not works... really I don't know what to say except "Update Internet Explorer", which may can't be a solution.
.
Enhance your NeoBook applications!
.
57 plugins, 1113 actions and 230 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: problem with streaming video and jwplayer

Postby dec » Thu May 29, 2014 1:10 pm

Hello,

More things to be carefully considered:

http://support.jwplayer.com/customer/po ... le-loading
.
Enhance your NeoBook applications!
.
57 plugins, 1113 actions and 230 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: problem with streaming video and jwplayer

Postby impulsmedia » Thu May 29, 2014 1:12 pm

Hi dec, thanks again.Please use Streamingtest4.html - this has a other code, but the same problem. I have to shutdon the stream now soon. opther things I will check tomorrow. Thanks
thanks in advance and greetings from Germany,
Walter
impulsmedia
 
Posts: 38
Joined: Wed Mar 22, 2006 9:01 am
Location: GERMANY

Re: problem with streaming video and jwplayer

Postby dec » Thu May 29, 2014 1:43 pm

Hello,

One thing to do not forget is to read carefully the documentation of the JS player. Is plenty of information and possible issues. Maybe we cannot solve the problem, but probably we cannot forget such source of information.
.
Enhance your NeoBook applications!
.
57 plugins, 1113 actions and 230 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: problem with streaming video and jwplayer

Postby dec » Thu May 29, 2014 6:48 pm

Hello,

Just to say I test the "LiveStream.exe" and works like a charm in another system (my laptop) using Windows 7 (instead Windows 8) and Internet Explorer 11.

P.S. Well. At least we can recommend to use the latest Internet Explorer version searching for a solution.
.
Enhance your NeoBook applications!
.
57 plugins, 1113 actions and 230 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain

Re: problem with streaming video and jwplayer

Postby impulsmedia » Thu May 29, 2014 11:33 pm

Hello dec,
I just tried another PC with WIN 7 and IE 11 AND ITS WORKING! YipeehYeah! :D Thanks so much for your work. We will talk about the fe for this later Thanks so much!
thanks in advance and greetings from Germany,
Walter
impulsmedia
 
Posts: 38
Joined: Wed Mar 22, 2006 9:01 am
Location: GERMANY

Solution found for problem with streaming video !

Postby impulsmedia » Fri May 30, 2014 1:15 am

Hi to all,
I found the final solution fore the problem: The problem depends on cached files/links/urls erc. Everytime I emptied the IE cache manually the stream was shown and running perfect. On every second try I got the error again. So I checked google for a command line tool to empty all caches of IE and found this:
http://stackoverflow.com/questions/12621969/clear-cache-of-browser-by-command-line

The code for the batchfile works perfect and now I start this batch everytime before calling the streaming webpage andf everything works fine! I´ll test this now on different OS and systems and give you a final report. Thanks again to dec and David de Argentina.

CODE also written on the URL above:

erase "%TEMP%\*.*" /f /s /q
for /D %%i in ("%TEMP%\*") do RD /S /Q "%%i"

erase "%TMP%\*.*" /f /s /q
for /D %%i in ("%TMP%\*") do RD /S /Q "%%i"

erase "%ALLUSERSPROFILE%\TEMP\*.*" /f /s /q
for /D %%i in ("%ALLUSERSPROFILE%\TEMP\*") do RD /S /Q "%%i"

erase "%SystemRoot%\TEMP\*.*" /f /s /q
for /D %%i in ("%SystemRoot%\TEMP\*") do RD /S /Q "%%i"

@rem Clear IE cache - (Deletes Temporary Internet Files Only)
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 8
erase "%LOCALAPPDATA%\Microsoft\Windows\Tempor~1\*.*" /f /s /q
for /D %%i in ("%LOCALAPPDATA%\Microsoft\Windows\Tempor~1\*") do RD /S /Q "%%i"

@rem Clear Google Chrome cache
erase "%LOCALAPPDATA%\Google\Chrome\User Data\*.*" /f /s /q
for /D %%i in ("%LOCALAPPDATA%\Google\Chrome\User Data\*") do RD /S /Q "%%i"

@rem Clear Firefox cache
erase "%LOCALAPPDATA%\Mozilla\Firefox\Profiles\*.*" /f /s /q
for /D %%i in ("%LOCALAPPDATA%\Mozilla\Firefox\Profiles\*") do RD /S /Q "%%i"

pause
thanks in advance and greetings from Germany,
Walter
impulsmedia
 
Posts: 38
Joined: Wed Mar 22, 2006 9:01 am
Location: GERMANY

Re: problem with streaming video and jwplayer

Postby dec » Fri May 30, 2014 2:43 am

Hello,

Yes; I read about possible cache issues in the player documentation. Well. At this point maybe you can try with some "anticache" HTML meta tags.

http://stackoverflow.com/questions/1341 ... l-browsers

Anyway glad to know finally you found a possible solution Walter. ;)
.
Enhance your NeoBook applications!
.
57 plugins, 1113 actions and 230 samples
.
NeoPlugins website: www.neoplugins.com
.
User avatar
dec
 
Posts: 1663
Joined: Wed Nov 16, 2005 12:48 am
Location: Spain


Return to General NeoBook Discussions

Who is online

Users browsing this forum: No registered users and 1 guest