Get aspect ratio of a video in script
#1
Question 
Hi!
I was wondering if there is any way to get the aspect ratio of a video that is about to play (or playing). The thing is, I would like to create a script that changes the zoom on projector based on the aspect ratio, but if I can't get it in a python script, I wont bother.

I've looked a bit at the Python API but could not find anything that seems to fit my requirements. Still, I am hoping that there is a way...
Does anybody know?

I have found the information I want within the XBMC sources (CStreamDetails holds the information), but the question is if it is exposed via the Python API.

Otherwise I might want to extend the Python API to allow me to do this, but that makes this project a bit (or much) more complicated....

Cheers,
Mikael
Reply
#2
info label is videoplayer.videoaspect. just grab that, you might have to use a json call.
Reply

Logout Mark Read Team Forum Stats Members Help
Get aspect ratio of a video in script0