This is a message.

can"t pause video while buffering Created Sep 16, 2009

This thread is solved

Views: 2936     Replies: 1     Last reply Oct 21, 2009  
You must login first before you can use this feature

rmerch

Posts: 8

Registered:
Sep 16, 2009

can"t pause video while buffering

Posted: Sep 16, 2009

I would like to be able to pause a video while it is buffering but this does not seem to work.

I decided that I will check to see if the video is buffering, if it is I then stop the buffering and pause the video which worked fine. The issue I have now is restarting the video. When I press play again, I also restart the buffering using startBuffering() but this does not seem to start the video playing even though the getState() tells me that the video state is playing

i have read that the stop buffering clears the whole buffer but I can not see why this would not allow the video to play back when you restart it.

Can anyone help

rmerch

Posts: 8

Registered:
Sep 16, 2009

Solved - can"t pause video while buffering

Posted: Oct 21, 2009

Reply to: can"t pause video while buffering, from rmerch
The problem was that the video had not loaded and the stop buffering function cleared the buffer. I wanted the user to be able to stop the video from playing but still continue to buffer the video.

The solution was to check the video state as I was doing anyway and if the state is <=2 (unloaded, loading, buffering) then use the stop function. If it is >= 3 use the pause function. This seems to work fine, although I have not tested this thoroughly yet.