MediaPlayer media type set to Video when opening a text file
Summary
I need in my application to be able to disallow a user to load a file which is not a proper video file. Unfortunately LibVLC allow to load not solely video files but also images and texts (which could be subtitles for videos). Now I was trying to refer to the track type of the loaded file to check if it is of Text type and there are also no video track types within the provided file. Unfortunately though the track type for a simple text file is set to Video instead.
Minimal project and steps to reproduce
https://gitlab.com/midium/libvlc-test
It uses latest available LibVLC version. Simply run the project press the button, select any text file and check the values the label below will be filled with.
What is the current bug behavior?
The track type value is Text
What is the expected correct behavior?
I would expect a text file to be marked as a Text track type
Does it work on other plaforms? Does it work with the official VLC apps?
Unfortunately I don't know this
Environment
- OS: Windows 10 Enterprice 64 bit
- Version 2004
- Device: Dell Laptop
- LibVLC version and architecture: 3.0.11 both x86 or x64
- LibVLCSharp version: 3.4.8