Разработчикам. Large Orange VLC media player Traffic Cone Logo VLC media player - Windows Vista - Qt Interface · Просмотреть все скриншоты. VLC - Qt is a free library used to connect Qt and libVLC libraries. It contains core classes for main media playback and also some GUI classes for faster media.
Custom Video Streaming Player using LibVLC and Qt. In my last two blog entries I have discussed how you can stream video from embedded Linux devices such as the Beaglebone using FFMPEG/AVCONV, the V4L2 Capture program and the Logitech C920 USB Camera (with hardware MPEG4/H264). In these setups I am using the regular VLC player to receive and display the video streams (RTP, UDP unicast and UDP multicast). These posts are available here:. Streaming Video using RTP on the Beaglebone Black.
UDP Unicast and Multicast Streaming Video using the Beaglebone Black. I would advise that you read those posts first as I am building on them in this post. The problem with these solutions is that they are using VLC to display the video and you are effectively without any type of control of the application. For example, If you wished to build a robot navigation system that streams video to the control panel then it would not be possible to modify the VLC user interface very easily.
So this post covers the area of building your own application to view the video streams. You could try and do this from first principles, but that is much too big a task; instead, you are better building on what is currently available. Step 1: VLC using LibVLC.
LibVLC is an incredibly comprehensive and accessible code library for all of the features that are present in the cross-platform VLC multimedia player. It would be great if we can take advantage of this library as it includes all of code necessary to decode video streams, deal with network sockets etc. And we can! The description of the functionality available in LibVLC is available here:. You can even download the source code for VLC itself from:. Step 1: Download the version of LibVLC for your platform. To make life easy I would recommend using the pre-built versions.
My platform for this post is 64-bit Windows 7 and I am using the tarball for Windows x64 (the latest version at the time of writing is version 2.
7): ftp://ftp. videolan. org/pub/videolan/vlc/2.
7/win64/ I downloaded and extracted the Windows x64 tarball to a directory C:Qtvlc-2. 7 in my case. You can go back a few levels on that URL to check if there are more recent versions and to find the version for your platform. Step 2: Use a LibVLC Wrapper. The great thing about open source is that someone has probably tried to do what you are looking to do before and has written some code. The downside is often that solutions are not well packaged and often need customisation to work with recent libraries.
There are several examples on how to use LibVLC within C++ and there are also several wrappers that are available for C++ to help make this process easier. I have tried several, but had particular success with these two:.
The reason I selected both of these is that I was able to download the source code for both and was able to recompile them from source under Windows. I’m not sure how useful the first link is under Linux as it is set up for Visual Studio, but the second link uses Qt which means it should be fine under all platforms. For this reason and because I really, really like Qt as an extension to C++, giving multi-platform user-interfaces, threads, sockets, etc. And, it is freely available.
For more information on Qt – see this link. Step 2: Download the vlc-qt library – I downloaded the “Official VLC-Qt Windows SDK and Source Packages”, which involved clicking the big green box. I extracted this to a folder in my c:Qt directory called libvlc-qt.
So, the directory looks like:.