mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-24 11:16:51 +00:00
xbmc: update to xbmc-13-0a5b020
Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
parent
a3f45c8072
commit
49aa69bf98
@ -17,7 +17,7 @@
|
||||
################################################################################
|
||||
|
||||
PKG_NAME="xbmc-theme-Confluence"
|
||||
PKG_VERSION="13-7f24c56"
|
||||
PKG_VERSION="13-0a5b020"
|
||||
PKG_REV="1"
|
||||
PKG_ARCH="any"
|
||||
PKG_LICENSE="GPL"
|
||||
|
@ -17,7 +17,7 @@
|
||||
################################################################################
|
||||
|
||||
PKG_NAME="xbmc"
|
||||
PKG_VERSION="13-7f24c56"
|
||||
PKG_VERSION="13-0a5b020"
|
||||
PKG_REV="1"
|
||||
PKG_ARCH="any"
|
||||
PKG_LICENSE="GPL"
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,26 +0,0 @@
|
||||
From 5c2362940defe41799d9d46aad4d31c391f342e8 Mon Sep 17 00:00:00 2001
|
||||
From: Rainer Hochecker <fernetmenta@online.de>
|
||||
Date: Mon, 14 Apr 2014 18:05:34 +0200
|
||||
Subject: [PATCH] ActiveAE: check suspend state before creating a stream
|
||||
|
||||
---
|
||||
xbmc/cores/AudioEngine/Engines/ActiveAE/ActiveAE.cpp | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/xbmc/cores/AudioEngine/Engines/ActiveAE/ActiveAE.cpp b/xbmc/cores/AudioEngine/Engines/ActiveAE/ActiveAE.cpp
|
||||
index a613004..e118294 100644
|
||||
--- a/xbmc/cores/AudioEngine/Engines/ActiveAE/ActiveAE.cpp
|
||||
+++ b/xbmc/cores/AudioEngine/Engines/ActiveAE/ActiveAE.cpp
|
||||
@@ -2632,6 +2632,9 @@ bool CActiveAE::ResampleSound(CActiveAESound *sound)
|
||||
|
||||
IAEStream *CActiveAE::MakeStream(enum AEDataFormat dataFormat, unsigned int sampleRate, unsigned int encodedSampleRate, CAEChannelInfo channelLayout, unsigned int options)
|
||||
{
|
||||
+ if (IsSuspended())
|
||||
+ return NULL;
|
||||
+
|
||||
//TODO: pass number of samples in audio packet
|
||||
|
||||
AEAudioFormat format;
|
||||
--
|
||||
1.9.1
|
||||
|
@ -1,208 +0,0 @@
|
||||
From 0c510ff6acea4a9afc049006ad8a173256aa8290 Mon Sep 17 00:00:00 2001
|
||||
From: Rainer Hochecker <fernetmenta@online.de>
|
||||
Date: Sat, 12 Apr 2014 18:13:32 +0200
|
||||
Subject: [PATCH 1/2] flac demuxer: improve seeking
|
||||
|
||||
---
|
||||
lib/ffmpeg/libavcodec/flac_parser.c | 8 +++++++
|
||||
lib/ffmpeg/libavformat/flacdec.c | 45 +++++++++++++++++++++++++++++++++++++
|
||||
2 files changed, 53 insertions(+)
|
||||
|
||||
diff --git a/lib/ffmpeg/libavcodec/flac_parser.c b/lib/ffmpeg/libavcodec/flac_parser.c
|
||||
index e2c6744..0b7bf9b 100644
|
||||
--- a/lib/ffmpeg/libavcodec/flac_parser.c
|
||||
+++ b/lib/ffmpeg/libavcodec/flac_parser.c
|
||||
@@ -468,6 +468,14 @@ static int get_best_header(FLACParseContext* fpc, const uint8_t **poutbuf,
|
||||
&fpc->wrap_buf,
|
||||
&fpc->wrap_buf_allocated_size);
|
||||
|
||||
+
|
||||
+ if (fpc->pc->flags & PARSER_FLAG_USE_CODEC_TS){
|
||||
+ if (header->fi.is_var_size)
|
||||
+ fpc->pc->pts = header->fi.frame_or_sample_num;
|
||||
+ else if (header->best_child)
|
||||
+ fpc->pc->pts = header->fi.frame_or_sample_num * header->fi.blocksize;
|
||||
+ }
|
||||
+
|
||||
fpc->best_header_valid = 0;
|
||||
/* Return the negative overread index so the client can compute pos.
|
||||
This should be the amount overread to the beginning of the child */
|
||||
diff --git a/lib/ffmpeg/libavformat/flacdec.c b/lib/ffmpeg/libavformat/flacdec.c
|
||||
index ecc47e6..66c8809 100644
|
||||
--- a/lib/ffmpeg/libavformat/flacdec.c
|
||||
+++ b/lib/ffmpeg/libavformat/flacdec.c
|
||||
@@ -284,12 +284,57 @@ static int flac_probe(AVProbeData *p)
|
||||
else return AVPROBE_SCORE_MAX/2;
|
||||
}
|
||||
|
||||
+static av_unused int64_t flac_read_timestamp(AVFormatContext *s, int stream_index,
|
||||
+ int64_t *ppos, int64_t pos_limit)
|
||||
+{
|
||||
+ AVPacket pkt, out_pkt;
|
||||
+ AVStream *st = s->streams[stream_index];
|
||||
+ int ret;
|
||||
+
|
||||
+ if (avio_seek(s->pb, *ppos, SEEK_SET) < 0)
|
||||
+ return AV_NOPTS_VALUE;
|
||||
+
|
||||
+ av_init_packet(&pkt);
|
||||
+ st->parser = av_parser_init(st->codec->codec_id);
|
||||
+ if (!st->parser){
|
||||
+ return AV_NOPTS_VALUE;
|
||||
+ }
|
||||
+ st->parser->flags |= PARSER_FLAG_USE_CODEC_TS;
|
||||
+
|
||||
+ for (;;){
|
||||
+ ret = ff_raw_read_partial_packet(s, &pkt);
|
||||
+ if (ret < 0){
|
||||
+ if (ret == AVERROR(EAGAIN))
|
||||
+ continue;
|
||||
+ else
|
||||
+ return AV_NOPTS_VALUE;
|
||||
+ }
|
||||
+ av_init_packet(&out_pkt);
|
||||
+ ret = av_parser_parse2(st->parser, st->codec,
|
||||
+ &out_pkt.data, &out_pkt.size, pkt.data, pkt.size,
|
||||
+ pkt.pts, pkt.dts, *ppos);
|
||||
+
|
||||
+ if (out_pkt.size){
|
||||
+ int size = out_pkt.size;
|
||||
+ av_free_packet(&out_pkt);
|
||||
+ if (st->parser->pts != AV_NOPTS_VALUE){
|
||||
+ // seeking may not have started from beginning of a frame
|
||||
+ // calculate frame start position from next frame backwards
|
||||
+ *ppos = st->parser->next_frame_offset - size;
|
||||
+ return st->parser->pts;
|
||||
+ }
|
||||
+ }
|
||||
+ }
|
||||
+ return AV_NOPTS_VALUE;
|
||||
+}
|
||||
+
|
||||
AVInputFormat ff_flac_demuxer = {
|
||||
.name = "flac",
|
||||
.long_name = NULL_IF_CONFIG_SMALL("raw FLAC"),
|
||||
.read_probe = flac_probe,
|
||||
.read_header = flac_read_header,
|
||||
.read_packet = ff_raw_read_partial_packet,
|
||||
+ .read_timestamp = flac_read_timestamp,
|
||||
.flags = AVFMT_GENERIC_INDEX,
|
||||
.extensions = "flac",
|
||||
.raw_codec_id = AV_CODEC_ID_FLAC,
|
||||
--
|
||||
1.9.1
|
||||
|
||||
|
||||
From f6a8444f36675da5df96ddc10e6b54160319675e Mon Sep 17 00:00:00 2001
|
||||
From: Rainer Hochecker <fernetmenta@online.de>
|
||||
Date: Mon, 14 Apr 2014 18:50:30 +0200
|
||||
Subject: [PATCH 2/2] ffmpeg: backport flac seeking patch
|
||||
|
||||
---
|
||||
.../0072-flac-demuxer-improve-seeking.patch | 94 ++++++++++++++++++++++
|
||||
1 file changed, 94 insertions(+)
|
||||
create mode 100644 lib/ffmpeg/patches/0072-flac-demuxer-improve-seeking.patch
|
||||
|
||||
diff --git a/lib/ffmpeg/patches/0072-flac-demuxer-improve-seeking.patch b/lib/ffmpeg/patches/0072-flac-demuxer-improve-seeking.patch
|
||||
new file mode 100644
|
||||
index 0000000..a6b6488
|
||||
--- /dev/null
|
||||
+++ b/lib/ffmpeg/patches/0072-flac-demuxer-improve-seeking.patch
|
||||
@@ -0,0 +1,94 @@
|
||||
+From 0c510ff6acea4a9afc049006ad8a173256aa8290 Mon Sep 17 00:00:00 2001
|
||||
+From: Rainer Hochecker <fernetmenta@online.de>
|
||||
+Date: Sat, 12 Apr 2014 18:13:32 +0200
|
||||
+Subject: [PATCH] flac demuxer: improve seeking
|
||||
+
|
||||
+---
|
||||
+ lib/ffmpeg/libavcodec/flac_parser.c | 8 +++++++
|
||||
+ lib/ffmpeg/libavformat/flacdec.c | 45 +++++++++++++++++++++++++++++++++++++
|
||||
+ 2 files changed, 53 insertions(+)
|
||||
+
|
||||
+diff --git a/lib/ffmpeg/libavcodec/flac_parser.c b/lib/ffmpeg/libavcodec/flac_parser.c
|
||||
+index e2c6744..0b7bf9b 100644
|
||||
+--- a/lib/ffmpeg/libavcodec/flac_parser.c
|
||||
++++ b/lib/ffmpeg/libavcodec/flac_parser.c
|
||||
+@@ -468,6 +468,14 @@ static int get_best_header(FLACParseContext* fpc, const uint8_t **poutbuf,
|
||||
+ &fpc->wrap_buf,
|
||||
+ &fpc->wrap_buf_allocated_size);
|
||||
+
|
||||
++
|
||||
++ if (fpc->pc->flags & PARSER_FLAG_USE_CODEC_TS){
|
||||
++ if (header->fi.is_var_size)
|
||||
++ fpc->pc->pts = header->fi.frame_or_sample_num;
|
||||
++ else if (header->best_child)
|
||||
++ fpc->pc->pts = header->fi.frame_or_sample_num * header->fi.blocksize;
|
||||
++ }
|
||||
++
|
||||
+ fpc->best_header_valid = 0;
|
||||
+ /* Return the negative overread index so the client can compute pos.
|
||||
+ This should be the amount overread to the beginning of the child */
|
||||
+diff --git a/lib/ffmpeg/libavformat/flacdec.c b/lib/ffmpeg/libavformat/flacdec.c
|
||||
+index ecc47e6..66c8809 100644
|
||||
+--- a/lib/ffmpeg/libavformat/flacdec.c
|
||||
++++ b/lib/ffmpeg/libavformat/flacdec.c
|
||||
+@@ -284,12 +284,57 @@ static int flac_probe(AVProbeData *p)
|
||||
+ else return AVPROBE_SCORE_MAX/2;
|
||||
+ }
|
||||
+
|
||||
++static av_unused int64_t flac_read_timestamp(AVFormatContext *s, int stream_index,
|
||||
++ int64_t *ppos, int64_t pos_limit)
|
||||
++{
|
||||
++ AVPacket pkt, out_pkt;
|
||||
++ AVStream *st = s->streams[stream_index];
|
||||
++ int ret;
|
||||
++
|
||||
++ if (avio_seek(s->pb, *ppos, SEEK_SET) < 0)
|
||||
++ return AV_NOPTS_VALUE;
|
||||
++
|
||||
++ av_init_packet(&pkt);
|
||||
++ st->parser = av_parser_init(st->codec->codec_id);
|
||||
++ if (!st->parser){
|
||||
++ return AV_NOPTS_VALUE;
|
||||
++ }
|
||||
++ st->parser->flags |= PARSER_FLAG_USE_CODEC_TS;
|
||||
++
|
||||
++ for (;;){
|
||||
++ ret = ff_raw_read_partial_packet(s, &pkt);
|
||||
++ if (ret < 0){
|
||||
++ if (ret == AVERROR(EAGAIN))
|
||||
++ continue;
|
||||
++ else
|
||||
++ return AV_NOPTS_VALUE;
|
||||
++ }
|
||||
++ av_init_packet(&out_pkt);
|
||||
++ ret = av_parser_parse2(st->parser, st->codec,
|
||||
++ &out_pkt.data, &out_pkt.size, pkt.data, pkt.size,
|
||||
++ pkt.pts, pkt.dts, *ppos);
|
||||
++
|
||||
++ if (out_pkt.size){
|
||||
++ int size = out_pkt.size;
|
||||
++ av_free_packet(&out_pkt);
|
||||
++ if (st->parser->pts != AV_NOPTS_VALUE){
|
||||
++ // seeking may not have started from beginning of a frame
|
||||
++ // calculate frame start position from next frame backwards
|
||||
++ *ppos = st->parser->next_frame_offset - size;
|
||||
++ return st->parser->pts;
|
||||
++ }
|
||||
++ }
|
||||
++ }
|
||||
++ return AV_NOPTS_VALUE;
|
||||
++}
|
||||
++
|
||||
+ AVInputFormat ff_flac_demuxer = {
|
||||
+ .name = "flac",
|
||||
+ .long_name = NULL_IF_CONFIG_SMALL("raw FLAC"),
|
||||
+ .read_probe = flac_probe,
|
||||
+ .read_header = flac_read_header,
|
||||
+ .read_packet = ff_raw_read_partial_packet,
|
||||
++ .read_timestamp = flac_read_timestamp,
|
||||
+ .flags = AVFMT_GENERIC_INDEX,
|
||||
+ .extensions = "flac",
|
||||
+ .raw_codec_id = AV_CODEC_ID_FLAC,
|
||||
+--
|
||||
+1.9.1
|
||||
+
|
||||
--
|
||||
1.9.1
|
||||
|
@ -1,103 +0,0 @@
|
||||
From 9707c09eb7a14c66a8f1fcacce1ca76c640aa441 Mon Sep 17 00:00:00 2001
|
||||
From: ruuk <xbmc@2ndmind.net>
|
||||
Date: Sun, 30 Mar 2014 11:22:23 -0700
|
||||
Subject: [PATCH] Added optional parameter 'ignoreCache' to xbmc.playSFX()
|
||||
Added parameter 'ignoreCache' to g_audioManager.PlayPythonSound() When
|
||||
ignoreCache is true, PlayPythonSound no frees any matching cached sound
|
||||
before continuing
|
||||
|
||||
---
|
||||
xbmc/guilib/GUIAudioManager.cpp | 14 +++++++++++---
|
||||
xbmc/guilib/GUIAudioManager.h | 2 +-
|
||||
xbmc/interfaces/legacy/ModuleXbmc.cpp | 4 ++--
|
||||
xbmc/interfaces/legacy/ModuleXbmc.h | 3 ++-
|
||||
4 files changed, 16 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/xbmc/guilib/GUIAudioManager.cpp b/xbmc/guilib/GUIAudioManager.cpp
|
||||
index aeb83a6..d0893e7 100644
|
||||
--- a/xbmc/guilib/GUIAudioManager.cpp
|
||||
+++ b/xbmc/guilib/GUIAudioManager.cpp
|
||||
@@ -131,7 +131,7 @@ void CGUIAudioManager::PlayWindowSound(int id, WINDOW_SOUND event)
|
||||
}
|
||||
|
||||
// \brief Play a sound given by filename
|
||||
-void CGUIAudioManager::PlayPythonSound(const CStdString& strFileName)
|
||||
+void CGUIAudioManager::PlayPythonSound(const CStdString& strFileName, bool ignoreCache)
|
||||
{
|
||||
CSingleLock lock(m_cs);
|
||||
|
||||
@@ -144,8 +144,16 @@ void CGUIAudioManager::PlayPythonSound(const CStdString& strFileName)
|
||||
if (itsb != m_pythonSounds.end())
|
||||
{
|
||||
IAESound* sound = itsb->second;
|
||||
- sound->Play();
|
||||
- return;
|
||||
+ if (ignoreCache)
|
||||
+ {
|
||||
+ FreeSound(sound);
|
||||
+ m_pythonSounds.erase(itsb);
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ sound->Play();
|
||||
+ return;
|
||||
+ }
|
||||
}
|
||||
|
||||
IAESound *sound = LoadSound(strFileName);
|
||||
diff --git a/xbmc/guilib/GUIAudioManager.h b/xbmc/guilib/GUIAudioManager.h
|
||||
index ab0d965..a38f579 100644
|
||||
--- a/xbmc/guilib/GUIAudioManager.h
|
||||
+++ b/xbmc/guilib/GUIAudioManager.h
|
||||
@@ -66,7 +66,7 @@ class CGUIAudioManager : public ISettingCallback
|
||||
|
||||
void PlayActionSound(const CAction& action);
|
||||
void PlayWindowSound(int id, WINDOW_SOUND event);
|
||||
- void PlayPythonSound(const CStdString& strFileName);
|
||||
+ void PlayPythonSound(const CStdString& strFileName, bool ignoreCache);
|
||||
|
||||
void Enable(bool bEnable);
|
||||
void SetVolume(float level);
|
||||
diff --git a/xbmc/interfaces/legacy/ModuleXbmc.cpp b/xbmc/interfaces/legacy/ModuleXbmc.cpp
|
||||
index 6507155..28a865f 100644
|
||||
--- a/xbmc/interfaces/legacy/ModuleXbmc.cpp
|
||||
+++ b/xbmc/interfaces/legacy/ModuleXbmc.cpp
|
||||
@@ -325,7 +325,7 @@
|
||||
return g_infoManager.GetImage(ret, WINDOW_INVALID);
|
||||
}
|
||||
|
||||
- void playSFX(const char* filename)
|
||||
+ void playSFX(const char* filename, bool ignoreCache)
|
||||
{
|
||||
XBMC_TRACE;
|
||||
if (!filename)
|
||||
@@ -333,7 +333,7 @@
|
||||
|
||||
if (XFILE::CFile::Exists(filename))
|
||||
{
|
||||
- g_audioManager.PlayPythonSound(filename);
|
||||
+ g_audioManager.PlayPythonSound(filename,ignoreCache);
|
||||
}
|
||||
}
|
||||
|
||||
diff --git a/xbmc/interfaces/legacy/ModuleXbmc.h b/xbmc/interfaces/legacy/ModuleXbmc.h
|
||||
index f26fa93..35c20e3 100644
|
||||
--- a/xbmc/interfaces/legacy/ModuleXbmc.h
|
||||
+++ b/xbmc/interfaces/legacy/ModuleXbmc.h
|
||||
@@ -223,11 +223,12 @@
|
||||
* playSFX(filename) -- Plays a wav file by filename
|
||||
*
|
||||
* filename : string - filename of the wav file to play.
|
||||
+ * ignoreCache : [opt] bool - True = Ignores any previously cached wav associated with filename
|
||||
*
|
||||
* example:
|
||||
* - xbmc.playSFX('special://xbmc/scripts/dingdong.wav')
|
||||
*/
|
||||
- void playSFX(const char* filename);
|
||||
+ void playSFX(const char* filename, bool ignoreCache = false);
|
||||
|
||||
/**
|
||||
* stopSFX() -- Stops wav file
|
||||
--
|
||||
1.9.1
|
||||
|
Loading…
x
Reference in New Issue
Block a user