0

I want to use libVLC (C#) to browse network shares.

This works for me, but only for media files (images, videos, etc.)

    Media media = new Media(new Uri(networkPath));
    var parseTask = media.ParseAsync(_libVLC, MediaParseOptions.FetchNetwork);
    Debug.WriteLine($"media.ParseAsync result: {parseTask.GetAwaiter().GetResult()}");
    Debug.WriteLine($"media.SubItems.Count result: {media.SubItems.Count}");

Is there a flag or an alternative to Media class that scans for ALL files in the network share (e.g. txt, docx, pdf, odf files)?

I only need the file content as raw bytes, it is not necessary that libVLC understands the file format.

mihca
  • 997
  • 1
  • 10
  • 29

1 Answers1

2

VLC is made to play media, not to be a samba share browser.

I'd recommend that you try to look into the library they're using : https://github.com/sahlberg/libsmb2

Maybe you'll be able to use it through P/Invoke ?

cube45
  • 3,429
  • 2
  • 24
  • 35