Closed abbasiehsan1991 closed 11 months ago
The screenshot you linked is in portrait mode, but the video aspect ratio is landscape. It is expected that you see black bars on the top and bottom.
Hey, Thanks for your quick response. This is for the recording screen thing. the device is in the landscape too. But anyway I was pointing to the space from the left and right sides. As you can see the video is not filling the view port completely but the share button is at the top right side.
This is the same issue, the aspect ratio of the video causes the black bands. If you remove the toolbar at the top you'll see the black bars being smaller.
Question / Problem
Summary
I try to use full-screen mode, but when I play a video there is a big space to the left and right if the video with the screen. What I did is the same as the sample project btw. I used a FrameLayout for full screen.
What I've tried
My XML:
This is what I'm doing for going to full screen:
As you can see in the below video, when I click on the full-screen button, the video is not filling the screen size, but when the video reaches to the end it full fill the screen. I'm not this is a bug or something on purpose.
https://github.com/PierfrancescoSoffritti/android-youtube-player/assets/23223511/4a53ec74-2c89-454d-b09a-d8690bc8a36e