[LibVLC in C] How to save stream to file during playback?

This forum is about all development around libVLC.
derjanni
New Cone
New Cone
Posts: 5
Joined: 14 Jan 2017 22:01

[LibVLC in C] How to save stream to file during playback?

Postby derjanni » 07 Feb 2017 11:44

Hi folks,

I have my IPTV GUI application pretty much working now with LibVLC and SDL with all my overlay stuff.
Now I want to allow the user to record the streaming video on request during playback.

How do I tell LibVLC to write the stream to file in a specified format after libvlc_media_player_play is already called?

My thoughts so far are:
a) Bring up a new VLC instance that writes to disk and release it when user stops recording, but could cause difference in what's rendered in the main instance due to buffering
b) Write the frames and the audio received in the callbacks directly to a media file, but requires raw media encoding and somewhat bypasses libVLC

Many thanks in advance!

Jan

Return to “Development around libVLC”

Who is online

Users browsing this forum: No registered users and 8 guests