diff options
author | Christian Gmeiner <christian.gmeiner@gmail.com> | 2009-12-02 20:53:48 +0100 |
---|---|---|
committer | Christian Gmeiner <christian.gmeiner@gmail.com> | 2009-12-02 20:53:48 +0100 |
commit | 7f036330bc7ac560cbcdb1583980b9a1d068a299 (patch) | |
tree | 183a4385f54c2b316cccf9d9101190e003123270 | |
parent | 0c7b22bab46d63a0aa37039c76038fe9af3dadbe (diff) | |
download | vdr-plugin-dxr3-7f036330bc7ac560cbcdb1583980b9a1d068a299.tar.gz vdr-plugin-dxr3-7f036330bc7ac560cbcdb1583980b9a1d068a299.tar.bz2 |
implement GetVideoSize (>= vdr 1.7.10)
first commit of a handfull to get a good >= vdr 1.7.10 support.
-rw-r--r-- | dxr3device.c | 14 | ||||
-rw-r--r-- | dxr3device.h | 4 |
2 files changed, 18 insertions, 0 deletions
diff --git a/dxr3device.c b/dxr3device.c index e7d469e..bdf0a91 100644 --- a/dxr3device.c +++ b/dxr3device.c @@ -216,6 +216,20 @@ int cDxr3Device::PlayAudio(const uchar *Data, int Length, uchar Id) } } +#if VDRVERSNUM >= 10710 +void cDxr3Device::GetVideoSize(int &Width, int &Height, double &VideoAspect) +{ + cDxr3Interface::instance()->dimension((uint32_t&)Width, (uint32_t&)Height); + uint32_t aspect = cDxr3Interface::instance()->GetAspectRatio(); + + if (aspect == EM8300_ASPECTRATIO_4_3) { + VideoAspect = 1.33333f; + } else { + VideoAspect = 1.77778f; + } +} +#endif + // additional functions // ================================== diff --git a/dxr3device.h b/dxr3device.h index ebdbcda..b382910 100644 --- a/dxr3device.h +++ b/dxr3device.h @@ -59,6 +59,10 @@ public: virtual int PlayVideo(const uchar *Data, int Length); virtual int PlayAudio(const uchar *Data, int Length, uchar Id); +#if VDRVERSNUM >= 10710 + virtual void GetVideoSize(int &Width, int &Height, double &VideoAspect); +#endif + // additional functions virtual void SetVideoFormat(bool VideoFormat16_9); virtual void SetVolumeDevice(int Volume); |