pedroSG94 / vlc-example-streamplayer

Example code how to play a stream with VLC
GNU General Public License v3.0
229 stars 93 forks source link

3:4 Aspect ratio issue #9

Open usman-afzal opened 6 years ago

usman-afzal commented 6 years ago

@pedroSG94 I am playing video having aspect ratio 3:4 using surface view and its stretching video. Can you help me how can I play all type of aspect ratios.

pedroSG94 commented 6 years ago

This library force vlc fullscreen video mode in this line: https://github.com/pedroSG94/vlc-example-streamplayer/blob/master/pedrovlc/src/main/java/com/pedro/vlc/VlcVideoLibrary.java#L114

You can change this mode using VLC documentation or try deleting it. VLC documentation (go to video option section for more info): https://wiki.videolan.org/Documentation:Command_line/

usman-afzal commented 6 years ago

@pedroSG94 I want to adjust player according to its best aspect fit ratio. How I can do that?

usman-afzal commented 6 years ago

@pedroSG94 can you help me please on this?

pedroSG94 commented 6 years ago

If last modifications commented not work. The only way that I know is change surfaceview size to same aspect ratio than video reproduced.

usman-afzal commented 6 years ago

@pedroSG94 There can be multiple aspect ratio so can't fix the size.

pedroSG94 commented 6 years ago

You can try with an older version of VLC with this commit: https://github.com/pedroSG94/vlc-example-streamplayer/tree/38d3c8b3b148193625a918fa330a41de42eefe17

I don't know more. If the problem persist, maybe you can found more help in VLC forum: https://forum.videolan.org/