mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-24 11:16:51 +00:00
Merge remote-tracking branch 'upstream/master' into openelec-settings
This commit is contained in:
commit
e16ff5606d
@ -1,5 +0,0 @@
|
||||
3.0.1
|
||||
- bump addon version
|
||||
|
||||
2.1.1
|
||||
- initial addon based on iperf-2.0.5
|
Binary file not shown.
Before Width: | Height: | Size: 2.3 KiB |
@ -1,23 +0,0 @@
|
||||
################################################################################
|
||||
# This file is part of OpenELEC - http://www.openelec.tv
|
||||
# Copyright (C) 2009-2012 Stephan Raue (stephan@openelec.tv)
|
||||
#
|
||||
# This Program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2, or (at your option)
|
||||
# any later version.
|
||||
#
|
||||
# This Program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with OpenELEC.tv; see the file COPYING. If not, write to
|
||||
# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA.
|
||||
# http://www.gnu.org/copyleft/gpl.html
|
||||
################################################################################
|
||||
|
||||
import os
|
||||
import sys
|
||||
import xbmcaddon
|
@ -22,5 +22,5 @@
|
||||
|
||||
. config/options $1
|
||||
|
||||
mkdir -p $ADDON_BUILD/$PKG_ADDON_ID/bin
|
||||
cp $PKG_BUILD/src/iperf $ADDON_BUILD/$PKG_ADDON_ID/bin
|
||||
mkdir -p $INSTALL/usr/bin/
|
||||
cp $PKG_BUILD/src/iperf $INSTALL/usr/bin
|
@ -28,11 +28,10 @@ PKG_URL="$SOURCEFORGE_SRC/iperf/files/$PKG_NAME-$PKG_VERSION.tar.gz"
|
||||
PKG_DEPENDS=""
|
||||
PKG_BUILD_DEPENDS="toolchain $ICONV"
|
||||
PKG_PRIORITY="optional"
|
||||
PKG_SECTION="network/testing"
|
||||
PKG_SECTION="debug/tools"
|
||||
PKG_SHORTDESC="iperf: A modern alternative for measuring maximum TCP and UDP bandwidth performance"
|
||||
PKG_LONGDESC="Iperf was developed by NLANR/DAST as a modern alternative for measuring maximum TCP and UDP bandwidth performance. Iperf allows the tuning of various parameters and UDP characteristics. Iperf reports bandwidth, delay jitter, datagram loss."
|
||||
|
||||
PKG_IS_ADDON="yes"
|
||||
PKG_ADDON_TYPE="xbmc.python.script"
|
||||
PKG_IS_ADDON="no"
|
||||
|
||||
PKG_AUTORECONF="yes"
|
@ -25,7 +25,7 @@ PKG_ARCH="any"
|
||||
PKG_LICENSE="GPL"
|
||||
PKG_SITE="http://www.openelec.tv"
|
||||
PKG_URL=""
|
||||
PKG_DEPENDS="acpica cpuid dmidecode dstat evtest gdb hddtemp htop i2c-tools iftop pmtools powertop smem strace wireless_tools tcpdump"
|
||||
PKG_DEPENDS="acpica cpuid dmidecode dstat evtest gdb hddtemp htop i2c-tools iftop pmtools powertop smem strace wireless_tools tcpdump iperf"
|
||||
PKG_BUILD_DEPENDS="toolchain"
|
||||
PKG_PRIORITY="optional"
|
||||
PKG_SECTION="debug"
|
||||
|
@ -38,5 +38,5 @@ cd $PKG_BUILD
|
||||
--without-z \
|
||||
--without-x \
|
||||
|
||||
make
|
||||
$MAKEINSTALL
|
||||
make -C src
|
||||
$MAKEINSTALL -C src
|
||||
|
@ -19,7 +19,7 @@
|
||||
################################################################################
|
||||
|
||||
PKG_NAME="xbmc-theme-Confluence"
|
||||
PKG_VERSION="12.0.4"
|
||||
PKG_VERSION="12.0.5"
|
||||
PKG_REV="1"
|
||||
PKG_ARCH="any"
|
||||
PKG_LICENSE="GPL"
|
||||
|
@ -19,7 +19,7 @@
|
||||
################################################################################
|
||||
|
||||
PKG_NAME="xbmc"
|
||||
PKG_VERSION="12.0.4"
|
||||
PKG_VERSION="12.0.5"
|
||||
PKG_REV="1"
|
||||
PKG_ARCH="any"
|
||||
PKG_LICENSE="GPL"
|
||||
|
@ -1,144 +0,0 @@
|
||||
From f2faaa846e03cbcc1ba11f09baad690c792035c5 Mon Sep 17 00:00:00 2001
|
||||
From: fritsch <Peter.Fruehberger@gmail.com>
|
||||
Date: Thu, 28 Feb 2013 00:17:03 +0100
|
||||
Subject: [PATCH] AE: Revisit Device Opening. Try to set periodSize of 100 ms
|
||||
and BufferSize of 800 ms
|
||||
|
||||
---
|
||||
xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp | 98 ++++++++++++++++-----------
|
||||
1 file changed, 59 insertions(+), 39 deletions(-)
|
||||
|
||||
diff --git a/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp b/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp
|
||||
index fe40d17..821bd2e 100644
|
||||
--- a/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp
|
||||
+++ b/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp
|
||||
@@ -38,7 +38,6 @@
|
||||
#endif
|
||||
|
||||
#define ALSA_OPTIONS (SND_PCM_NONBLOCK | SND_PCM_NO_AUTO_FORMAT | SND_PCM_NO_AUTO_CHANNELS | SND_PCM_NO_AUTO_RESAMPLE)
|
||||
-#define ALSA_PERIODS 16
|
||||
|
||||
#define ALSA_MAX_CHANNELS 16
|
||||
static enum AEChannel ALSAChannelMap[ALSA_MAX_CHANNELS + 1] = {
|
||||
@@ -328,59 +327,80 @@ bool CAESinkALSA::InitializeHW(AEAudioFormat &format)
|
||||
}
|
||||
}
|
||||
|
||||
- unsigned int periods;
|
||||
-
|
||||
snd_pcm_uframes_t periodSize, bufferSize;
|
||||
snd_pcm_hw_params_get_buffer_size_max(hw_params, &bufferSize);
|
||||
+ snd_pcm_hw_params_get_period_size_max(hw_params, &periodSize, NULL);
|
||||
+
|
||||
+ /*
|
||||
+ We want to make sure, that we have approx 500 to 800 ms Buffer with
|
||||
+ a periodSize of approx 100 ms.
|
||||
+ It is calced:
|
||||
+ periodSize = sampleRate / 10
|
||||
+ buffersize = periodSize * 1 frame * 8.
|
||||
+ */
|
||||
+ periodSize = std::min(periodSize, (snd_pcm_uframes_t) sampleRate / 10);
|
||||
+ bufferSize = std::min(bufferSize, (snd_pcm_uframes_t) periodSize * 8);
|
||||
+
|
||||
+ /*
|
||||
+ According to upstream we should set buffer size first - so make sure it is always at least
|
||||
+ double of period size to not get underruns
|
||||
+ */
|
||||
+ periodSize = std::min(periodSize, bufferSize / 2);
|
||||
|
||||
- bufferSize = std::min(bufferSize, (snd_pcm_uframes_t)8192);
|
||||
- periodSize = bufferSize / ALSA_PERIODS;
|
||||
- periods = ALSA_PERIODS;
|
||||
-
|
||||
- CLog::Log(LOGDEBUG, "CAESinkALSA::InitializeHW - Request: periodSize %lu, periods %u, bufferSize %lu", periodSize, periods, bufferSize);
|
||||
+ CLog::Log(LOGDEBUG, "CAESinkALSA::InitializeHW - Request: periodSize %lu, bufferSize %lu", periodSize, bufferSize);
|
||||
|
||||
- /* work on a copy of the hw params */
|
||||
snd_pcm_hw_params_t *hw_params_copy;
|
||||
snd_pcm_hw_params_alloca(&hw_params_copy);
|
||||
-
|
||||
- /* try to set the buffer size then the period size */
|
||||
- snd_pcm_hw_params_copy(hw_params_copy, hw_params);
|
||||
- snd_pcm_hw_params_set_buffer_size_near(m_pcm, hw_params_copy, &bufferSize);
|
||||
- snd_pcm_hw_params_set_period_size_near(m_pcm, hw_params_copy, &periodSize, NULL);
|
||||
- snd_pcm_hw_params_set_periods_near (m_pcm, hw_params_copy, &periods , NULL);
|
||||
- if (snd_pcm_hw_params(m_pcm, hw_params_copy) != 0)
|
||||
+ snd_pcm_hw_params_copy(hw_params_copy, hw_params); // copy what we have and is already working
|
||||
+
|
||||
+ // first trying bufferSize, PeriodSize
|
||||
+ // for more info see here:
|
||||
+ // http://mailman.alsa-project.org/pipermail/alsa-devel/2009-September/021069.html
|
||||
+ // the last three tries are done as within pulseaudio
|
||||
+
|
||||
+ // backup periodSize and bufferSize first. Restore them after every failed try
|
||||
+ snd_pcm_uframes_t periodSizeTemp, bufferSizeTemp;
|
||||
+ periodSizeTemp = periodSize;
|
||||
+ bufferSizeTemp = bufferSize;
|
||||
+ if (snd_pcm_hw_params_set_buffer_size_near(m_pcm, hw_params_copy, &bufferSize) != 0
|
||||
+ || snd_pcm_hw_params_set_period_size_near(m_pcm, hw_params_copy, &periodSize, NULL) != 0
|
||||
+ || snd_pcm_hw_params(m_pcm, hw_params_copy) != 0)
|
||||
{
|
||||
- /* try to set the period size then the buffer size */
|
||||
- snd_pcm_hw_params_copy(hw_params_copy, hw_params);
|
||||
- snd_pcm_hw_params_set_period_size_near(m_pcm, hw_params_copy, &periodSize, NULL);
|
||||
- snd_pcm_hw_params_set_buffer_size_near(m_pcm, hw_params_copy, &bufferSize);
|
||||
- snd_pcm_hw_params_set_periods_near (m_pcm, hw_params_copy, &periods , NULL);
|
||||
- if (snd_pcm_hw_params(m_pcm, hw_params_copy) != 0)
|
||||
+ bufferSize = bufferSizeTemp;
|
||||
+ periodSize = periodSizeTemp;
|
||||
+ // retry with PeriodSize, bufferSize
|
||||
+ snd_pcm_hw_params_copy(hw_params_copy, hw_params); // restore working copy
|
||||
+ if (snd_pcm_hw_params_set_period_size_near(m_pcm, hw_params_copy, &periodSize, NULL) != 0
|
||||
+ || snd_pcm_hw_params_set_buffer_size_near(m_pcm, hw_params_copy, &bufferSize) != 0
|
||||
+ || snd_pcm_hw_params(m_pcm, hw_params_copy) != 0)
|
||||
{
|
||||
- /* try to just set the buffer size */
|
||||
- snd_pcm_hw_params_copy(hw_params_copy, hw_params);
|
||||
- snd_pcm_hw_params_set_buffer_size_near(m_pcm, hw_params_copy, &bufferSize);
|
||||
- snd_pcm_hw_params_set_periods_near (m_pcm, hw_params_copy, &periods , NULL);
|
||||
- if (snd_pcm_hw_params(m_pcm, hw_params_copy) != 0)
|
||||
+ // try only periodSize
|
||||
+ periodSize = periodSizeTemp;
|
||||
+ snd_pcm_hw_params_copy(hw_params_copy, hw_params); // restore working copy
|
||||
+ if(snd_pcm_hw_params_set_period_size_near(m_pcm, hw_params_copy, &periodSize, NULL) != 0
|
||||
+ || snd_pcm_hw_params(m_pcm, hw_params_copy) != 0)
|
||||
{
|
||||
- /* try to just set the period size */
|
||||
- snd_pcm_hw_params_copy(hw_params_copy, hw_params);
|
||||
- snd_pcm_hw_params_set_period_size_near(m_pcm, hw_params_copy, &periodSize, NULL);
|
||||
- snd_pcm_hw_params_set_periods_near (m_pcm, hw_params_copy, &periods , NULL);
|
||||
- if (snd_pcm_hw_params(m_pcm, hw_params_copy) != 0)
|
||||
+ // try only BufferSize
|
||||
+ bufferSize = bufferSizeTemp;
|
||||
+ snd_pcm_hw_params_copy(hw_params_copy, hw_params); // restory working copy
|
||||
+ if (snd_pcm_hw_params_set_buffer_size_near(m_pcm, hw_params_copy, &bufferSize) != 0
|
||||
+ || snd_pcm_hw_params(m_pcm, hw_params_copy) != 0)
|
||||
{
|
||||
- CLog::Log(LOGERROR, "CAESinkALSA::InitializeHW - Failed to set the parameters");
|
||||
- return false;
|
||||
+ // set default that Alsa would choose
|
||||
+ CLog::Log(LOGWARNING, "CAESinkAlsa::IntializeHW - Using default alsa values - set failed");
|
||||
+ if (snd_pcm_hw_params(m_pcm, hw_params) != 0)
|
||||
+ {
|
||||
+ CLog::Log(LOGDEBUG, "CAESinkALSA::InitializeHW - Could not init a valid sink");
|
||||
+ return false;
|
||||
+ }
|
||||
}
|
||||
}
|
||||
+ // reread values when alsa default was kept
|
||||
+ snd_pcm_get_params(m_pcm, &bufferSize, &periodSize);
|
||||
}
|
||||
}
|
||||
-
|
||||
- snd_pcm_hw_params_get_period_size(hw_params_copy, &periodSize, NULL);
|
||||
- snd_pcm_hw_params_get_buffer_size(hw_params_copy, &bufferSize);
|
||||
|
||||
-
|
||||
- CLog::Log(LOGDEBUG, "CAESinkALSA::InitializeHW - Got: periodSize %lu, periods %u, bufferSize %lu", periodSize, periods, bufferSize);
|
||||
+ CLog::Log(LOGDEBUG, "CAESinkALSA::InitializeHW - Got: periodSize %lu, bufferSize %lu", periodSize, bufferSize);
|
||||
|
||||
/* set the format parameters */
|
||||
format.m_sampleRate = sampleRate;
|
||||
--
|
||||
1.7.10
|
||||
|
@ -1,156 +0,0 @@
|
||||
From 632825b71a2bc248eb5705666debc5f7653d6878 Mon Sep 17 00:00:00 2001
|
||||
From: popcornmix <popcornmix@gmail.com>
|
||||
Date: Sun, 24 Feb 2013 15:25:49 +0000
|
||||
Subject: [PATCH] [rbp] Fix for stuttery video when seeking before zero
|
||||
|
||||
There are a few issues with seeking I found.
|
||||
We weren't correctly setting OMX_BUFFERFLAG_TIME_UNKNOWN on the first frame after a seek which could make the GPU think video was at 0 and audio at a much larger offset.
|
||||
A full video fifo (to GPU) stops any higher priority messages from being received which can stall a seek and the flush message doesn't get through. Use m_flush to discard the video packet that doesn't fit.
|
||||
We get an audio frame through with unknown pts/dts after the flush, but before the GENERAL_RESYNC when seeking. This was given to GPU and was perhaps 30 seconds out from the following packets and that throws off the timing between audio and video streams. Keeping m_flush true until the GENERAL_RESYNC discards this frame. Hopefully that is safe.
|
||||
---
|
||||
xbmc/cores/omxplayer/OMXPlayerAudio.cpp | 13 ++-----------
|
||||
xbmc/cores/omxplayer/OMXPlayerAudio.h | 1 -
|
||||
xbmc/cores/omxplayer/OMXPlayerVideo.cpp | 7 +++++++
|
||||
xbmc/cores/omxplayer/OMXPlayerVideo.h | 1 +
|
||||
xbmc/cores/omxplayer/OMXVideo.cpp | 11 +++--------
|
||||
5 files changed, 13 insertions(+), 20 deletions(-)
|
||||
|
||||
diff --git a/xbmc/cores/omxplayer/OMXPlayerAudio.cpp b/xbmc/cores/omxplayer/OMXPlayerAudio.cpp
|
||||
index 58c3a4f..16ea6c3 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXPlayerAudio.cpp
|
||||
+++ b/xbmc/cores/omxplayer/OMXPlayerAudio.cpp
|
||||
@@ -369,13 +369,9 @@ bool OMXPlayerAudio::Decode(DemuxPacket *pkt, bool bDropPacket)
|
||||
|
||||
while(!m_bStop)
|
||||
{
|
||||
+ // discard if flushing as clocks may be stopped and we'll never submit it
|
||||
if(m_flush)
|
||||
- {
|
||||
- CSingleLock lock(m_flushLock);
|
||||
- m_flush = false;
|
||||
- lock.Leave();
|
||||
break;
|
||||
- }
|
||||
|
||||
if(m_omxAudio.GetSpace() < (unsigned int)pkt->iSize)
|
||||
{
|
||||
@@ -420,12 +416,7 @@ bool OMXPlayerAudio::Decode(DemuxPacket *pkt, bool bDropPacket)
|
||||
while(!m_bStop)
|
||||
{
|
||||
if(m_flush)
|
||||
- {
|
||||
- CSingleLock lock(m_flushLock);
|
||||
- m_flush = false;
|
||||
- lock.Leave();
|
||||
break;
|
||||
- }
|
||||
|
||||
if(m_omxAudio.GetSpace() < (unsigned int)pkt->iSize)
|
||||
{
|
||||
@@ -544,6 +535,7 @@ void OMXPlayerAudio::Process()
|
||||
}
|
||||
else
|
||||
CLog::Log(LOGDEBUG, "COMXPlayerAudio - CDVDMsg::GENERAL_RESYNC(%f, 0)", m_audioClock);
|
||||
+ m_flush = false;
|
||||
}
|
||||
else if (pMsg->IsType(CDVDMsg::GENERAL_RESET))
|
||||
{
|
||||
@@ -627,7 +619,6 @@ void OMXPlayerAudio::Process()
|
||||
|
||||
void OMXPlayerAudio::Flush()
|
||||
{
|
||||
- CSingleLock lock(m_flushLock);
|
||||
m_flush = true;
|
||||
m_messageQueue.Flush();
|
||||
m_messageQueue.Put( new CDVDMsg(CDVDMsg::GENERAL_FLUSH), 1);
|
||||
diff --git a/xbmc/cores/omxplayer/OMXPlayerAudio.h b/xbmc/cores/omxplayer/OMXPlayerAudio.h
|
||||
index d10133e..d6083e9 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXPlayerAudio.h
|
||||
+++ b/xbmc/cores/omxplayer/OMXPlayerAudio.h
|
||||
@@ -42,7 +42,6 @@
|
||||
class OMXPlayerAudio : public CThread
|
||||
{
|
||||
protected:
|
||||
- CCriticalSection m_flushLock;
|
||||
CDVDMessageQueue m_messageQueue;
|
||||
CDVDMessageQueue &m_messageParent;
|
||||
|
||||
diff --git a/xbmc/cores/omxplayer/OMXPlayerVideo.cpp b/xbmc/cores/omxplayer/OMXPlayerVideo.cpp
|
||||
index 5a6e31e..5dd908b 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXPlayerVideo.cpp
|
||||
+++ b/xbmc/cores/omxplayer/OMXPlayerVideo.cpp
|
||||
@@ -122,6 +122,7 @@ bool OMXPlayerVideo::OpenStream(CDVDStreamInfo &hints)
|
||||
m_Deinterlace = ( g_settings.m_currentVideoSettings.m_DeinterlaceMode == VS_DEINTERLACEMODE_OFF ) ? false : true;
|
||||
m_hdmi_clock_sync = (g_guiSettings.GetInt("videoplayer.adjustrefreshrate") != ADJUST_REFRESHRATE_OFF);
|
||||
m_started = false;
|
||||
+ m_flush = false;
|
||||
m_stalled = m_messageQueue.GetPacketCount(CDVDMsg::DEMUXER_PACKET) == 0;
|
||||
m_autosync = 1;
|
||||
m_iSleepEndTime = DVD_NOPTS_VALUE;
|
||||
@@ -593,6 +594,7 @@ void OMXPlayerVideo::Process()
|
||||
m_omxVideo.Reset();
|
||||
m_av_clock->OMXReset(false);
|
||||
m_av_clock->UnLock();
|
||||
+ m_flush = false;
|
||||
}
|
||||
else if (pMsg->IsType(CDVDMsg::PLAYER_SETSPEED))
|
||||
{
|
||||
@@ -633,6 +635,10 @@ void OMXPlayerVideo::Process()
|
||||
|
||||
while (!m_bStop)
|
||||
{
|
||||
+ // discard if flushing as clocks may be stopped and we'll never submit it
|
||||
+ if (m_flush)
|
||||
+ break;
|
||||
+
|
||||
if((int)m_omxVideo.GetFreeSpace() < pPacket->iSize)
|
||||
{
|
||||
Sleep(10);
|
||||
@@ -697,6 +703,7 @@ void OMXPlayerVideo::Process()
|
||||
|
||||
void OMXPlayerVideo::Flush()
|
||||
{
|
||||
+ m_flush = true;
|
||||
m_messageQueue.Flush();
|
||||
m_messageQueue.Put(new CDVDMsg(CDVDMsg::GENERAL_FLUSH), 1);
|
||||
}
|
||||
diff --git a/xbmc/cores/omxplayer/OMXPlayerVideo.h b/xbmc/cores/omxplayer/OMXPlayerVideo.h
|
||||
index cf05c1f..7df1b0b 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXPlayerVideo.h
|
||||
+++ b/xbmc/cores/omxplayer/OMXPlayerVideo.h
|
||||
@@ -61,6 +61,7 @@ class OMXPlayerVideo : public CThread
|
||||
int m_audio_count;
|
||||
bool m_stalled;
|
||||
bool m_started;
|
||||
+ bool m_flush;
|
||||
std::string m_codecname;
|
||||
double m_droptime;
|
||||
double m_dropbase;
|
||||
diff --git a/xbmc/cores/omxplayer/OMXVideo.cpp b/xbmc/cores/omxplayer/OMXVideo.cpp
|
||||
index 3417286..4f11ff8 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXVideo.cpp
|
||||
+++ b/xbmc/cores/omxplayer/OMXVideo.cpp
|
||||
@@ -809,17 +809,12 @@ int COMXVideo::Decode(uint8_t *pData, int iSize, double dts, double pts)
|
||||
// only send dts on first frame to get nearly correct starttime
|
||||
if(pts == DVD_NOPTS_VALUE)
|
||||
pts = dts;
|
||||
- if(pts == DVD_NOPTS_VALUE)
|
||||
- omx_buffer->nFlags |= OMX_BUFFERFLAG_TIME_UNKNOWN;
|
||||
- omx_buffer->nFlags = OMX_BUFFERFLAG_STARTTIME;
|
||||
+ omx_buffer->nFlags |= OMX_BUFFERFLAG_STARTTIME;
|
||||
CLog::Log(LOGDEBUG, "OMXVideo::Decode VDec : setStartTime %f\n", (pts == DVD_NOPTS_VALUE ? 0.0 : pts) / DVD_TIME_BASE);
|
||||
m_av_clock->VideoStart(false);
|
||||
}
|
||||
- else
|
||||
- {
|
||||
- if(pts == DVD_NOPTS_VALUE)
|
||||
- omx_buffer->nFlags = OMX_BUFFERFLAG_TIME_UNKNOWN;
|
||||
- }
|
||||
+ if(pts == DVD_NOPTS_VALUE)
|
||||
+ omx_buffer->nFlags |= OMX_BUFFERFLAG_TIME_UNKNOWN;
|
||||
|
||||
omx_buffer->nTimeStamp = ToOMXTime((uint64_t)(pts == DVD_NOPTS_VALUE) ? 0 : pts);
|
||||
omx_buffer->nFilledLen = (demuxer_bytes > omx_buffer->nAllocLen) ? omx_buffer->nAllocLen : demuxer_bytes;
|
||||
--
|
||||
1.7.10
|
||||
|
@ -1,46 +0,0 @@
|
||||
From eb4ae32119a83716d7fb930381d2848c02383cea Mon Sep 17 00:00:00 2001
|
||||
From: fritsch <peter.fruehberger@gmail.com>
|
||||
Date: Wed, 6 Mar 2013 07:52:59 +0100
|
||||
Subject: [PATCH] AE: Fix menu sounds by decreasing buffer(max 200 ms) and
|
||||
periodSize(50 ms)
|
||||
|
||||
---
|
||||
xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp | 19 ++++++++++---------
|
||||
1 file changed, 10 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp b/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp
|
||||
index 821bd2e..21891a5 100644
|
||||
--- a/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp
|
||||
+++ b/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp
|
||||
@@ -332,18 +332,19 @@ bool CAESinkALSA::InitializeHW(AEAudioFormat &format)
|
||||
snd_pcm_hw_params_get_period_size_max(hw_params, &periodSize, NULL);
|
||||
|
||||
/*
|
||||
- We want to make sure, that we have approx 500 to 800 ms Buffer with
|
||||
- a periodSize of approx 100 ms.
|
||||
- It is calced:
|
||||
- periodSize = sampleRate / 10
|
||||
- buffersize = periodSize * 1 frame * 8.
|
||||
+ We want to make sure, that we have max 200 ms Buffer with
|
||||
+ a periodSize of approx 50 ms. Choosing a higher bufferSize
|
||||
+ will cause problems with menu sounds. Buffer will be increased
|
||||
+ after those are fixed.
|
||||
+ periodSize = sampleRate / 20
|
||||
+ bufferSize = periodSize * 1 frame * 4.
|
||||
*/
|
||||
- periodSize = std::min(periodSize, (snd_pcm_uframes_t) sampleRate / 10);
|
||||
- bufferSize = std::min(bufferSize, (snd_pcm_uframes_t) periodSize * 8);
|
||||
+ periodSize = std::min(periodSize, (snd_pcm_uframes_t) sampleRate / 20);
|
||||
+ bufferSize = std::min(bufferSize, (snd_pcm_uframes_t) periodSize * 4);
|
||||
|
||||
/*
|
||||
- According to upstream we should set buffer size first - so make sure it is always at least
|
||||
- double of period size to not get underruns
|
||||
+ According to upstream we should set buffer size first - so make sure it is always at least
|
||||
+ double of period size to not get underruns
|
||||
*/
|
||||
periodSize = std::min(periodSize, bufferSize / 2);
|
||||
|
||||
--
|
||||
1.7.10
|
||||
|
@ -1,520 +0,0 @@
|
||||
From dac7871e3440b9d4235fcd91af1c2d41a931d69d Mon Sep 17 00:00:00 2001
|
||||
From: popcornmix <popcornmix@gmail.com>
|
||||
Date: Mon, 18 Feb 2013 23:04:28 +0000
|
||||
Subject: [PATCH] [rbp] Handle resolution changes during video stream.
|
||||
|
||||
When the resolution changes, GPU sends a port settings changed message. Host has to acknowledge it by disabling and enabling the affected ports.
|
||||
---
|
||||
xbmc/cores/omxplayer/OMXPlayerVideo.cpp | 229 ++++++++++++-------------------
|
||||
xbmc/cores/omxplayer/OMXPlayerVideo.h | 7 +-
|
||||
xbmc/cores/omxplayer/OMXVideo.cpp | 95 ++++++++-----
|
||||
xbmc/cores/omxplayer/OMXVideo.h | 7 +-
|
||||
4 files changed, 151 insertions(+), 187 deletions(-)
|
||||
|
||||
diff --git a/xbmc/cores/omxplayer/OMXPlayerVideo.cpp b/xbmc/cores/omxplayer/OMXPlayerVideo.cpp
|
||||
index 5a6e31e..a033c78 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXPlayerVideo.cpp
|
||||
+++ b/xbmc/cores/omxplayer/OMXPlayerVideo.cpp
|
||||
@@ -83,9 +83,6 @@ class COMXMsgVideoCodecChange : public CDVDMsg
|
||||
m_iSubtitleDelay = 0;
|
||||
m_FlipTimeStamp = 0.0;
|
||||
m_bRenderSubs = false;
|
||||
- m_width = 0;
|
||||
- m_height = 0;
|
||||
- m_fps = 0.0f;
|
||||
m_flags = 0;
|
||||
m_bAllowFullscreen = false;
|
||||
m_iCurrentPts = DVD_NOPTS_VALUE;
|
||||
@@ -98,12 +95,7 @@ class COMXMsgVideoCodecChange : public CDVDMsg
|
||||
m_messageQueue.SetMaxDataSize(10 * 1024 * 1024);
|
||||
m_messageQueue.SetMaxTimeSize(8.0);
|
||||
|
||||
- RESOLUTION res = g_graphicsContext.GetVideoResolution();
|
||||
- m_video_width = g_settings.m_ResInfo[res].iScreenWidth;
|
||||
- m_video_height = g_settings.m_ResInfo[res].iScreenHeight;
|
||||
-
|
||||
m_dst_rect.SetRect(0, 0, 0, 0);
|
||||
-
|
||||
}
|
||||
|
||||
OMXPlayerVideo::~OMXPlayerVideo()
|
||||
@@ -125,6 +117,8 @@ bool OMXPlayerVideo::OpenStream(CDVDStreamInfo &hints)
|
||||
m_stalled = m_messageQueue.GetPacketCount(CDVDMsg::DEMUXER_PACKET) == 0;
|
||||
m_autosync = 1;
|
||||
m_iSleepEndTime = DVD_NOPTS_VALUE;
|
||||
+ // force SetVideoRect to be called initially
|
||||
+ m_dst_rect.SetRect(0, 0, 0, 0);
|
||||
|
||||
m_audio_count = m_av_clock->HasAudio();
|
||||
|
||||
@@ -220,154 +214,45 @@ void OMXPlayerVideo::ProcessOverlays(int iGroupId, double pts)
|
||||
if (m_started)
|
||||
m_pOverlayContainer->CleanUp(pts - m_iSubtitleDelay);
|
||||
|
||||
- enum EOverlay
|
||||
- { OVERLAY_AUTO // select mode auto
|
||||
- , OVERLAY_GPU // render osd using gpu
|
||||
- , OVERLAY_BUF // render osd on buffer
|
||||
- } render = OVERLAY_AUTO;
|
||||
-
|
||||
- /*
|
||||
- if(m_pOverlayContainer->ContainsOverlayType(DVDOVERLAY_TYPE_SPU)
|
||||
- || m_pOverlayContainer->ContainsOverlayType(DVDOVERLAY_TYPE_IMAGE)
|
||||
- || m_pOverlayContainer->ContainsOverlayType(DVDOVERLAY_TYPE_SSA) )
|
||||
- render = OVERLAY_BUF;
|
||||
- */
|
||||
-
|
||||
- if(render == OVERLAY_BUF)
|
||||
- {
|
||||
- // rendering spu overlay types directly on video memory costs a lot of processing power.
|
||||
- // thus we allocate a temp picture, copy the original to it (needed because the same picture can be used more than once).
|
||||
- // then do all the rendering on that temp picture and finaly copy it to video memory.
|
||||
- // In almost all cases this is 5 or more times faster!.
|
||||
-
|
||||
- if(m_pTempOverlayPicture && ( m_pTempOverlayPicture->iWidth != m_width
|
||||
- || m_pTempOverlayPicture->iHeight != m_height))
|
||||
- {
|
||||
- CDVDCodecUtils::FreePicture(m_pTempOverlayPicture);
|
||||
- m_pTempOverlayPicture = NULL;
|
||||
- }
|
||||
-
|
||||
- if(!m_pTempOverlayPicture)
|
||||
- m_pTempOverlayPicture = CDVDCodecUtils::AllocatePicture(m_width, m_height);
|
||||
- if(!m_pTempOverlayPicture)
|
||||
- return;
|
||||
- m_pTempOverlayPicture->format = RENDER_FMT_YUV420P;
|
||||
- }
|
||||
-
|
||||
- if(render == OVERLAY_AUTO)
|
||||
- render = OVERLAY_GPU;
|
||||
-
|
||||
VecOverlays overlays;
|
||||
|
||||
- {
|
||||
- CSingleLock lock(*m_pOverlayContainer);
|
||||
+ CSingleLock lock(*m_pOverlayContainer);
|
||||
|
||||
- VecOverlays* pVecOverlays = m_pOverlayContainer->GetOverlays();
|
||||
- VecOverlaysIter it = pVecOverlays->begin();
|
||||
-
|
||||
- //Check all overlays and render those that should be rendered, based on time and forced
|
||||
- //Both forced and subs should check timeing, pts == 0 in the stillframe case
|
||||
- while (it != pVecOverlays->end())
|
||||
- {
|
||||
- CDVDOverlay* pOverlay = *it++;
|
||||
- if(!pOverlay->bForced && !m_bRenderSubs)
|
||||
- continue;
|
||||
-
|
||||
- if(pOverlay->iGroupId != iGroupId)
|
||||
- continue;
|
||||
+ VecOverlays* pVecOverlays = m_pOverlayContainer->GetOverlays();
|
||||
+ VecOverlaysIter it = pVecOverlays->begin();
|
||||
|
||||
- double pts2 = pOverlay->bForced ? pts : pts - m_iSubtitleDelay;
|
||||
+ //Check all overlays and render those that should be rendered, based on time and forced
|
||||
+ //Both forced and subs should check timeing, pts == 0 in the stillframe case
|
||||
+ while (it != pVecOverlays->end())
|
||||
+ {
|
||||
+ CDVDOverlay* pOverlay = *it++;
|
||||
+ if(!pOverlay->bForced && !m_bRenderSubs)
|
||||
+ continue;
|
||||
|
||||
- if((pOverlay->iPTSStartTime <= pts2 && (pOverlay->iPTSStopTime > pts2 || pOverlay->iPTSStopTime == 0LL)) || pts == 0)
|
||||
- {
|
||||
- if(pOverlay->IsOverlayType(DVDOVERLAY_TYPE_GROUP))
|
||||
- overlays.insert(overlays.end(), static_cast<CDVDOverlayGroup*>(pOverlay)->m_overlays.begin()
|
||||
- , static_cast<CDVDOverlayGroup*>(pOverlay)->m_overlays.end());
|
||||
- else
|
||||
- overlays.push_back(pOverlay);
|
||||
+ if(pOverlay->iGroupId != iGroupId)
|
||||
+ continue;
|
||||
|
||||
- }
|
||||
- }
|
||||
+ double pts2 = pOverlay->bForced ? pts : pts - m_iSubtitleDelay;
|
||||
|
||||
- for(it = overlays.begin(); it != overlays.end(); ++it)
|
||||
+ if((pOverlay->iPTSStartTime <= pts2 && (pOverlay->iPTSStopTime > pts2 || pOverlay->iPTSStopTime == 0LL)) || pts == 0)
|
||||
{
|
||||
- double pts2 = (*it)->bForced ? pts : pts - m_iSubtitleDelay;
|
||||
-
|
||||
- if (render == OVERLAY_GPU)
|
||||
- g_renderManager.AddOverlay(*it, pts2);
|
||||
-
|
||||
- /*
|
||||
- printf("subtitle : DVDOVERLAY_TYPE_SPU %d DVDOVERLAY_TYPE_IMAGE %d DVDOVERLAY_TYPE_SSA %d\n",
|
||||
- m_pOverlayContainer->ContainsOverlayType(DVDOVERLAY_TYPE_SPU),
|
||||
- m_pOverlayContainer->ContainsOverlayType(DVDOVERLAY_TYPE_IMAGE),
|
||||
- m_pOverlayContainer->ContainsOverlayType(DVDOVERLAY_TYPE_SSA) );
|
||||
- */
|
||||
-
|
||||
- if (render == OVERLAY_BUF)
|
||||
- CDVDOverlayRenderer::Render(m_pTempOverlayPicture, *it, pts2);
|
||||
+ if(pOverlay->IsOverlayType(DVDOVERLAY_TYPE_GROUP))
|
||||
+ overlays.insert(overlays.end(), static_cast<CDVDOverlayGroup*>(pOverlay)->m_overlays.begin()
|
||||
+ , static_cast<CDVDOverlayGroup*>(pOverlay)->m_overlays.end());
|
||||
+ else
|
||||
+ overlays.push_back(pOverlay);
|
||||
}
|
||||
}
|
||||
-}
|
||||
-
|
||||
-void OMXPlayerVideo::Output(int iGroupId, double pts, bool bDropPacket)
|
||||
-{
|
||||
|
||||
- if (!g_renderManager.IsConfigured()
|
||||
- || m_video_width != m_width
|
||||
- || m_video_height != m_height
|
||||
- || m_fps != m_fFrameRate)
|
||||
+ for(it = overlays.begin(); it != overlays.end(); ++it)
|
||||
{
|
||||
- m_width = m_video_width;
|
||||
- m_height = m_video_height;
|
||||
- m_fps = m_fFrameRate;
|
||||
-
|
||||
- unsigned flags = 0;
|
||||
- ERenderFormat format = RENDER_FMT_BYPASS;
|
||||
-
|
||||
- if(m_bAllowFullscreen)
|
||||
- {
|
||||
- flags |= CONF_FLAGS_FULLSCREEN;
|
||||
- m_bAllowFullscreen = false; // only allow on first configure
|
||||
- }
|
||||
-
|
||||
- if(m_flags & CONF_FLAGS_FORMAT_SBS)
|
||||
- {
|
||||
- if(g_Windowing.Support3D(m_video_width, m_video_height, D3DPRESENTFLAG_MODE3DSBS))
|
||||
- {
|
||||
- CLog::Log(LOGNOTICE, "3DSBS movie found");
|
||||
- flags |= CONF_FLAGS_FORMAT_SBS;
|
||||
- }
|
||||
- }
|
||||
- else if(m_flags & CONF_FLAGS_FORMAT_TB)
|
||||
- {
|
||||
- if(g_Windowing.Support3D(m_video_width, m_video_height, D3DPRESENTFLAG_MODE3DTB))
|
||||
- {
|
||||
- CLog::Log(LOGNOTICE, "3DTB movie found");
|
||||
- flags |= CONF_FLAGS_FORMAT_TB;
|
||||
- }
|
||||
- }
|
||||
-
|
||||
- unsigned int iDisplayWidth = m_hints.width;
|
||||
- unsigned int iDisplayHeight = m_hints.height;
|
||||
-
|
||||
- /* use forced aspect if any */
|
||||
- if( m_fForcedAspectRatio != 0.0f )
|
||||
- iDisplayWidth = (int) (iDisplayHeight * m_fForcedAspectRatio);
|
||||
-
|
||||
- CLog::Log(LOGDEBUG,"%s - change configuration. %dx%d. framerate: %4.2f. %dx%x format: BYPASS",
|
||||
- __FUNCTION__, m_width, m_height, m_fps, iDisplayWidth, iDisplayHeight);
|
||||
-
|
||||
- if(!g_renderManager.Configure(m_hints.width, m_hints.height,
|
||||
- iDisplayWidth, iDisplayHeight, m_fps, flags, format, 0,
|
||||
- m_hints.orientation))
|
||||
- {
|
||||
- CLog::Log(LOGERROR, "%s - failed to configure renderer", __FUNCTION__);
|
||||
- return;
|
||||
- }
|
||||
-
|
||||
- g_renderManager.RegisterRenderUpdateCallBack((const void*)this, RenderUpdateCallBack);
|
||||
+ double pts2 = (*it)->bForced ? pts : pts - m_iSubtitleDelay;
|
||||
+ g_renderManager.AddOverlay(*it, pts2);
|
||||
}
|
||||
+}
|
||||
|
||||
+void OMXPlayerVideo::Output(int iGroupId, double pts, bool bDropPacket)
|
||||
+{
|
||||
if (!g_renderManager.IsStarted()) {
|
||||
CLog::Log(LOGERROR, "%s - renderer not started", __FUNCTION__);
|
||||
return;
|
||||
@@ -724,6 +609,7 @@ bool OMXPlayerVideo::OpenDecoder()
|
||||
m_av_clock->OMXStop(false);
|
||||
|
||||
bool bVideoDecoderOpen = m_omxVideo.Open(m_hints, m_av_clock, m_Deinterlace, m_hdmi_clock_sync);
|
||||
+ m_omxVideo.RegisterResolutionUpdateCallBack((void *)this, ResolutionUpdateCallBack);
|
||||
|
||||
if(!bVideoDecoderOpen)
|
||||
{
|
||||
@@ -859,3 +745,62 @@ void OMXPlayerVideo::RenderUpdateCallBack(const void *ctx, const CRect &SrcRect,
|
||||
player->SetVideoRect(SrcRect, DestRect);
|
||||
}
|
||||
|
||||
+void OMXPlayerVideo::ResolutionUpdateCallBack(uint32_t width, uint32_t height)
|
||||
+{
|
||||
+ RESOLUTION res = g_graphicsContext.GetVideoResolution();
|
||||
+ uint32_t video_width = g_settings.m_ResInfo[res].iScreenWidth;
|
||||
+ uint32_t video_height = g_settings.m_ResInfo[res].iScreenHeight;
|
||||
+
|
||||
+ unsigned flags = 0;
|
||||
+ ERenderFormat format = RENDER_FMT_BYPASS;
|
||||
+
|
||||
+ if(m_bAllowFullscreen)
|
||||
+ {
|
||||
+ flags |= CONF_FLAGS_FULLSCREEN;
|
||||
+ m_bAllowFullscreen = false; // only allow on first configure
|
||||
+ }
|
||||
+
|
||||
+ if(m_flags & CONF_FLAGS_FORMAT_SBS)
|
||||
+ {
|
||||
+ if(g_Windowing.Support3D(video_width, video_height, D3DPRESENTFLAG_MODE3DSBS))
|
||||
+ {
|
||||
+ CLog::Log(LOGNOTICE, "3DSBS movie found");
|
||||
+ flags |= CONF_FLAGS_FORMAT_SBS;
|
||||
+ }
|
||||
+ }
|
||||
+ else if(m_flags & CONF_FLAGS_FORMAT_TB)
|
||||
+ {
|
||||
+ if(g_Windowing.Support3D(video_width, video_height, D3DPRESENTFLAG_MODE3DTB))
|
||||
+ {
|
||||
+ CLog::Log(LOGNOTICE, "3DTB movie found");
|
||||
+ flags |= CONF_FLAGS_FORMAT_TB;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ unsigned int iDisplayWidth = width;
|
||||
+ unsigned int iDisplayHeight = height;
|
||||
+
|
||||
+ /* use forced aspect if any */
|
||||
+ if( m_fForcedAspectRatio != 0.0f )
|
||||
+ iDisplayWidth = (int) (iDisplayHeight * m_fForcedAspectRatio);
|
||||
+
|
||||
+ CLog::Log(LOGDEBUG,"%s - change configuration. video:%dx%d. framerate: %4.2f. %dx%d format: BYPASS",
|
||||
+ __FUNCTION__, video_width, video_height, m_fFrameRate, iDisplayWidth, iDisplayHeight);
|
||||
+
|
||||
+ if(!g_renderManager.Configure(width, height,
|
||||
+ iDisplayWidth, iDisplayHeight, m_fFrameRate, flags, format, 0,
|
||||
+ m_hints.orientation))
|
||||
+ {
|
||||
+ CLog::Log(LOGERROR, "%s - failed to configure renderer", __FUNCTION__);
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ g_renderManager.RegisterRenderUpdateCallBack((const void*)this, RenderUpdateCallBack);
|
||||
+}
|
||||
+
|
||||
+void OMXPlayerVideo::ResolutionUpdateCallBack(void *ctx, uint32_t width, uint32_t height)
|
||||
+{
|
||||
+ OMXPlayerVideo *player = static_cast<OMXPlayerVideo*>(ctx);
|
||||
+ player->ResolutionUpdateCallBack(width, height);
|
||||
+}
|
||||
+
|
||||
diff --git a/xbmc/cores/omxplayer/OMXPlayerVideo.h b/xbmc/cores/omxplayer/OMXPlayerVideo.h
|
||||
index cf05c1f..95a691b 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXPlayerVideo.h
|
||||
+++ b/xbmc/cores/omxplayer/OMXPlayerVideo.h
|
||||
@@ -70,12 +70,7 @@ class OMXPlayerVideo : public CThread
|
||||
bool m_bAllowFullscreen;
|
||||
|
||||
float m_fForcedAspectRatio;
|
||||
- unsigned int m_width;
|
||||
- unsigned int m_height;
|
||||
- unsigned int m_video_width;
|
||||
- unsigned int m_video_height;
|
||||
unsigned m_flags;
|
||||
- float m_fps;
|
||||
|
||||
CRect m_dst_rect;
|
||||
int m_view_mode;
|
||||
@@ -133,5 +128,7 @@ class OMXPlayerVideo : public CThread
|
||||
int GetFreeSpace();
|
||||
void SetVideoRect(const CRect &SrcRect, const CRect &DestRect);
|
||||
static void RenderUpdateCallBack(const void *ctx, const CRect &SrcRect, const CRect &DestRect);
|
||||
+ void ResolutionUpdateCallBack(uint32_t width, uint32_t height);
|
||||
+ static void ResolutionUpdateCallBack(void *ctx, uint32_t width, uint32_t height);
|
||||
};
|
||||
#endif
|
||||
diff --git a/xbmc/cores/omxplayer/OMXVideo.cpp b/xbmc/cores/omxplayer/OMXVideo.cpp
|
||||
index 3417286..b6b42e7 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXVideo.cpp
|
||||
+++ b/xbmc/cores/omxplayer/OMXVideo.cpp
|
||||
@@ -86,7 +86,6 @@
|
||||
m_video_codec_name = "";
|
||||
m_deinterlace = false;
|
||||
m_hdmi_clock_sync = false;
|
||||
- m_first_frame = true;
|
||||
}
|
||||
|
||||
COMXVideo::~COMXVideo()
|
||||
@@ -154,6 +153,9 @@ bool COMXVideo::Open(CDVDStreamInfo &hints, OMXClock *clock, bool deinterlace, b
|
||||
OMX_ERRORTYPE omx_err = OMX_ErrorNone;
|
||||
std::string decoder_name;
|
||||
|
||||
+ m_res_ctx = NULL;
|
||||
+ m_res_callback = NULL;
|
||||
+
|
||||
m_video_codec_name = "";
|
||||
m_codingType = OMX_VIDEO_CodingUnused;
|
||||
|
||||
@@ -697,7 +699,6 @@ bool COMXVideo::Open(CDVDStreamInfo &hints, OMXClock *clock, bool deinterlace, b
|
||||
CLASSNAME, __func__, m_omx_decoder.GetComponent(), m_omx_decoder.GetInputPort(), m_omx_decoder.GetOutputPort(),
|
||||
m_deinterlace, m_hdmi_clock_sync);
|
||||
|
||||
- m_first_frame = true;
|
||||
// start from assuming all recent frames had valid pts
|
||||
m_history_valid_pts = ~0;
|
||||
|
||||
@@ -736,8 +737,10 @@ void COMXVideo::Close()
|
||||
m_video_convert = false;
|
||||
m_video_codec_name = "";
|
||||
m_deinterlace = false;
|
||||
- m_first_frame = true;
|
||||
m_av_clock = NULL;
|
||||
+
|
||||
+ m_res_ctx = NULL;
|
||||
+ m_res_callback = NULL;
|
||||
}
|
||||
|
||||
void COMXVideo::SetDropState(bool bDrop)
|
||||
@@ -851,57 +854,74 @@ int COMXVideo::Decode(uint8_t *pData, int iSize, double dts, double pts)
|
||||
}
|
||||
}
|
||||
|
||||
- if(m_first_frame && m_deinterlace)
|
||||
+ omx_err = m_omx_decoder.WaitForEvent(OMX_EventPortSettingsChanged, 0);
|
||||
+ if (omx_err == OMX_ErrorNone)
|
||||
{
|
||||
OMX_PARAM_PORTDEFINITIONTYPE port_image;
|
||||
OMX_INIT_STRUCTURE(port_image);
|
||||
port_image.nPortIndex = m_omx_decoder.GetOutputPort();
|
||||
-
|
||||
omx_err = m_omx_decoder.GetParameter(OMX_IndexParamPortDefinition, &port_image);
|
||||
if(omx_err != OMX_ErrorNone)
|
||||
- CLog::Log(LOGERROR, "%s::%s - error OMX_IndexParamPortDefinition 1 omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
+ {
|
||||
+ CLog::Log(LOGERROR, "%s::%s - error m_omx_decoder.GetParameter(OMX_IndexParamPortDefinition) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
+ }
|
||||
+ // let OMXPlayerVideo know about resolution so it can inform RenderManager
|
||||
+ if (m_res_callback)
|
||||
+ m_res_callback(m_res_ctx, port_image.format.video.nFrameWidth, port_image.format.video.nFrameHeight);
|
||||
+
|
||||
+ m_omx_decoder.DisablePort(m_omx_decoder.GetOutputPort(), true);
|
||||
+ m_omx_sched.DisablePort(m_omx_sched.GetInputPort(), true);
|
||||
|
||||
- /* we assume when the sizes equal we have the first decoded frame */
|
||||
- if(port_image.format.video.nFrameWidth == m_decoded_width && port_image.format.video.nFrameHeight == m_decoded_height)
|
||||
+ OMX_CONFIG_INTERLACETYPE interlace;
|
||||
+ OMX_INIT_STRUCTURE(interlace);
|
||||
+ interlace.nPortIndex = m_omx_decoder.GetOutputPort();
|
||||
+ omx_err = m_omx_decoder.GetConfig(OMX_IndexConfigCommonInterlace, &interlace);
|
||||
+ if(omx_err != OMX_ErrorNone)
|
||||
{
|
||||
- m_first_frame = false;
|
||||
+ CLog::Log(LOGERROR, "%s::%s - error m_omx_decoder.GetConfig(OMX_IndexConfigCommonInterlace) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
+ }
|
||||
|
||||
- omx_err = m_omx_decoder.WaitForEvent(OMX_EventPortSettingsChanged);
|
||||
- if(omx_err == OMX_ErrorStreamCorrupt)
|
||||
+ if (m_deinterlace)
|
||||
+ {
|
||||
+ m_omx_image_fx.DisablePort(m_omx_image_fx.GetInputPort(), true);
|
||||
+ port_image.nPortIndex = m_omx_image_fx.GetInputPort();
|
||||
+ omx_err = m_omx_image_fx.SetParameter(OMX_IndexParamPortDefinition, &port_image);
|
||||
+ if(omx_err != OMX_ErrorNone)
|
||||
{
|
||||
- CLog::Log(LOGERROR, "%s::%s - image not unsupported\n", CLASSNAME, __func__);
|
||||
- return false;
|
||||
+ CLog::Log(LOGERROR, "%s::%s - error m_omx_image_fx.SetParameter(OMX_IndexParamPortDefinition) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
}
|
||||
-
|
||||
- m_omx_decoder.DisablePort(m_omx_decoder.GetOutputPort(), false);
|
||||
- m_omx_sched.DisablePort(m_omx_sched.GetInputPort(), false);
|
||||
-
|
||||
- if(m_deinterlace)
|
||||
+ omx_err = m_omx_decoder.WaitForEvent(OMX_EventPortSettingsChanged);
|
||||
+ if(omx_err != OMX_ErrorNone)
|
||||
{
|
||||
- m_omx_image_fx.DisablePort(m_omx_image_fx.GetOutputPort(), false);
|
||||
- m_omx_image_fx.DisablePort(m_omx_image_fx.GetInputPort(), false);
|
||||
-
|
||||
- port_image.nPortIndex = m_omx_image_fx.GetInputPort();
|
||||
- omx_err = m_omx_image_fx.SetParameter(OMX_IndexParamPortDefinition, &port_image);
|
||||
- if(omx_err != OMX_ErrorNone)
|
||||
- CLog::Log(LOGERROR, "%s::%s - error OMX_IndexParamPortDefinition 2 omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
-
|
||||
- port_image.nPortIndex = m_omx_image_fx.GetOutputPort();
|
||||
- omx_err = m_omx_image_fx.SetParameter(OMX_IndexParamPortDefinition, &port_image);
|
||||
- if(omx_err != OMX_ErrorNone)
|
||||
- CLog::Log(LOGERROR, "%s::%s - error OMX_IndexParamPortDefinition 3 omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
+ CLog::Log(LOGERROR, "%s::%s - error m_omx_decoder.WaitForEvent(OMX_EventPortSettingsChanged) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
}
|
||||
-
|
||||
- m_omx_decoder.EnablePort(m_omx_decoder.GetOutputPort(), false);
|
||||
-
|
||||
- if(m_deinterlace)
|
||||
+ port_image.nPortIndex = m_omx_image_fx.GetOutputPort();
|
||||
+ omx_err = m_omx_image_fx.GetParameter(OMX_IndexParamPortDefinition, &port_image);
|
||||
+ if(omx_err != OMX_ErrorNone)
|
||||
{
|
||||
- m_omx_image_fx.EnablePort(m_omx_image_fx.GetOutputPort(), false);
|
||||
- m_omx_image_fx.EnablePort(m_omx_image_fx.GetInputPort(), false);
|
||||
+ CLog::Log(LOGERROR, "%s::%s - error m_omx_image_fx.GetParameter(OMX_IndexParamPortDefinition) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
}
|
||||
+ m_omx_image_fx.EnablePort(m_omx_image_fx.GetInputPort(), true);
|
||||
|
||||
- m_omx_sched.EnablePort(m_omx_sched.GetInputPort(), false);
|
||||
+ m_omx_image_fx.DisablePort(m_omx_image_fx.GetOutputPort(), true);
|
||||
+ }
|
||||
+ port_image.nPortIndex = m_omx_sched.GetInputPort();
|
||||
+ omx_err = m_omx_sched.SetParameter(OMX_IndexParamPortDefinition, &port_image);
|
||||
+ if(omx_err != OMX_ErrorNone)
|
||||
+ {
|
||||
+ CLog::Log(LOGERROR, "%s::%s - error m_omx_sched.SetParameter(OMX_IndexParamPortDefinition) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
+ }
|
||||
+ omx_err = m_omx_sched.WaitForEvent(OMX_EventPortSettingsChanged);
|
||||
+ if(omx_err != OMX_ErrorNone)
|
||||
+ {
|
||||
+ CLog::Log(LOGERROR, "%s::%s - error m_omx_sched.WaitForEvent(OMX_EventPortSettingsChanged) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
+ }
|
||||
+ if (m_deinterlace)
|
||||
+ {
|
||||
+ m_omx_image_fx.EnablePort(m_omx_image_fx.GetOutputPort(), true);
|
||||
}
|
||||
+ m_omx_decoder.EnablePort(m_omx_decoder.GetOutputPort(), true);
|
||||
+ m_omx_sched.EnablePort(m_omx_sched.GetInputPort(), true);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -932,7 +952,6 @@ void COMXVideo::Reset(void)
|
||||
|
||||
SendDecoderConfig();
|
||||
|
||||
- m_first_frame = true;
|
||||
*/
|
||||
}
|
||||
|
||||
diff --git a/xbmc/cores/omxplayer/OMXVideo.h b/xbmc/cores/omxplayer/OMXVideo.h
|
||||
index 0afa56d..037f155 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXVideo.h
|
||||
+++ b/xbmc/cores/omxplayer/OMXVideo.h
|
||||
@@ -36,6 +36,8 @@
|
||||
|
||||
#define CLASSNAME "COMXVideo"
|
||||
|
||||
+typedef void (*ResolutionUpdateCallBackFn)(void *ctx, uint32_t width, uint32_t height);
|
||||
+
|
||||
class COMXVideo
|
||||
{
|
||||
public:
|
||||
@@ -45,6 +47,7 @@ class COMXVideo
|
||||
// Required overrides
|
||||
bool SendDecoderConfig();
|
||||
bool Open(CDVDStreamInfo &hints, OMXClock *clock, bool deinterlace = false, bool hdmi_clock_sync = false);
|
||||
+ void RegisterResolutionUpdateCallBack(void *ctx, ResolutionUpdateCallBackFn callback) { m_res_ctx = ctx; m_res_callback = callback; }
|
||||
void Close(void);
|
||||
unsigned int GetFreeSpace();
|
||||
unsigned int GetSize();
|
||||
@@ -89,9 +92,9 @@ class COMXVideo
|
||||
|
||||
bool m_deinterlace;
|
||||
bool m_hdmi_clock_sync;
|
||||
- bool m_first_frame;
|
||||
uint32_t m_history_valid_pts;
|
||||
-
|
||||
+ ResolutionUpdateCallBackFn m_res_callback;
|
||||
+ void *m_res_ctx;
|
||||
bool NaluFormatStartCodes(enum CodecID codec, uint8_t *in_extradata, int in_extrasize);
|
||||
};
|
||||
|
||||
--
|
||||
1.7.10
|
||||
|
@ -1,202 +0,0 @@
|
||||
From 3d1005fdd34e72f81aff9034f8d30a0d33a780a8 Mon Sep 17 00:00:00 2001
|
||||
From: xbmc <fernetmenta@online.de>
|
||||
Date: Mon, 4 Mar 2013 08:30:47 +0100
|
||||
Subject: [PATCH] Always copy overlays from file parser - Fixes stuck hw
|
||||
resources on render
|
||||
|
||||
---
|
||||
.../cores/dvdplayer/DVDCodecs/Overlay/DVDOverlay.h | 6 +++
|
||||
.../dvdplayer/DVDCodecs/Overlay/DVDOverlayImage.h | 6 +++
|
||||
.../dvdplayer/DVDCodecs/Overlay/DVDOverlaySSA.h | 11 ++++++
|
||||
.../dvdplayer/DVDCodecs/Overlay/DVDOverlayText.h | 41 ++++++++++++++++++++
|
||||
xbmc/cores/dvdplayer/DVDPlayerSubtitle.cpp | 1 +
|
||||
.../dvdplayer/DVDSubtitles/DVDSubtitleParser.h | 8 +++-
|
||||
6 files changed, 72 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlay.h b/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlay.h
|
||||
index 8c87bc4..da8de1f 100644
|
||||
--- a/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlay.h
|
||||
+++ b/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlay.h
|
||||
@@ -103,6 +103,12 @@ class CDVDOverlay
|
||||
|
||||
bool IsOverlayType(DVDOverlayType type) { return (m_type == type); }
|
||||
|
||||
+ /**
|
||||
+ * return a copy to DVDPlayerSubtitle in order to have hw resources cleared
|
||||
+ * after rendering
|
||||
+ */
|
||||
+ virtual CDVDOverlay* Clone() { return Acquire(); }
|
||||
+
|
||||
double iPTSStartTime;
|
||||
double iPTSStopTime;
|
||||
bool bForced; // display, no matter what
|
||||
diff --git a/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlayImage.h b/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlayImage.h
|
||||
index bc90d68..e1cdf59 100644
|
||||
--- a/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlayImage.h
|
||||
+++ b/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlayImage.h
|
||||
@@ -20,6 +20,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
+#include "PlatformDefs.h"
|
||||
#include "DVDOverlay.h"
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
@@ -117,6 +118,11 @@ class CDVDOverlayImage : public CDVDOverlay
|
||||
if(palette) free(palette);
|
||||
}
|
||||
|
||||
+ virtual CDVDOverlayImage* Clone()
|
||||
+ {
|
||||
+ return new CDVDOverlayImage(*this);
|
||||
+ }
|
||||
+
|
||||
BYTE* data_at(int sub_x, int sub_y) const
|
||||
{
|
||||
int bpp;
|
||||
diff --git a/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlaySSA.h b/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlaySSA.h
|
||||
index 31deba1..f42c571 100644
|
||||
--- a/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlaySSA.h
|
||||
+++ b/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlaySSA.h
|
||||
@@ -37,10 +37,21 @@ class CDVDOverlaySSA : public CDVDOverlay
|
||||
libass->Acquire();
|
||||
}
|
||||
|
||||
+ CDVDOverlaySSA(CDVDOverlaySSA& src)
|
||||
+ : CDVDOverlay(src)
|
||||
+ , m_libass(src.m_libass)
|
||||
+ {
|
||||
+ m_libass->Acquire();
|
||||
+ }
|
||||
+
|
||||
~CDVDOverlaySSA()
|
||||
{
|
||||
if(m_libass)
|
||||
SAFE_RELEASE(m_libass);
|
||||
}
|
||||
|
||||
+ virtual CDVDOverlaySSA* Clone()
|
||||
+ {
|
||||
+ return new CDVDOverlaySSA(*this);
|
||||
+ }
|
||||
};
|
||||
diff --git a/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlayText.h b/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlayText.h
|
||||
index 849a6e3..54e3bfa 100644
|
||||
--- a/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlayText.h
|
||||
+++ b/xbmc/cores/dvdplayer/DVDCodecs/Overlay/DVDOverlayText.h
|
||||
@@ -46,6 +46,12 @@ class CDVDOverlayText : public CDVDOverlay
|
||||
m_type = type;
|
||||
}
|
||||
|
||||
+ CElement(CElement& src)
|
||||
+ {
|
||||
+ pNext = NULL;
|
||||
+ m_type = src.m_type;
|
||||
+ }
|
||||
+
|
||||
virtual ~CElement()
|
||||
{
|
||||
}
|
||||
@@ -71,6 +77,12 @@ class CDVDOverlayText : public CDVDOverlay
|
||||
}
|
||||
}
|
||||
|
||||
+ CElementText(CElementText& src)
|
||||
+ : CElement(src)
|
||||
+ {
|
||||
+ m_text = strdup(src.m_text);
|
||||
+ }
|
||||
+
|
||||
virtual ~CElementText()
|
||||
{
|
||||
if (m_text) free(m_text);
|
||||
@@ -81,12 +93,20 @@ class CDVDOverlayText : public CDVDOverlay
|
||||
|
||||
class CElementProperty : public CElement
|
||||
{
|
||||
+ public:
|
||||
CElementProperty() : CElement(ELEMENT_TYPE_PROPERTY)
|
||||
{
|
||||
bItalic = false;
|
||||
bBold = false;
|
||||
}
|
||||
|
||||
+ CElementProperty(CElementProperty& src)
|
||||
+ : CElement(src)
|
||||
+ {
|
||||
+ bItalic = src.bItalic;
|
||||
+ bBold = src.bBold;
|
||||
+ }
|
||||
+
|
||||
public:
|
||||
bool bItalic;
|
||||
bool bBold;
|
||||
@@ -99,6 +119,22 @@ class CDVDOverlayText : public CDVDOverlay
|
||||
m_pEnd = NULL;
|
||||
}
|
||||
|
||||
+ CDVDOverlayText(CDVDOverlayText& src)
|
||||
+ : CDVDOverlay(src)
|
||||
+ {
|
||||
+ m_pHead = NULL;
|
||||
+ m_pEnd = NULL;
|
||||
+ for(CElement* e = src.m_pHead; e; e = e->pNext)
|
||||
+ {
|
||||
+ if(e->IsElementType(ELEMENT_TYPE_TEXT))
|
||||
+ AddElement(new CElementText(*static_cast<CElementText*>(e)));
|
||||
+ else if(e->IsElementType(ELEMENT_TYPE_PROPERTY))
|
||||
+ AddElement(new CElementProperty(*static_cast<CElementProperty*>(e)));
|
||||
+ else
|
||||
+ AddElement(new CElement(*static_cast<CElement*>(e)));
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
virtual ~CDVDOverlayText()
|
||||
{
|
||||
CElement* pTemp;
|
||||
@@ -110,6 +146,11 @@ class CDVDOverlayText : public CDVDOverlay
|
||||
}
|
||||
}
|
||||
|
||||
+ virtual CDVDOverlayText* Clone()
|
||||
+ {
|
||||
+ return new CDVDOverlayText(*this);
|
||||
+ }
|
||||
+
|
||||
void AddElement(CDVDOverlayText::CElement* pElement)
|
||||
{
|
||||
pElement->pNext = NULL;
|
||||
diff --git a/xbmc/cores/dvdplayer/DVDPlayerSubtitle.cpp b/xbmc/cores/dvdplayer/DVDPlayerSubtitle.cpp
|
||||
index 29c8d57..540d890 100644
|
||||
--- a/xbmc/cores/dvdplayer/DVDPlayerSubtitle.cpp
|
||||
+++ b/xbmc/cores/dvdplayer/DVDPlayerSubtitle.cpp
|
||||
@@ -222,6 +222,7 @@ void CDVDPlayerSubtitle::Process(double pts)
|
||||
while(pOverlay)
|
||||
{
|
||||
m_pOverlayContainer->Add(pOverlay);
|
||||
+ pOverlay->Release();
|
||||
pOverlay = m_pSubtitleFileParser->Parse(pts);
|
||||
}
|
||||
|
||||
diff --git a/xbmc/cores/dvdplayer/DVDSubtitles/DVDSubtitleParser.h b/xbmc/cores/dvdplayer/DVDSubtitles/DVDSubtitleParser.h
|
||||
index 944bf06..3cd1e95 100644
|
||||
--- a/xbmc/cores/dvdplayer/DVDSubtitles/DVDSubtitleParser.h
|
||||
+++ b/xbmc/cores/dvdplayer/DVDSubtitles/DVDSubtitleParser.h
|
||||
@@ -47,7 +47,13 @@ class CDVDSubtitleParserCollection
|
||||
m_filename = strFile;
|
||||
}
|
||||
virtual ~CDVDSubtitleParserCollection() { }
|
||||
- virtual CDVDOverlay* Parse(double iPts) { return m_collection.Get(iPts); }
|
||||
+ virtual CDVDOverlay* Parse(double iPts)
|
||||
+ {
|
||||
+ CDVDOverlay* o = m_collection.Get(iPts);
|
||||
+ if(o == NULL)
|
||||
+ return o;
|
||||
+ return o->Clone();
|
||||
+ }
|
||||
virtual void Reset() { m_collection.Reset(); }
|
||||
virtual void Dispose() { m_collection.Clear(); }
|
||||
|
||||
--
|
||||
1.7.10
|
||||
|
@ -1,31 +0,0 @@
|
||||
From 8717c162b8c5092d77672351ce3bfa2d4e7e32d8 Mon Sep 17 00:00:00 2001
|
||||
From: fritsch <peter.fruehberger@gmail.com>
|
||||
Date: Tue, 5 Mar 2013 22:17:15 +0100
|
||||
Subject: [PATCH] AE: Fix resample of e.g. 192 khz to 48 khz audio by scaling
|
||||
the usual suspects with the src sampleRate
|
||||
|
||||
---
|
||||
xbmc/cores/AudioEngine/Engines/SoftAE/SoftAEStream.cpp | 7 +++++++
|
||||
1 file changed, 7 insertions(+)
|
||||
|
||||
diff --git a/xbmc/cores/AudioEngine/Engines/SoftAE/SoftAEStream.cpp b/xbmc/cores/AudioEngine/Engines/SoftAE/SoftAEStream.cpp
|
||||
index 258dcac..a64beb1 100644
|
||||
--- a/xbmc/cores/AudioEngine/Engines/SoftAE/SoftAEStream.cpp
|
||||
+++ b/xbmc/cores/AudioEngine/Engines/SoftAE/SoftAEStream.cpp
|
||||
@@ -196,6 +196,13 @@ void CSoftAEStream::Initialize()
|
||||
m_ssrcData.data_out = (float*)_aligned_malloc(m_format.m_frameSamples * (int)std::ceil(m_ssrcData.src_ratio) * sizeof(float), 16);
|
||||
m_ssrcData.output_frames = m_format.m_frames * (long)std::ceil(m_ssrcData.src_ratio);
|
||||
m_ssrcData.end_of_input = 0;
|
||||
+ // we must buffer the same amount as before but taking the source sample rate into account
|
||||
+ // there is no reason to decrease the buffer for upsampling
|
||||
+ if (m_internalRatio < 1)
|
||||
+ {
|
||||
+ m_waterLevel *= (1.0 / m_internalRatio);
|
||||
+ m_refillBuffer = m_waterLevel;
|
||||
+ }
|
||||
}
|
||||
|
||||
m_limiter.SetSamplerate(AE.GetSampleRate());
|
||||
--
|
||||
1.7.10
|
||||
|
@ -1,25 +0,0 @@
|
||||
From 249cccc2da097917995571b123ac22e30ed3f686 Mon Sep 17 00:00:00 2001
|
||||
From: popcornmix <popcornmix@gmail.com>
|
||||
Date: Thu, 7 Mar 2013 12:50:57 +0000
|
||||
Subject: [PATCH] [rbp] Enable Vsync as a default
|
||||
|
||||
---
|
||||
xbmc/settings/Settings.h | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/xbmc/settings/Settings.h b/xbmc/settings/Settings.h
|
||||
index fd44a0f..5ba1d36 100644
|
||||
--- a/xbmc/settings/Settings.h
|
||||
+++ b/xbmc/settings/Settings.h
|
||||
@@ -36,7 +36,7 @@
|
||||
#ifdef MID
|
||||
#define DEFAULT_VSYNC VSYNC_DISABLED
|
||||
#else // MID
|
||||
-#if defined(TARGET_DARWIN) || defined(_WIN32)
|
||||
+#if defined(TARGET_DARWIN) || defined(_WIN32) || defined(TARGET_RASPBERRY_PI)
|
||||
#define DEFAULT_VSYNC VSYNC_ALWAYS
|
||||
#else
|
||||
#define DEFAULT_VSYNC VSYNC_DRIVER
|
||||
--
|
||||
1.7.10
|
||||
|
@ -0,0 +1,34 @@
|
||||
From 88e250d43dcb13ec2a05f64994c57a3d96b024b4 Mon Sep 17 00:00:00 2001
|
||||
From: Jim Carroll <thecarrolls@jiminger.com>
|
||||
Date: Mon, 11 Mar 2013 03:19:46 -0400
|
||||
Subject: [PATCH] [fix] build issue with std::min on some platforms.
|
||||
|
||||
---
|
||||
xbmc/interfaces/legacy/File.h | 4 +++-
|
||||
1 file changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/xbmc/interfaces/legacy/File.h b/xbmc/interfaces/legacy/File.h
|
||||
index d8b5d26..d3c17b3 100644
|
||||
--- a/xbmc/interfaces/legacy/File.h
|
||||
+++ b/xbmc/interfaces/legacy/File.h
|
||||
@@ -27,6 +27,8 @@
|
||||
#include "LanguageHook.h"
|
||||
#include "commons/Buffer.h"
|
||||
|
||||
+#include <algorithm>
|
||||
+
|
||||
namespace XBMCAddon
|
||||
{
|
||||
|
||||
@@ -70,7 +72,7 @@
|
||||
inline String read(unsigned long numBytes = 0)
|
||||
{
|
||||
XbmcCommons::Buffer b = readBytes(numBytes);
|
||||
- return b.getString(numBytes == 0 ? b.remaining() : std::min(b.remaining(),numBytes));
|
||||
+ return b.getString(numBytes == 0 ? b.remaining() : std::min((unsigned long)b.remaining(),numBytes));
|
||||
}
|
||||
|
||||
/**
|
||||
--
|
||||
1.7.10
|
||||
|
@ -1,31 +0,0 @@
|
||||
From 7a9939f714bcafe8d6616bfbdeb87d2e4b1f24e8 Mon Sep 17 00:00:00 2001
|
||||
From: pitpompej <pitpompej@arcor.de>
|
||||
Date: Fri, 8 Mar 2013 21:05:31 +0100
|
||||
Subject: [PATCH] Prevent timeout error because of waiting for port settings
|
||||
change event on the wrong pipeline object when using
|
||||
deinterlace mode
|
||||
|
||||
---
|
||||
xbmc/cores/omxplayer/OMXVideo.cpp | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/xbmc/cores/omxplayer/OMXVideo.cpp b/xbmc/cores/omxplayer/OMXVideo.cpp
|
||||
index d4b8fbf..15bc8fa 100644
|
||||
--- a/xbmc/cores/omxplayer/OMXVideo.cpp
|
||||
+++ b/xbmc/cores/omxplayer/OMXVideo.cpp
|
||||
@@ -885,10 +885,10 @@ int COMXVideo::Decode(uint8_t *pData, int iSize, double dts, double pts)
|
||||
{
|
||||
CLog::Log(LOGERROR, "%s::%s - error m_omx_image_fx.SetParameter(OMX_IndexParamPortDefinition) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
}
|
||||
- omx_err = m_omx_decoder.WaitForEvent(OMX_EventPortSettingsChanged);
|
||||
+ omx_err = m_omx_image_fx.WaitForEvent(OMX_EventPortSettingsChanged);
|
||||
if(omx_err != OMX_ErrorNone)
|
||||
{
|
||||
- CLog::Log(LOGERROR, "%s::%s - error m_omx_decoder.WaitForEvent(OMX_EventPortSettingsChanged) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
+ CLog::Log(LOGERROR, "%s::%s - error m_omx_image_fx.WaitForEvent(OMX_EventPortSettingsChanged) omx_err(0x%08x)\n", CLASSNAME, __func__, omx_err);
|
||||
}
|
||||
port_image.nPortIndex = m_omx_image_fx.GetOutputPort();
|
||||
omx_err = m_omx_image_fx.GetParameter(OMX_IndexParamPortDefinition, &port_image);
|
||||
--
|
||||
1.7.10
|
||||
|
@ -20,7 +20,7 @@
|
||||
################################################################################
|
||||
|
||||
PKG_NAME="xbmc"
|
||||
PKG_VERSION="12.0.4"
|
||||
PKG_VERSION="12.0.5"
|
||||
GIT_REPO="-b Frodo git://github.com/xbmc/xbmc.git"
|
||||
DEST_DIR="$PKG_NAME-frodo"
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user