Compare commits

...

18 Commits
0.3.2 ... 0.3.7

Author SHA1 Message Date
Julian Scheel
d4077a142c Bump version to 0.3.7
Signed-off-by: Julian Scheel <julian@jusst.de>
2017-07-10 08:56:43 +02:00
Julian Scheel
6ee28476fa OctonetData: Use hash for channel nativeId
We previously assumed that the channelId provided by the Octonet would
only contain numbers and colons, which unfortunately is not true. The
satellite names could contain arbitrary characters, which then caused
the conversion to a numeric value to fail, stopping channels from being
distinguishable. This caused all EPG events to be mapped to the first
channel.

Signed-off-by: Julian Scheel <julian@jusst.de>
2017-07-06 14:21:41 +02:00
Julian Scheel
de0a0f9a81 AppVeyor: Provide built addon as artifact
Allow users to fetch the builds generated by AppVeyor.

Signed-off-by: Julian Scheel <julian@jusst.de>
2017-07-06 14:16:00 +02:00
Julian Scheel
1b0c31654a Travis: Build against Kodi Krypton
This is the Krypton support branch, so it shall be build-tested against
Krypton Kodi tree.

Signed-off-by: Julian Scheel <julian@jusst.de>
2017-05-26 10:46:28 +02:00
Julian Scheel
f260cb07e9 AppVeyor: Build against Kodi Krypton
This is the Krypton support branch, so it shall be build-tested against
Krypton Kodi tree.

Signed-off-by: Julian Scheel <julian@jusst.de>
2017-05-26 10:46:28 +02:00
Dennis Hamester
8549a31c8d Bump version to 0.3.6 2016-11-28 15:09:54 +01:00
Dennis Hamester
0a7fb087ac Bump pvr api version to 5.2.1 2016-11-28 15:09:25 +01:00
Dennis Hamester
5c0f000a91 Bump version to 0.3.5 2016-11-28 14:14:57 +01:00
Dennis Hamester
2b020cec9c README: Rewrite build instructions 2016-11-28 14:00:01 +01:00
Dennis Hamester
96a19310ca Change time parameter of SeekTime from int to double
See xbmc/xbmc#10985
2016-11-28 10:40:36 +01:00
Dennis Hamester
3a6f4eb7b5 Bump version to 0.3.4 2016-11-18 10:28:37 +01:00
Dennis Hamester
2067aba378 OctonetData: Remove unused variable 2016-11-16 12:32:36 +01:00
Dennis Hamester
b52f50ef30 OctonetData: Fix missing EPG data for the first channel 2016-11-16 12:31:27 +01:00
Dennis Hamester
d1f9af2225 OctonetData: Fix computing last_end in getEPG() 2016-11-14 11:36:51 +01:00
Julian Scheel
880d313bef Unify Digital Devices naming
Always write Digital Devices with a blank in between.

Signed-off-by: Julian Scheel <julian@jusst.de>
2016-11-11 20:49:27 +01:00
Julian Scheel
94eb166783 README: Add AppVeyor badge
Add a badge for AppVeyor (Windows) build status.

Signed-off-by: Julian Scheel <julian@jusst.de>
2016-11-10 17:54:14 +01:00
Dennis Hamester
ba7e50e79c client: Clear incoming signalStatus before filling it 2016-11-10 17:23:47 +01:00
Julian Scheel
5fc6fc2ebc README: Add build status
Signed-off-by: Julian Scheel <julian@jusst.de>
2016-11-10 17:20:24 +01:00
7 changed files with 76 additions and 44 deletions

View File

@@ -36,7 +36,7 @@ before_install:
#
before_script:
- cd $TRAVIS_BUILD_DIR/..
- git clone --depth=1 https://github.com/xbmc/xbmc.git
- git clone --depth=1 https://github.com/xbmc/xbmc.git -b Krypton
- mkdir -p xbmc/project/cmake/addons/addons/pvr.octonet
- echo "pvr.octonet https://github.com/DigitalDevices/pvr.octonet master" > xbmc/project/cmake/addons/addons/pvr.octonet/pvr.octonet.txt
- cd $TRAVIS_BUILD_DIR && mkdir build && cd build

View File

@@ -1,27 +1,40 @@
# Octonet PVR
DigitalDevices [Octonet] (http://www.digital-devices.eu/shop/de/netzwerk-tv/) PVR client addon for [Kodi] (http://kodi.tv)
Digital Devices [Octonet](http://www.digital-devices.eu/shop/de/netzwerk-tv/) PVR client addon for [Kodi](http://kodi.tv)
| Platform | Status |
|----------|--------|
| Linux + OS X (Travis) | [![Build Status](https://travis-ci.org/julianscheel/pvr.octonet.svg?branch=master)](https://travis-ci.org/julianscheel/pvr.octonet) |
| Windows (AppVeyor) | [![Build status](https://ci.appveyor.com/api/projects/status/m7dhmpmuf5coir5h?svg=true)](https://ci.appveyor.com/project/julianscheel/pvr-octonet) |
# Building
## Windows
1. Create a file `project/cmake/addons/addons/kodi.pvr.octonet/kodi.pvr.octonet.txt` containing a
single line `kodi.pvr.octonet file://C:\some\path`. The path doesn't matter and doesn't need to
actually exist.
These instructions work on all supported platforms for the most part. Obviously, paths need to be
adjusted according to your OS (`/` vs `\`). We use Linux paths here as an example.
2. Use a shell that has environment variables setup by Visual Studio for the native x86 toolchain.
Run the following in a new build directory and adjust paths accordingly:
Clone the `pvr.octonet` repository:
```
cmake -G "NMake Makefiles" ^
-DCMAKE_BUILD_TYPE=Release ^
-DADDONS_TO_BUILD="kodi.pvr.octonet" ^
-DADDON_SRC_PREFIX="path_to_where_kodi.pvr.octonet_is" ^
-DCMAKE_INSTALL_PREFIX="some_subdirectory" ^
-DPACKAGE_ZIP=ON ^
"path_to_kodi\project\cmake\addons"
$ git clone https://github.com/DigitalDevices/pvr.octonet.git
```
Make sure `ADDON_SRC_PREFIX` points to the parent directory of `kodi.pvr.octonet`.
Clone the Kodi repository:
4. Build the addon by running `nmake`. Run `nmake package-addons` to package a zip file of the
addon.
```
$ git clone https://github.com/xbmc/xbmc.git
```
If you already have a local Kodi checkout, you can use that one. Just make sure it is recent enough
(Kodi 17 Beta 5 or later should work).
```
$ cd pvr.octonet
$ mkdir build
$ cd build
$ cmake -DCMAKE_BUILD_TYPE=Release -DADDONS_TO_BUILD="pvr.octonet" -DADDON_SRC_PREFIX="path to parent of pvr.octonet" -DCMAKE_INSTALL_PREFIX="install" -DPACKAGE_ZIP=ON "path to kodi/project/cmake/addons"
```
On Windows, you should add `-G "NMake Makefiles"` to the CMake invocation. Make sure that
`ADDON_SRC_PREFIX` does _not_ point directly to `pvr.octonet` but instead to its parent directory.
Finally, build the plugin with `make` (or `nmake` on Windows). The plugin should be in an `install`
subdirectory.

View File

@@ -21,15 +21,20 @@ environment:
- GENERATOR: "Visual Studio 14"
CONFIG: Release
artifacts:
- path: build/install/
name: pvr.octonet
type: zip
build_script:
- cd ..
- set ROOT=%cd%
- git clone --depth=1 https://github.com/xbmc/xbmc.git
- git clone --depth=1 https://github.com/xbmc/xbmc.git -b Krypton
- mkdir xbmc\project\cmake\addons\addons\pvr.octonet
- echo pvr.octonet https://github.com/DigitalDevices/pvr.octonet master > xbmc\project\cmake\addons\addons\pvr.octonet\pvr.octonet.txt
- cd %ADDON%
- mkdir build
- cd build
# Must use absolute path for cmake to build depends correctly
- cmake -G "%GENERATOR%" -DADDONS_TO_BUILD=%ADDON% -DCMAKE_BUILD_TYPE=%CONFIG% -DADDON_SRC_PREFIX=%ROOT% -DCMAKE_INSTALL_PREFIX=%ROOT%\xbmc\addons -DPACKAGE_ZIP=1 %ROOT%\xbmc\project\cmake\addons
- cmake -G "%GENERATOR%" -DADDONS_TO_BUILD=%ADDON% -DCMAKE_BUILD_TYPE=%CONFIG% -DADDON_SRC_PREFIX=%ROOT% -DCMAKE_INSTALL_PREFIX=install -DPACKAGE_ZIP=1 %ROOT%\xbmc\project\cmake\addons
- cmake --build . --config %CONFIG%

7
debian/control vendored
View File

@@ -11,13 +11,12 @@ Package: kodi-pvr-octonet
Section: libs
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: DigitalDevices Octopus NET PVR for Kodi
Description: Digital Devices Octopus NET PVR for Kodi
Digital Devices Octopus NET PVR for Kodi
Package: kodi-pvr-octonet-dbg
Section: libs
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: debug symbols for DigitalDevices Octopus NET PVR for Kodi
debug symbols for DigitalDevices Octopus NET PVR for Kodi
Description: debug symbols for Digital Devices Octopus NET PVR for Kodi
debug symbols for Digital Devices Octopus NET PVR for Kodi

View File

@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<addon
id="pvr.octonet"
version="0.3.2"
name="PVR DigitalDevices Octopus NET Client"
version="0.3.7"
name="Digital Devices Octopus NET Client"
provider-name="digitaldevices">
<requires>
<c-pluff version="0.1" />
<import addon="xbmc.pvr" version="5.2.0" />
<import addon="xbmc.pvr" version="5.2.1" />
</requires>
<extension
point="xbmc.pvrclient"
@@ -16,8 +16,8 @@
library_windx="pvr.octonet.dll"
library_android="libpvr.octonet.so" />
<extension point="xbmc.addon.metadata">
<summary lang="de_DE">Kodi PVR Addon für DigitalDevices Octopus NET Streams</summary>
<summary lang="en_US">Kodi PVR Addon for DigitalDevices Octopus NET Streams</summary>
<summary lang="de_DE">Kodi PVR Addon für Digital Devices Octopus NET Streams</summary>
<summary lang="en_US">Kodi PVR Addon for Digital Devices Octopus NET Streams</summary>
<platform>all</platform>
</extension>
</addon>

View File

@@ -53,14 +53,8 @@ OctonetData::~OctonetData(void)
int64_t OctonetData::parseID(std::string id)
{
int64_t nativeId;
size_t strip;
/* Strip colons from id */
while ((strip = id.find(":")) != std::string::npos)
id.erase(strip, 1);
std::stringstream ids(id);
ids >> nativeId;
std::hash<std::string> hash_fn;
int64_t nativeId = hash_fn(id);
return nativeId;
}
@@ -125,7 +119,6 @@ OctonetChannel* OctonetData::findChannel(int64_t nativeId)
time_t OctonetData::parseDateTime(std::string date)
{
struct tm timeinfo;
time_t time;
memset(&timeinfo, 0, sizeof(timeinfo));
@@ -237,20 +230,23 @@ PVR_ERROR OctonetData::getChannels(ADDON_HANDLE handle, bool bRadio)
PVR_ERROR OctonetData::getEPG(ADDON_HANDLE handle, const PVR_CHANNEL &channel, time_t start, time_t end)
{
bool needs_reload = false;
for (unsigned int i = 0; i < channels.size(); i++)
{
OctonetChannel &chan = channels.at(i);
if (channel.iUniqueId != chan.id)
continue;
if(chan.epg.empty()) {
loadEPG();
}
// FIXME: Check if reload is needed!?
std::vector<OctonetEpgEntry>::iterator it;
time_t last_end = 0;
for (it = chan.epg.begin(); it < chan.epg.end(); ++it) {
if (end > last_end)
last_end = end;
for (it = chan.epg.begin(); it != chan.epg.end(); ++it) {
if (it->end > last_end)
last_end = it->end;
if (it->end < start || it->start > end) {
continue;
@@ -271,6 +267,24 @@ PVR_ERROR OctonetData::getEPG(ADDON_HANDLE handle, const PVR_CHANNEL &channel, t
if (last_end < end)
loadEPG();
for (it = chan.epg.begin(); it != chan.epg.end(); ++it) {
if (it->end < start || it->start > end) {
continue;
}
EPG_TAG entry;
memset(&entry, 0, sizeof(EPG_TAG));
entry.iChannelNumber = i;
entry.iUniqueBroadcastId = it->id;
entry.strTitle = it->title.c_str();
entry.strPlotOutline = it->subtitle.c_str();
entry.startTime = it->start;
entry.endTime = it->end;
pvr->TransferEpgEntry(handle, &entry);
}
}
return PVR_ERROR_NO_ERROR;

View File

@@ -157,7 +157,7 @@ PVR_ERROR GetAddonCapabilities(PVR_ADDON_CAPABILITIES *pCapabilities)
const char* GetBackendName(void)
{
return "DigitalDevices Octopus NET Client";
return "Digital Devices Octopus NET Client";
}
const char* GetBackendVersion(void)
@@ -271,6 +271,7 @@ bool SwitchChannel(const PVR_CHANNEL& channel) {
}
PVR_ERROR SignalStatus(PVR_SIGNAL_STATUS& signalStatus) {
memset(&signalStatus, 0, sizeof(PVR_SIGNAL_STATUS));
rtsp_fill_signal_status(signalStatus);
return PVR_ERROR_NO_ERROR;
}
@@ -301,7 +302,7 @@ bool CanSeekStream() { return false; }
/* Callbacks */
void PauseStream(bool bPaused) {}
bool SeekTime(int time, bool backwards, double *startpts) { return false; }
bool SeekTime(double time, bool backwards, double *startpts) { return false; }
void SetSpeed(int speed) {}
PVR_ERROR SetEPGTimeFrame(int) { return PVR_ERROR_NOT_IMPLEMENTED; }