Page 1 of 1

Scale video to view size in Xamarin.Android not working

Posted: 05 Oct 2021 15:44
by SvenCarstensen
Hello all,

I am trying to play a RTP stream via LibVLC 3.5.0 and LibVLCSharp 3.2.0.1 in a Xamarin.Android app.

The playback itself works, but the video does not scale to the size of the window.
So I see in a view with 640 * 360 points only the lower left part of the video.

Has anyone had this problem and can possibly give me a tip?
I would appreciate the help of the forum very much!

Regards

Sven

Re: Scale video to view size in Xamarin.Android not working

Posted: 06 Oct 2021 04:11
by mfkl
Have you tried playing with the Scale and AspectRatio mediaplayer properties? Like this https://code.videolan.org/videolan/LibV ... Manager.cs

Re: Scale video to view size in Xamarin.Android not working

Posted: 06 Oct 2021 22:29
by RĂ©mi Denis-Courmont
With default settings, LibVLC automatically adjusts the video size to window area. But I don't know if that's implementable and correctly implemented on Android.

Maybe check if it works on X11.

Re: Scale video to view size in Xamarin.Android not working

Posted: 07 Oct 2021 09:49
by SvenCarstensen
Hi mfki,

thank you for your reply.
Have you tried playing with the Scale and AspectRatio mediaplayer properties? Like this https://code.videolan.org/videolan/LibV ... Manager.cs
Yes, i have tried both of them with no success :-(