Page 1 of 1

How do I know when a video is loaded?

Posted: 01 Nov 2014 12:32
by iamanidiot
Hi,

I'm new to everything around here.

In HTML5 video player, there are handy events like "loadeddata" and "loadedmetadata", which I can listen to know that a video is loaded and ready to play, and its metadata (width, height, length) is available.

What is the equivalent of these in VLC player? I checked the documentation and am confused. Take the event "MediaPlayerOpening" for example, is it fired before or after a video is loaded? I also notice there's vlc.input.state, but I don't want to check it periodically, like every 100ms. What's the best way to make myself notified when a video is loaded?

Re: How do I know when a video is loaded?

Posted: 21 Nov 2014 12:46
by iamanidiot
OK I'll answer this myself. MediaPlayerPlaying is the event to listen to. It doesn't seem possible to load a video and grab metadata without playing it.