Skip to main content

Microsoft Silverlight

Unanswered Question Video Buffering Silverlight 2RSS Feed

(0)

vijayreddykatta
vijayred...

Member

Member

0 points

8 Posts

Video Buffering Silverlight 2

Hi All, 

I wrote this method in canvas_loaded.

MediaPlayer.BufferingProgressChanged += new RoutedEventHandler(MediaPlayer_BufferingProgressChanged);

Sometimes this method is calling after video running. 

Sometimes this method is calling late(slowly). Why?

void MediaPlayer_BufferingProgressChanged(object sender, RoutedEventArgs e)

{

prBar.filler().Width = MediaElement.BufferingProgress * (150);

if (md.BufferingProgress == 0.0 || md.BufferingProgress == 1.0)

prBar.hidden();

else

prBar.show();

}

 While bufferingprogress = 0  then buffering progressbar is displaying(sometime) , It's hiding after 4 or 5 sec video playing.At this moment this method is calling late.Once its called its hiding.

All the times its hiding if bufferingprogress = 0

What's the problem? Any one help please.

Thanks,

Vijay

rajesh shirpuram
rajesh s...

Contributor

Contributor

2314 points

505 Posts

Re: Video Buffering Silverlight 2

 have you tried deleting your browser cache?

Thanks
Rajesh Shirpuram

(If this has answered your question, please click on "mark as answer" on this post. Thank you!)

vijayreddykatta
vijayred...

Member

Member

0 points

8 Posts

Re: Re: Video Buffering Silverlight 2

I have deleted browser cache also. ButSad

djprod
djprod

Member

Member

334 points

65 Posts

Re: Video Buffering Silverlight 2

 From the Beta 2 documentation:- 

!QUOTE!

The BufferingProgressChanged event typically occurs multiple times during a download. The event will occur when the BufferingProgress value increases by 0.05 or more, compared to the last time the event was raised, and also when the value reaches 1.0.

 !ENDQUOTE!

so perhaps, (sorta guessing here as i'm a SL 1.0 dev)

if (md.BufferingProgress == 0.0 || md.BufferingProgress == 1.0 && md.downloadprogress==1.0)

so that your buffering indicator stays visible until content is fully downloaded, might do the trick

Also I guess you know the only Visibility options are Visibility="Visible" or Visibility="Collapsed"

Hope this helps

regards

Marc.

roomygupta
roomygupta

Member

Member

82 points

62 Posts

Re: Video Buffering Silverlight 2

what is tis prBar in the code??

and can you please let me know how we can give diferent types of buffering UI in our projet??

ROOMY GUPTA
  • Unanswered Question
  • Answered Question
  • Announcement
Microsoft Communities