IE always hang ??? [fixed]

All you've ever wanted to know about the ActiveX, Mozilla plugins, the web interface and various PHP extensions
5kinman
Blank Cone
Blank Cone
Posts: 29
Joined: 14 Nov 2008 10:18
Location: Hong Kong

IE always hang ??? [fixed]

Postby 5kinman » 07 Jan 2009 10:49

I am using the IE 7.0, and VLC 0.9.8a

I don't know why the html page will crash the IE ...

(the JS file VLCobject is downloaded from revolunet )

Code: Select all

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML> <HEAD> <TITLE> Streaming Client </TITLE> </HEAD> <BODY> <center> <div id="vlccontents"> Player loading... </div> <script type="text/javascript" src="VLCobject.js"></script> <script type="text/javascript"> var so = new VLCObject("clientOutput", "600", "350"); so.write("vlccontents"); </script> <br><br> <script type="text/javascript"> var vout_state = false; var subtitle_index = 0; var audio_track_index = 1; var vlc_state = 0; function vlcOperation(opCode) { var vlc = document.getElementById("clientOutput"); if (opCode == 0) { vlc.playlist.items.clear(); while (vlc.playlist.items.count != 0) { } vlc.playlist.add("udp://@224.0.0.40:1234", "", " :vout-filter=deinterlace :deinterlace-mode=linear"); vlc.playlist.play(); vlc.video.subtitle = subtitle_index; vlc.audio.track = audio_track_index; vlc.audio.volume = 200; } else if (opCode == 1) { vout_state = vlc.input.hasVout; } }; function handleVLC() { if (vlc_state == 0) { vlcOperation(0); vlc_state = 1; } else if (vlc_state == 1) { vlcOperation(1); if (vout_state == true) { vlc_state = 2; } else { vlc_state = 0; } } else if (vlc_state == 2) { clearInterval(handleVLCIntervalId); } else { vlc_state = 0; } }; </script> <script type="text/javascript"> handleVLCIntervalId = setInterval('handleVLC()', 500); </script> </center> </BODY> </HTML>
Does VLC support IE 7.0?
Last edited by 5kinman on 22 Jan 2009 10:25, edited 1 time in total.

Anatoly_B
Blank Cone
Blank Cone
Posts: 14
Joined: 20 Aug 2008 03:30

Re: IE always hang ???

Postby Anatoly_B » 07 Jan 2009 21:09

while (vlc.playlist.items.count != 0) {}
- :(
The delay 250ms minimum after vlc.playlist.items.clear() is required before any next operation with VLC Plugin (including check vlc.playlist.items.count)

5kinman
Blank Cone
Blank Cone
Posts: 29
Joined: 14 Nov 2008 10:18
Location: Hong Kong

Re: IE always hang ???

Postby 5kinman » 08 Jan 2009 03:41

Thx for the reply.

I've try to do other vlc operation after 500ms. But the IE hang up and require to close with the following:

Code: Select all

AppName: iexplore.exe AppVer: 7.0.6000.16762 ModName: libvlc.dll ModVer: 0.0.0.0 Offset: 00004d00

Anatoly_B
Blank Cone
Blank Cone
Posts: 14
Joined: 20 Aug 2008 03:30

Re: IE always hang ???

Postby Anatoly_B » 08 Jan 2009 20:27

vlc.playlist.items.clear(); while (vlc.playlist.items.count != 0) { };
- This causes crash...
vlc.playlist.items.clear() ---> 250ms ---> anyVar=vlc.playlist.items.count
- Waiting in an empty cycle is undesirable (it causes heavy CPU loading and will increase necessary delays), preferably periodic inquiry:
functon TestPlayListState(){ if(vlc.playlist.items.count!=0){setTimeout("TestPlayListState()",250)}else{PlayStart()} }
vlc.playlist.items.clear(); setTimeout("TestPlayListState()",250);

revolunet
Big Cone-huna
Big Cone-huna
Posts: 515
Joined: 17 Oct 2007 13:16
VLC version: 0.9.8
Operating System: Vista
Location: Paris, France
Contact:

Re: IE always hang ???

Postby revolunet » 12 Jan 2009 10:43

yes it can work with IE7

But... theres a bug in 0.9.8 plugin playlist management

the clear() function doesnt seem to work anymore, so heres a workaround :

Code: Select all

var itemid = vlc.playlist.add(myitemuri); vlc.playlist.playItem(itemid)
the playlist will never be cleared but you can play the last item...

hope this helps :)
VLC & web IT consulting - http://www.revolunet.com
Github : http://github.com/revolunet

5kinman
Blank Cone
Blank Cone
Posts: 29
Joined: 14 Nov 2008 10:18
Location: Hong Kong

Re: IE always hang ???

Postby 5kinman » 12 Jan 2009 11:28

Thanks for the reply.

I'll try to run VLC on the IE with other html codings to solve the problem.


Return to “Web and scripting”

Who is online

Users browsing this forum: No registered users and 9 guests