Page 1 of 1

Getting tracks info about a stream without actually playing it (silent+no screen output)

Posted: 10 Dec 2016 16:14
by fishstyc
Hello,

a few years ago, I used LibVLC pre 2.0 to play streams (like rtsp, http, dvb-t, ...)

With that version, I managed to first get the info about the streams 'silently' (in the background) by adding this option to the media first:

Code: Select all

libvlc_media_add_option( preloadMedia, "sout=#description:dummy" );
and then when I got the information, I would load the stream again, but by then I'd know its size so I could properly prepare the textures that it was supposed to render to.

Since 2.0 however, this stopped working, and I would like to know if and how it could be done with the current version of the library.

Thanks

Re: Getting tracks info about a stream without actually playing it (silent+no screen output)

Posted: 27 Dec 2016 11:52
by Jean-Baptiste Kempf
You can use VLC preparsing for that.