I have created vlcControl added on my windows form. I would like to know how can get rid of black bars on my vlc videos (image consumes black space). An example is shown below:
I have tried the line vlc --aspect-ratio 16:9 -L -f /directory/to/file/filename.
The line changes the aspect ratio but did not work as expected. I have tried the following lines of code:
Line 1:
vlcCustomer.Play(new Uri("rtsp://192.168.1.10/2/media/video1"), ":network-caching=50 :aspect-ratio=16:9 -L -f /directory/to/file/filename");
Line 2:
vlcCustomer.Play(new Uri("rtsp://192.168.1.10/2/media/video1"), ":network-caching=50 vlc --aspect-ratio 16:9 -L -f /directory/to/file/filename");
No need to use CLI args for this, libvlc has an API for changing aspect ratio and it is available in Vlc.DotNet. Example: https://github.com/ZeBobo5/Vlc.DotNet/blob/f0d3e2aca37500ccd2710c8b9b286ccc485f1636/src/Samples/Samples.WinForms.Advanced/Sample.cs#L167