summaryrefslogtreecommitdiffstats
path: root/xbmc/cores
diff options
context:
space:
mode:
authormanuel <manuel@mausz.at>2018-01-01 16:26:10 +0100
committermanuel <manuel@mausz.at>2018-01-01 16:26:10 +0100
commita51f51db67e3eab80ac2ed28d403a6d77f7acc45 (patch)
tree72e41d0283d3db549ea5a22e3c9063ef2a971d54 /xbmc/cores
parent4830f27a40323fe859dc166337a2b861877b7121 (diff)
downloadkodi-pvr-build-a51f51db67e3eab80ac2ed28d403a6d77f7acc45.tar.gz
kodi-pvr-build-a51f51db67e3eab80ac2ed28d403a6d77f7acc45.tar.bz2
kodi-pvr-build-a51f51db67e3eab80ac2ed28d403a6d77f7acc45.zip
sync with upstream
Diffstat (limited to 'xbmc/cores')
-rw-r--r--xbmc/cores/VideoPlayer/Interface/Addon/DemuxCrypto.h (renamed from xbmc/cores/VideoPlayer/DVDDemuxers/DemuxCrypto.h)6
-rw-r--r--xbmc/cores/VideoPlayer/Interface/Addon/DemuxPacket.h (renamed from xbmc/cores/VideoPlayer/DVDDemuxers/DVDDemuxPacket.h)27
-rw-r--r--xbmc/cores/VideoPlayer/Interface/Addon/TimingConstants.h31
3 files changed, 49 insertions, 15 deletions
diff --git a/xbmc/cores/VideoPlayer/DVDDemuxers/DemuxCrypto.h b/xbmc/cores/VideoPlayer/Interface/Addon/DemuxCrypto.h
index a32f4fe..c77d000 100644
--- a/xbmc/cores/VideoPlayer/DVDDemuxers/DemuxCrypto.h
+++ b/xbmc/cores/VideoPlayer/Interface/Addon/DemuxCrypto.h
@@ -55,6 +55,9 @@ struct DemuxCryptoSession
55 55
56 static const uint8_t FLAG_SECURE_DECODER = 1; 56 static const uint8_t FLAG_SECURE_DECODER = 1;
57 uint8_t flags; 57 uint8_t flags;
58private:
59 DemuxCryptoSession(const DemuxCryptoSession&) = delete;
60 DemuxCryptoSession& operator=(const DemuxCryptoSession&) = delete;
58}; 61};
59 62
60//CryptoInfo stores the information to decrypt a sample 63//CryptoInfo stores the information to decrypt a sample
@@ -82,4 +85,7 @@ struct DemuxCryptoInfo
82 85
83 uint8_t iv[16]; // initialization vector 86 uint8_t iv[16]; // initialization vector
84 uint8_t kid[16]; // key id 87 uint8_t kid[16]; // key id
88private:
89 DemuxCryptoInfo(const DemuxCryptoInfo&) = delete;
90 DemuxCryptoInfo& operator=(const DemuxCryptoInfo&) = delete;
85}; 91};
diff --git a/xbmc/cores/VideoPlayer/DVDDemuxers/DVDDemuxPacket.h b/xbmc/cores/VideoPlayer/Interface/Addon/DemuxPacket.h
index 77d796e..2d85ed9 100644
--- a/xbmc/cores/VideoPlayer/DVDDemuxers/DVDDemuxPacket.h
+++ b/xbmc/cores/VideoPlayer/Interface/Addon/DemuxPacket.h
@@ -20,6 +20,7 @@
20 * 20 *
21 */ 21 */
22 22
23#include "TimingConstants.h"
23#include <cstdint> 24#include <cstdint>
24#include <memory> 25#include <memory>
25 26
@@ -32,24 +33,20 @@ typedef struct DemuxPacket
32{ 33{
33 DemuxPacket() = default; 34 DemuxPacket() = default;
34 35
35 DemuxPacket(unsigned char *pData, int const iSize, double const pts, double const dts) 36 uint8_t *pData = nullptr;
36 : pData(pData) 37 int iSize = 0;
37 , iSize(iSize) 38 int iStreamId = -1;
38 , pts(pts)
39 , dts(dts)
40 {};
41
42 unsigned char *pData; // data
43 int iSize; // data size
44 int iStreamId; // integer representing the stream index
45 int64_t demuxerId; // id of the demuxer that created the packet 39 int64_t demuxerId; // id of the demuxer that created the packet
46 int iGroupId; // the group this data belongs to, used to group data from different streams together 40 int iGroupId = -1; // the group this data belongs to, used to group data from different streams together
47 41
48 double pts; // pts in DVD_TIME_BASE 42 void *pSideData = nullptr;
49 double dts; // dts in DVD_TIME_BASE 43 int iSideDataElems = 0;
50 double duration; // duration in DVD_TIME_BASE if available
51 44
52 int dispTime; 45 double pts = DVD_NOPTS_VALUE;
46 double dts = DVD_NOPTS_VALUE;
47 double duration = 0; // duration in DVD_TIME_BASE if available
48 int dispTime = 0;
49 bool recoveryPoint = false;
53 50
54 std::shared_ptr<DemuxCryptoInfo> cryptoInfo; 51 std::shared_ptr<DemuxCryptoInfo> cryptoInfo;
55} DemuxPacket; 52} DemuxPacket;
diff --git a/xbmc/cores/VideoPlayer/Interface/Addon/TimingConstants.h b/xbmc/cores/VideoPlayer/Interface/Addon/TimingConstants.h
new file mode 100644
index 0000000..b70128e
--- /dev/null
+++ b/xbmc/cores/VideoPlayer/Interface/Addon/TimingConstants.h
@@ -0,0 +1,31 @@
1#pragma once
2
3/*
4* Copyright (C) 2017 Team XBMC
5* http://xbmc.org
6*
7* This Program is free software; you can redistribute it and/or modify
8* it under the terms of the GNU General Public License as published by
9* the Free Software Foundation; either version 2, or (at your option)
10* any later version.
11*
12* This Program is distributed in the hope that it will be useful,
13* but WITHOUT ANY WARRANTY; without even the implied warranty of
14* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15* GNU General Public License for more details.
16*
17* You should have received a copy of the GNU General Public License
18* along with XBMC; see the file COPYING. If not, see
19* <http://www.gnu.org/licenses/>.
20*
21*/
22
23#define DVD_TIME_BASE 1000000
24#define DVD_NOPTS_VALUE 0xFFF0000000000000
25
26#define DVD_TIME_TO_MSEC(x) ((int)((double)(x) * 1000 / DVD_TIME_BASE))
27#define DVD_SEC_TO_TIME(x) ((double)(x) * DVD_TIME_BASE)
28#define DVD_MSEC_TO_TIME(x) ((double)(x) * DVD_TIME_BASE / 1000)
29
30#define DVD_PLAYSPEED_PAUSE 0 // frame stepping
31#define DVD_PLAYSPEED_NORMAL 1000