diff options
author | Thomas Reufer <thomas@reufer.ch> | 2014-02-10 21:53:25 +0100 |
---|---|---|
committer | Thomas Reufer <thomas@reufer.ch> | 2014-02-10 21:53:25 +0100 |
commit | 0094472cda6eefa9b5363ad844daf0fcfd00c326 (patch) | |
tree | b577f931820ef3899da856f9ccd0de04f4c8ffa8 /omx.h | |
parent | 88f137d194b1768344e954a1b1d35fb1fce03df9 (diff) | |
download | vdr-plugin-rpihddevice-0.0.8.tar.gz vdr-plugin-rpihddevice-0.0.8.tar.bz2 |
2014-02-10: Version 0.0.80.0.8
-------------------------
- new:
- image grabbing
- implemented proper handling in case of buffer stall
- reporting video size
- support letter box and center cut out set by VDR
- support video scaling
- fixed:
- increased number of audio buffer to fix replay issues with PES recordings
- return correct number of audio bytes written from PlayAudio()
- fixed start up in audio only mode
- fixed still image with deinterlacer
- fixed crash during deinitialization
- fixed crash when copying 5.1 PCM audio
- use cThread::mutex for locking
- implement cOvgOsd::SetAreas() and cOvgOsd::SetActive()
- audio codec clean up, drop AAC-LATM and rename ADTS to AAC
- audio decoding thread clean up
- known issues
- StillImage() will cause buffer stall
- artifacts with StillImage() and PES recordings
- speed to fast when fast replaying audio only recordings
Diffstat (limited to 'omx.h')
-rw-r--r-- | omx.h | 26 |
1 files changed, 21 insertions, 5 deletions
@@ -9,7 +9,7 @@ #include <queue> #include <vdr/thread.h> -#include "types.h" +#include "tools.h" extern "C" { @@ -26,6 +26,8 @@ public: int Init(void); int DeInit(void); + void SetBufferStallCallback(void (*onBufferStall)(void*), void* data); + static OMX_TICKS ToOmxTicks(int64_t val); static int64_t FromOmxTicks(OMX_TICKS &ticks); static void PtsToTicks(uint64_t pts, OMX_TICKS &ticks); @@ -50,7 +52,8 @@ public: enum eClockReference { eClockRefAudio, - eClockRefVideo + eClockRefVideo, + eClockRefNone }; void SetClockReference(eClockReference clockReference); @@ -76,6 +79,10 @@ public: eDataUnitType dataUnit = eArbitraryStreamSection); int SetupAudioRender(cAudioCodec::eCodec outputFormat, int channels, cAudioPort::ePort audioPort, int samplingRate = 0); + void GetVideoSize(int &width, int &height, bool &interlaced); + + void SetDisplayMode(bool letterbox, bool noaspect); + void SetDisplayRegion(int x, int y, int width, int height); OMX_BUFFERHEADERTYPE* GetAudioBuffer(uint64_t pts = 0); OMX_BUFFERHEADERTYPE* GetVideoBuffer(uint64_t pts = 0); @@ -114,7 +121,9 @@ private: COMPONENT_T *m_comp[cOmx::eNumComponents + 1]; TUNNEL_T m_tun[cOmx::eNumTunnels + 1]; - cMutex *m_mutex; + int m_videoWidth; + int m_videoHeight; + bool m_videoInterlaced; bool m_setAudioStartTime; bool m_setVideoStartTime; @@ -125,14 +134,21 @@ private: eClockReference m_clockReference; - cCondWait *m_portEventReady; - std::queue<unsigned int> *m_portEvents; + cCondWait *m_eventReady; + std::queue<unsigned int> *m_portEvents; + bool m_stallEvent; + void (*m_onBufferStall)(void*); + void *m_onBufferStallData; + void HandlePortSettingsChanged(unsigned int portId); + void SetBufferStall(int delayMs); + bool IsBufferStall(void); static void OnBufferEmpty(void *instance, COMPONENT_T *comp); static void OnPortSettingsChanged(void *instance, COMPONENT_T *comp, OMX_U32 data); static void OnEndOfStream(void *instance, COMPONENT_T *comp, OMX_U32 data); static void OnError(void *instance, COMPONENT_T *comp, OMX_U32 data); + static void OnConfigChanged(void *instance, COMPONENT_T *comp, OMX_U32 data); }; |