How to stream the video using VLC-QT wrapper

This forum is about all development around libVLC.
vinayk9119
New Cone
New Cone
Posts: 3
Joined: 06 Dec 2020 17:39

How to stream the video using VLC-QT wrapper

Postby vinayk9119 » 06 Dec 2020 17:44

I want to stream the video using ```RTSP, HTTP and UDP ``` as they are supported by ```vlc```. I am using ```Qt5``` and as ```Qt``` don't have that much good media libraries so I go for open source and now using ```libvlc``` through ```VLC-Qt``` wrapper.

I am able to receive the stream videos in my program, The source code for receiving the streaming video is given below

```
void player::on_actionNETWORK_STREAM_triggered()
{
QString url= QInputDialog::getText(this,tr("Open Url"),tr("Enter the URL you want to play"));

if(url.isEmpty())
return;
else
{
m_media=new VlcMedia(url,m_instance);
playlist.append(url);
m_mediaList->addMedia(m_media);
m_player->open(m_media);
}
}
```
To receive the streaming video I just put the url of that video into the new ```VlcMedia``` instance but don't know how to stream a video.

While reading the documentation of the ```VLC-QT``` wrapper I read that it have one ```class``` named ```VlcVideoStream ``` but I am not getting how to use that class to do the streaming. The link of the documentation of this ```class``` is given below

https://vlc-qt.tano.si/reference/1.1/cl ... ideostream

Return to “Development around libVLC”

Who is online

Users browsing this forum: No registered users and 5 guests