[vlc-commits] omxil: Handle parameter changes for OMX_IndexParamAudioPcm as output reconfiguration

Martin Storsjö git at videolan.org
Tue Jul 9 13:31:09 CEST 2013


vlc | branch: master | Martin Storsjö <martin at martin.st> | Tue Jul  9 14:27:54 2013 +0300| [229d18843760b158eed5102267bc003c1c65b42d] | committer: Martin Storsjö

omxil: Handle parameter changes for OMX_IndexParamAudioPcm as output reconfiguration

This fixes the output sample rate when decoding with
OMX.Nvidia.aac.decoder (such as on nexus 7), possibly also for other
audio codecs on the same class of devices, possibly also for audio
codecs on other OMX implementations.

Signed-off-by: Martin Storsjö <martin at martin.st>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=229d18843760b158eed5102267bc003c1c65b42d
---

 modules/codec/omxil/omxil.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/modules/codec/omxil/omxil.c b/modules/codec/omxil/omxil.c
index bad3ad1..c49b7e5 100644
--- a/modules/codec/omxil/omxil.c
+++ b/modules/codec/omxil/omxil.c
@@ -1594,7 +1594,8 @@ static OMX_ERRORTYPE OmxEventHandler( OMX_HANDLETYPE omx_handle,
         break;
 
     case OMX_EventPortSettingsChanged:
-        if( data_2 == 0 || data_2 == OMX_IndexParamPortDefinition )
+        if( data_2 == 0 || data_2 == OMX_IndexParamPortDefinition ||
+            data_2 == OMX_IndexParamAudioPcm )
         {
             OMX_BUFFERHEADERTYPE *sentinel;
             for(i = 0; i < p_sys->ports; i++)



More information about the vlc-commits mailing list