Tuesday, March 29, 2011

[YouTube-API] Re: behavior of pauseVideo()

Hello Dave,

The consensus from the team is that the behavior you describe is a
direct result of the way the Flash runtime's NetStream object handles
seeks within an existing buffer vs. a request to start playing from a
new buffer. This is low-level behavior in the Flash playback
libraries, and is not some that the YouTube Player will override.

The Players team does not have a particular concern with your code
calling stop and then play again—the limitations/side effects that you
point out do apply, but if you feel that it gives the best user
experience, there's nothing stopping you.

Cheers,
-Jeff Posnick, YouTube API Team
~ YouTube is hiring! ~ http://google.com/jobs/workyoutube ~


On Mar 23, 10:39 pm, Dave <dbcarl...@gmail.com> wrote:
> Hi Jeff,
>    We're using Actionscript 3. Thanks again for your help.
>
> -Dave
>
> On Mar 22, 9:19 am, Jeffrey Posnick <je...@google.com> wrote:
>
>
>
>
>
>
>
> > Also, so that I'm clear on what you're describing, which version of
> > the player (ActionScript 2 vs. ActionScript 3 vs. <iframe>) are you
> > using?
>
> > Cheers,
> > -Jeff Posnick, YouTube API Team
> > ~ YouTube is hiring! ~http://google.com/jobs/workyoutube~
>
> > On Mar 22, 12:17 pm, Jeffrey Posnick <je...@google.com> wrote:
>
> > > Hello Dave,
>
> > >  I've never noticed that myself. I'll bring it up with the Players API
> > > team and see if it's intentional or something that they might be open
> > > to changing.
>
> > > Cheers,
> > > -Jeff Posnick, YouTube API Team
> > > ~ YouTube is hiring! ~http://google.com/jobs/workyoutube~
>
> > > On Mar 19, 9:00 pm, Dave <dbcarl...@gmail.com> wrote:
>
> > > > We've noticed that there is a difference between how playback is
> > > > resumed when a youtube clip is started vs. unpaused.
>
> > > > If you call pauseVideo() then playVideo(), the clip will start from
> > > > the nearest keyframe. This can be ahead or behind the current
> > > > playtime.
>
> > > > On the other hand, if you call stopVideo() then playVideo(), the clip
> > > > will always start from the nearest keyframe before (never after) the
> > > > current playtime.
>
> > > > We prefer the latter behavior for our application, but calling
> > > > stopVideo() all the time is less than ideal.
>
> > > > The user loses previously downloaded data, and youtube's servers have
> > > > to deal with more requests. The API says that stopVideo() ... "should
> > > > be reserved for rare situations when you know that the user will not
> > > > be watching additional video in the player."
>
> > > > Is there any way around this? If not, is it problematic to use
> > > > stopVideo() in place of pauseVideo() for this purpose?
>
> > > > Thanks,
> > > > Dave

--
You received this message because you are subscribed to the Google Groups "YouTube APIs Developer Forum" group.
To post to this group, send email to youtube-api-gdata@googlegroups.com.
To unsubscribe from this group, send email to youtube-api-gdata+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/youtube-api-gdata?hl=en.

No comments:

Post a Comment