[Libvlcsharp] How to feed libvlcsharp with data[] stream

This forum is about all development around libVLC.
cbn
New Cone
New Cone
Posts: 2
Joined: 06 Dec 2021 09:33

[Libvlcsharp] How to feed libvlcsharp with data[] stream

Postby cbn » 06 Dec 2021 09:37

Hello guys

I have an app in vb.net (winForms) that I want to play a valid TS with the video & audio PIDs. It works fine if I stream it using TCP/UDP protocol from the app itself, but I want to do it without doing a network stream.

I see this can be doing using StreamMediaInput, but I don't know how to do it right.

I have this:

Code: Select all

Dim vlc_memorystream as stream Private Sub WriteStream(ByVal Data() As Byte, ByVal len As Integer) 'Data() array is the video TS (MPEG-2) (188 bytes len) vlc_memorystream.Write(Data, 0, len) End Sub

Doing stream to TCP to a libvlcsharp is ok, how I can doing it directly passing the Data() array to libvlcsharp?

The problem is the buffer. It plays well few seconds and then it stops playback. How I can handle this? It seems that memory that are in vlc_memorystream aren't reset when is needed..

I'm a bit newbie in this things, so a help will be very welcome :-)

Thank you.

mfkl
Developer
Developer
Posts: 740
Joined: 13 Jun 2017 10:41

Re: [Libvlcsharp] How to feed libvlcsharp with data[] stream

Postby mfkl » 06 Dec 2021 09:45

Can you share logs and a fully reproducible sample please?
https://mfkl.github.io

cbn
New Cone
New Cone
Posts: 2
Joined: 06 Dec 2021 09:33

Re: [Libvlcsharp] How to feed libvlcsharp with data[] stream

Postby cbn » 06 Dec 2021 10:18

Can you share logs and a fully reproducible sample please?
Hello,

The stream is a DVB-S. It works well when this stream is sent to TCP to the libvlcsharp video player, but fails using StreamMediaInput.

Here's the logs: https://zerobin.net/?11a1ab641151a262#4 ... iyLAneuQU=

mfkl
Developer
Developer
Posts: 740
Joined: 13 Jun 2017 10:41

Re: [Libvlcsharp] How to feed libvlcsharp with data[] stream

Postby mfkl » 07 Dec 2021 11:35

can you share a way for us to reproduce easily please? e.g. a minimal git repository
https://mfkl.github.io


Return to “Development around libVLC”

Who is online

Users browsing this forum: No registered users and 10 guests