mirror of
https://github.com/rofafor/vdr-plugin-iptv.git
synced 2023-10-10 11:37:03 +00:00
Compare commits
28 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c1544453b6 | ||
|
|
5c14668598 | ||
|
|
d4a255a773 | ||
|
|
24bcf25571 | ||
|
|
78f4a2a0fc | ||
|
|
65d79abbf4 | ||
|
|
caf326bb4d | ||
|
|
18c2962cd9 | ||
|
|
1e2d0955de | ||
|
|
27437381d0 | ||
|
|
7ce44c9175 | ||
|
|
7206a8d189 | ||
|
|
dce9d3361f | ||
|
|
d71f79bdd8 | ||
|
|
dcf7ce5447 | ||
|
|
3ae015cf51 | ||
|
|
4915630cfc | ||
|
|
28d1869a28 | ||
|
|
c8c9dccf2b | ||
|
|
adcde3954c | ||
|
|
c3d38f2345 | ||
|
|
8f552bd19f | ||
|
|
3b5b7eac24 | ||
|
|
3daea8b1ba | ||
|
|
b5744903cd | ||
|
|
61a588ed22 | ||
|
|
9e630760f6 | ||
|
|
b3b0ae3567 |
14
HISTORY
14
HISTORY
@@ -24,3 +24,17 @@ VDR Plugin 'iptv' Revision History
|
||||
- Added German translation (Thanks to Tobias Grimm).
|
||||
- Added pluginparam patch for vdr-1.5.11.
|
||||
- Updated Makefile 'i18n' targets.
|
||||
|
||||
2007-11-27: Version 0.0.5
|
||||
|
||||
- Added French translation (Thanks to Bruno Roussel).
|
||||
- Added a more sophisticated example script (Thanks to Tobias Grimm).
|
||||
- Improved iptvstream.sh compatibility under non-bash shells.
|
||||
|
||||
2008-01-20: Version 0.0.6
|
||||
|
||||
- Fixed some lint warnings.
|
||||
- Added Italian translation (Thanks to Gringo).
|
||||
- Added '-Wno-parentheses' to the compiler options.
|
||||
- Mapped 'kInfo' as help key in setup menu.
|
||||
- Refactored statistic collecting code.
|
||||
|
||||
4
Makefile
4
Makefile
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# Makefile for a Video Disk Recorder plugin
|
||||
#
|
||||
# $Id: Makefile,v 1.23 2007/11/04 14:13:11 rahrenbe Exp $
|
||||
# $Id: Makefile,v 1.24 2008/01/13 16:45:02 rahrenbe Exp $
|
||||
|
||||
# Debugging on/off
|
||||
#IPTV_DEBUG = 1
|
||||
@@ -24,7 +24,7 @@ VERSION = $(shell grep 'static const char VERSION\[\] *=' $(PLUGIN).c | awk '{ p
|
||||
### The C++ compiler and options:
|
||||
|
||||
CXX ?= g++
|
||||
CXXFLAGS ?= -fPIC -g -O2 -Wall -Woverloaded-virtual
|
||||
CXXFLAGS ?= -fPIC -g -O2 -Wall -Woverloaded-virtual -Wno-parentheses
|
||||
|
||||
### The directory environment:
|
||||
|
||||
|
||||
4
common.c
4
common.c
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: common.c,v 1.8 2007/10/26 23:18:50 rahrenbe Exp $
|
||||
* $Id: common.c,v 1.9 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#include <vdr/tools.h>
|
||||
@@ -23,7 +23,7 @@ uint8_t payload(const uint8_t *tsp)
|
||||
if (tsp[4] > 183) // corrupted data?
|
||||
return 0;
|
||||
else
|
||||
return 184 - 1 - tsp[4];
|
||||
return (184 - 1) - tsp[4];
|
||||
}
|
||||
|
||||
return 184;
|
||||
|
||||
4
common.h
4
common.h
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: common.h,v 1.18 2007/10/28 16:22:44 rahrenbe Exp $
|
||||
* $Id: common.h,v 1.19 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_COMMON_H
|
||||
@@ -63,6 +63,8 @@
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof(arr[0]))
|
||||
|
||||
uint16_t ts_pid(const uint8_t *buf);
|
||||
uint8_t payload(const uint8_t *tsp);
|
||||
const char *id_pid(const u_short Pid);
|
||||
|
||||
14
config.c
14
config.c
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: config.c,v 1.18 2007/10/20 17:26:46 rahrenbe Exp $
|
||||
* $Id: config.c,v 1.19 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#include "config.h"
|
||||
@@ -19,27 +19,27 @@ cIptvConfig::cIptvConfig(void)
|
||||
sectionFiltering(1),
|
||||
sidScanning(1)
|
||||
{
|
||||
for (unsigned int i = 0; i < sizeof(disabledFilters); ++i)
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(disabledFilters) - 1; ++i)
|
||||
disabledFilters[i] = -1;
|
||||
memset(configDirectory, '\0', sizeof(configDirectory));
|
||||
}
|
||||
|
||||
unsigned int cIptvConfig::GetDisabledFiltersCount(void)
|
||||
unsigned int cIptvConfig::GetDisabledFiltersCount(void) const
|
||||
{
|
||||
unsigned int n = 0;
|
||||
while ((disabledFilters[n] != -1) && (n < sizeof(disabledFilters)))
|
||||
while ((disabledFilters[n] != -1) && (n < ARRAY_SIZE(disabledFilters) - 1))
|
||||
n++;
|
||||
return n;
|
||||
}
|
||||
|
||||
int cIptvConfig::GetDisabledFilters(unsigned int Index)
|
||||
int cIptvConfig::GetDisabledFilters(unsigned int Index) const
|
||||
{
|
||||
return (Index < sizeof(disabledFilters)) ? disabledFilters[Index] : -1;
|
||||
return (Index < ARRAY_SIZE(disabledFilters)) ? disabledFilters[Index] : -1;
|
||||
}
|
||||
|
||||
void cIptvConfig::SetDisabledFilters(unsigned int Index, int Number)
|
||||
{
|
||||
if (Index < sizeof(disabledFilters))
|
||||
if (Index < ARRAY_SIZE(disabledFilters))
|
||||
disabledFilters[Index] = Number;
|
||||
}
|
||||
|
||||
|
||||
22
config.h
22
config.h
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: config.h,v 1.17 2007/10/28 16:22:44 rahrenbe Exp $
|
||||
* $Id: config.h,v 1.18 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_CONFIG_H
|
||||
@@ -27,16 +27,16 @@ private:
|
||||
|
||||
public:
|
||||
cIptvConfig();
|
||||
unsigned int GetReadBufferTsCount(void) { return readBufferTsCount; }
|
||||
unsigned int GetTsBufferSize(void) { return tsBufferSize; }
|
||||
unsigned int GetTsBufferPrefillRatio(void) { return tsBufferPrefillRatio; }
|
||||
unsigned int GetExtProtocolBasePort(void) { return extProtocolBasePort; }
|
||||
unsigned int GetUseBytes(void) { return useBytes; }
|
||||
unsigned int GetSectionFiltering(void) { return sectionFiltering; }
|
||||
unsigned int GetSidScanning(void) { return sidScanning; }
|
||||
const char *GetConfigDirectory(void) { return configDirectory; }
|
||||
unsigned int GetDisabledFiltersCount(void);
|
||||
int GetDisabledFilters(unsigned int Index);
|
||||
unsigned int GetReadBufferTsCount(void) const { return readBufferTsCount; }
|
||||
unsigned int GetTsBufferSize(void) const { return tsBufferSize; }
|
||||
unsigned int GetTsBufferPrefillRatio(void) const { return tsBufferPrefillRatio; }
|
||||
unsigned int GetExtProtocolBasePort(void) const { return extProtocolBasePort; }
|
||||
unsigned int GetUseBytes(void) const { return useBytes; }
|
||||
unsigned int GetSectionFiltering(void) const { return sectionFiltering; }
|
||||
unsigned int GetSidScanning(void) const { return sidScanning; }
|
||||
const char *GetConfigDirectory(void) const { return configDirectory; }
|
||||
unsigned int GetDisabledFiltersCount(void) const;
|
||||
int GetDisabledFilters(unsigned int Index) const;
|
||||
void SetTsBufferSize(unsigned int Size) { tsBufferSize = Size; }
|
||||
void SetTsBufferPrefillRatio(unsigned int Ratio) { tsBufferPrefillRatio = Ratio; }
|
||||
void SetExtProtocolBasePort(unsigned int PortNumber) { extProtocolBasePort = PortNumber; }
|
||||
|
||||
19
device.c
19
device.c
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: device.c,v 1.76 2007/10/26 23:48:30 rahrenbe Exp $
|
||||
* $Id: device.c,v 1.78 2008/01/19 21:08:02 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#include "config.h"
|
||||
@@ -33,7 +33,7 @@ cIptvDevice::cIptvDevice(unsigned int Index)
|
||||
pExtProtocol = new cIptvProtocolExt();
|
||||
pIptvStreamer = new cIptvStreamer(tsBuffer, &mutex);
|
||||
// Initialize filter pointers
|
||||
memset(&secfilters, '\0', sizeof(secfilters));
|
||||
memset(secfilters, '\0', sizeof(secfilters));
|
||||
// Start section handler for iptv device
|
||||
StartSectionHandler();
|
||||
// Sid scanner must be created after the section handler
|
||||
@@ -102,15 +102,15 @@ cString cIptvDevice::GetGeneralInformation(void)
|
||||
return cString::sprintf("IPTV device: %d\nCardIndex: %d\n%s%s%sChannel: %s",
|
||||
deviceIndex, CardIndex(),
|
||||
pIptvStreamer ? *pIptvStreamer->GetInformation() : "",
|
||||
pIptvStreamer ? *pIptvStreamer->GetStatistic() : "",
|
||||
*cIptvBufferStatistics::GetStatistic(),
|
||||
pIptvStreamer ? *pIptvStreamer->GetStreamerStatistic() : "",
|
||||
*GetBufferStatistic(),
|
||||
*Channels.GetByNumber(cDevice::CurrentChannel())->ToText());
|
||||
}
|
||||
|
||||
cString cIptvDevice::GetPidsInformation(void)
|
||||
{
|
||||
//debug("cIptvDevice::GetPidsInformation(%d)\n", deviceIndex);
|
||||
return cIptvPidStatistics::GetStatistic();
|
||||
return GetPidStatistic();
|
||||
}
|
||||
|
||||
cString cIptvDevice::GetFiltersInformation(void)
|
||||
@@ -122,7 +122,7 @@ cString cIptvDevice::GetFiltersInformation(void)
|
||||
for (unsigned int i = 0; i < eMaxSecFilterCount; ++i) {
|
||||
if (secfilters[i]) {
|
||||
info = cString::sprintf("%sFilter %d: %s Pid=0x%02X (%s)\n", *info, i,
|
||||
*secfilters[i]->GetStatistic(), secfilters[i]->GetPid(),
|
||||
*secfilters[i]->GetSectionStatistic(), secfilters[i]->GetPid(),
|
||||
id_pid(secfilters[i]->GetPid()));
|
||||
if (++count > IPTV_STATS_ACTIVE_FILTERS_COUNT)
|
||||
break;
|
||||
@@ -320,7 +320,8 @@ void cIptvDevice::CloseDvr(void)
|
||||
debug("cIptvDevice::CloseDvr(%d)\n", deviceIndex);
|
||||
if (pSidScanner && IptvConfig.GetSectionFiltering() && IptvConfig.GetSidScanning())
|
||||
pSidScanner->SetStatus(false);
|
||||
pIptvStreamer->Close();
|
||||
if (pIptvStreamer)
|
||||
pIptvStreamer->Close();
|
||||
isOpenDvr = false;
|
||||
}
|
||||
|
||||
@@ -358,7 +359,7 @@ bool cIptvDevice::GetTSPacket(uchar *&Data)
|
||||
tsBuffer->Del(TS_SIZE);
|
||||
isPacketDelivered = false;
|
||||
// Update buffer statistics
|
||||
cIptvBufferStatistics::AddStatistic(TS_SIZE, tsBuffer->Available());
|
||||
AddBufferStatistic(TS_SIZE, tsBuffer->Available());
|
||||
}
|
||||
uchar *p = tsBuffer->Get(Count);
|
||||
if (p && Count >= TS_SIZE) {
|
||||
@@ -376,7 +377,7 @@ bool cIptvDevice::GetTSPacket(uchar *&Data)
|
||||
isPacketDelivered = true;
|
||||
Data = p;
|
||||
// Update pid statistics
|
||||
cIptvPidStatistics::AddStatistic(ts_pid(p), payload(p));
|
||||
AddPidStatistic(ts_pid(p), payload(p));
|
||||
// Run the data through all filters
|
||||
for (unsigned int i = 0; i < eMaxSecFilterCount; ++i) {
|
||||
if (secfilters[i])
|
||||
|
||||
8
device.h
8
device.h
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: device.h,v 1.34 2007/10/19 21:36:28 rahrenbe Exp $
|
||||
* $Id: device.h,v 1.35 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_DEVICE_H
|
||||
@@ -53,8 +53,12 @@ public:
|
||||
virtual ~cIptvDevice();
|
||||
cString GetInformation(unsigned int Page = IPTV_DEVICE_INFO_ALL);
|
||||
|
||||
// for statistics and general information
|
||||
// copy and assignment constructors
|
||||
private:
|
||||
cIptvDevice(const cIptvDevice&);
|
||||
cIptvDevice& operator=(const cIptvDevice&);
|
||||
|
||||
// for statistics and general information
|
||||
cString GetGeneralInformation(void);
|
||||
cString GetPidsInformation(void);
|
||||
cString GetFiltersInformation(void);
|
||||
|
||||
12
iptv.c
12
iptv.c
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: iptv.c,v 1.28 2007/10/29 21:21:39 rahrenbe Exp $
|
||||
* $Id: iptv.c,v 1.33 2008/01/19 20:24:10 rahrenbe Exp $
|
||||
*/
|
||||
|
||||
#include <getopt.h>
|
||||
@@ -22,7 +22,7 @@
|
||||
#error "You must apply the closefilter patch for VDR!"
|
||||
#endif
|
||||
|
||||
static const char VERSION[] = "0.0.4";
|
||||
static const char VERSION[] = "0.0.6";
|
||||
static const char DESCRIPTION[] = trNOOP("Experience the IPTV");
|
||||
|
||||
class cPluginIptv : public cPlugin {
|
||||
@@ -193,9 +193,11 @@ bool cPluginIptv::SetupParse(const char *Name, const char *Value)
|
||||
else if (!strcasecmp(Name, "SidScanning"))
|
||||
IptvConfig.SetSidScanning(atoi(Value));
|
||||
else if (!strcasecmp(Name, "DisabledFilters")) {
|
||||
int DisabledFilters[SECTION_FILTER_TABLE_SIZE] = { -1 };
|
||||
int DisabledFiltersCount = ParseFilters(Value, DisabledFilters);
|
||||
for (int i = 0; i < DisabledFiltersCount; ++i)
|
||||
int DisabledFilters[SECTION_FILTER_TABLE_SIZE];
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(DisabledFilters); ++i)
|
||||
DisabledFilters[i] = -1;
|
||||
unsigned int DisabledFiltersCount = ParseFilters(Value, DisabledFilters);
|
||||
for (unsigned int i = 0; i < DisabledFiltersCount; ++i)
|
||||
IptvConfig.SetDisabledFilters(i, DisabledFilters[i]);
|
||||
}
|
||||
else
|
||||
|
||||
@@ -1,4 +1,24 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# iptvstream.sh can be used by the VDR iptv plug-in to transcode external
|
||||
# sources
|
||||
#
|
||||
# (C) 2007 Rolf Ahrenberg, Antti Sepp<70>l<EFBFBD>
|
||||
#
|
||||
# iptvstream.sh 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 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This package 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 this package; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
|
||||
# MA 02110-1301, USA.
|
||||
|
||||
if [ $# -ne 2 ]; then
|
||||
logger "$0: error: Invalid parameter count '$#' $*"
|
||||
@@ -17,7 +37,7 @@ ABITRATE=320
|
||||
|
||||
# There is a way to specify multiple URLs in the same script. The selection is
|
||||
# then controlled by the extra parameter passed by IPTV plugin to the script
|
||||
case $PARAMETER in
|
||||
case ${PARAMETER} in
|
||||
1)
|
||||
URL=""
|
||||
;;
|
||||
@@ -42,5 +62,12 @@ let VPID=${PARAMETER}+1
|
||||
let APID=${PARAMETER}+2
|
||||
let SPID=${PARAMETER}+3
|
||||
|
||||
# Use 'exec' for capturing program pid for further management in IPTV plugin
|
||||
exec vlc "${URL}" --sout "#transcode{vcodec=mp2v,acodec=mpga,vb=${VBITRATE},ab=${ABITRATE}}:standard{access=udp,mux=ts{pid-video=${VPID},pid-audio=${APID},pid-spu=${SPID}},dst=127.0.0.1:${PORT}}" --intf dummy
|
||||
# Capture VLC pid for further management in IPTV plugin
|
||||
vlc "${URL}" --sout "#transcode{vcodec=mp2v,acodec=mpga,vb=${VBITRATE},ab=${ABITRATE}}:standard{access=udp,mux=ts{pid-video=${VPID},pid-audio=${APID},pid-spu=${SPID}},dst=127.0.0.1:${PORT}}" --intf dummy &
|
||||
|
||||
PID=${!}
|
||||
|
||||
trap 'kill -INT ${PID} 2> /dev/null' INT EXIT QUIT TERM
|
||||
|
||||
# Waiting for the given PID to terminate
|
||||
wait ${PID}
|
||||
|
||||
100
iptv/vlc2iptv
Executable file
100
iptv/vlc2iptv
Executable file
@@ -0,0 +1,100 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# vlc2iptv is used by the VDR iptv plug-in to transcode external sources
|
||||
#
|
||||
# (C) 2007 Rolf Ahrenberg, Antti Sepp<70>l<EFBFBD>
|
||||
# (C) 2007 Tobias Grimm
|
||||
#
|
||||
# vlc2iptv 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 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This package 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 this package; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
|
||||
# MA 02110-1301, USA.
|
||||
#
|
||||
|
||||
#
|
||||
# <Global Settings>
|
||||
#
|
||||
|
||||
CHANNELS_CONF=/var/lib/vdr/channels.conf
|
||||
CHANNEL_SETTINGS_DIR=/etc/vdr/plugins/iptv/vlcinput/
|
||||
VIDEO_BITRATE=2400
|
||||
AUDIO_BITRATE=320
|
||||
|
||||
#
|
||||
# </Global Settings>
|
||||
#
|
||||
|
||||
exit_with_error()
|
||||
{
|
||||
logger "vlc2iptv: error: $*"
|
||||
exit 1;
|
||||
}
|
||||
|
||||
read_arguments()
|
||||
{
|
||||
[ $# -ne 2 ] && exit_with_error "Invalid parameter count '$#' $*"
|
||||
PARAMETER=$1
|
||||
PORT=$2
|
||||
}
|
||||
|
||||
lookup_channel_and_pids()
|
||||
{
|
||||
[ ! -e "$CHANNELS_CONF" ] && \
|
||||
exit_with_error "channels.conf not found ($CHANNELS_CONF)"
|
||||
|
||||
local CHANNEL_RECORD=`grep ":IPTV|EXT|vlc2iptv|$PARAMETER:" $CHANNELS_CONF`
|
||||
[ -z "$CHANNEL_RECORD" ] && \
|
||||
exit_with_error "no iptv channel with parameter $PARAMETER found"
|
||||
|
||||
CHANNEL_NAME=`echo $CHANNEL_RECORD | awk "-F[;,:]" '{print $1}'`
|
||||
VPID=`echo $CHANNEL_RECORD | awk -F: '{print $6}'`
|
||||
APID=`echo $CHANNEL_RECORD | awk -F: '{print $7}'`
|
||||
SPID=0
|
||||
}
|
||||
|
||||
load_channel_configuration()
|
||||
{
|
||||
local CHANNEL_SETTINGS_FILE="$CHANNEL_SETTINGS_DIR/$CHANNEL_NAME.conf"
|
||||
|
||||
[ ! -e $CHANNEL_SETTINGS_FILE ] && \
|
||||
exit_with_error "No vlc input configuration for channel '$CHANNEL_NAME'"
|
||||
. $CHANNEL_SETTINGS_FILE
|
||||
|
||||
[ -z "$URL" ] && \
|
||||
exit_with_error "No URL specified for channel '$CHANNEL_NAME'"
|
||||
}
|
||||
|
||||
read_arguments $*
|
||||
lookup_channel_and_pids
|
||||
load_channel_configuration
|
||||
|
||||
#
|
||||
# Start VLC
|
||||
#
|
||||
|
||||
if [ -n "$WIDTH" -a -n "$HEIGHT" ] ; then
|
||||
RESIZE_OPTIONS=",width=${WIDTH},height=${HEIGHT}"
|
||||
else
|
||||
RESIZE_OPTIONS=""
|
||||
fi
|
||||
|
||||
vlc "${URL}" \
|
||||
--sout "#transcode{vcodec=mp2v$RESIZE_OPTIONS,acodec=mpga,vb=${VIDEO_BITRATE},ab=${AUDIO_BITRATE}}:standard{access=udp,mux=ts{pid-video=${VPID},pid-audio=${APID},pid-spu=${SPID}},dst=127.0.0.1:${PORT}}" \
|
||||
--intf dummy &
|
||||
|
||||
PID=${!}
|
||||
|
||||
trap 'kill -INT ${PID} 2> /dev/null' INT EXIT QUIT TERM
|
||||
|
||||
# Waiting for the given PID to terminate
|
||||
wait ${PID}
|
||||
@@ -1,277 +0,0 @@
|
||||
diff -Nru vdr-1.5.10-vanilla/channels.c vdr-1.5.10-pluginparam/channels.c
|
||||
--- vdr-1.5.10-vanilla/channels.c 2007-10-14 18:21:57.000000000 +0300
|
||||
+++ vdr-1.5.10-pluginparam/channels.c 2007-10-27 01:53:27.000000000 +0300
|
||||
@@ -166,6 +166,7 @@
|
||||
shortName = strdup("");
|
||||
provider = strdup("");
|
||||
portalName = strdup("");
|
||||
+ pluginParam = strdup("");
|
||||
memset(&__BeginData__, 0, (char *)&__EndData__ - (char *)&__BeginData__);
|
||||
inversion = INVERSION_AUTO;
|
||||
bandwidth = BANDWIDTH_AUTO;
|
||||
@@ -187,6 +188,7 @@
|
||||
shortName = NULL;
|
||||
provider = NULL;
|
||||
portalName = NULL;
|
||||
+ pluginParam = NULL;
|
||||
schedule = NULL;
|
||||
linkChannels = NULL;
|
||||
refChannel = NULL;
|
||||
@@ -215,6 +217,7 @@
|
||||
free(shortName);
|
||||
free(provider);
|
||||
free(portalName);
|
||||
+ free(pluginParam);
|
||||
}
|
||||
|
||||
cChannel& cChannel::operator= (const cChannel &Channel)
|
||||
@@ -223,6 +226,7 @@
|
||||
shortName = strcpyrealloc(shortName, Channel.shortName);
|
||||
provider = strcpyrealloc(provider, Channel.provider);
|
||||
portalName = strcpyrealloc(portalName, Channel.portalName);
|
||||
+ pluginParam = strcpyrealloc(pluginParam, Channel.pluginParam);
|
||||
memcpy(&__BeginData__, &Channel.__BeginData__, (char *)&Channel.__EndData__ - (char *)&Channel.__BeginData__);
|
||||
return *this;
|
||||
}
|
||||
@@ -280,9 +284,26 @@
|
||||
transmission = Channel->transmission;
|
||||
guard = Channel->guard;
|
||||
hierarchy = Channel->hierarchy;
|
||||
+ if (IsPlug()) pluginParam = strcpyrealloc(pluginParam, Channel->pluginParam);
|
||||
}
|
||||
}
|
||||
|
||||
+bool cChannel::SetPlugTransponderData(int Source, int Frequency, const char *PluginParam)
|
||||
+{
|
||||
+ if (source != Source || frequency != Frequency || (strcmp(pluginParam, PluginParam) != 0)) {
|
||||
+ if (Number()) {
|
||||
+ dsyslog("changing transponder data of channel %d from %s:%d:%s to %s:%d:%s", Number(), *cSource::ToString(source), frequency, pluginParam, *cSource::ToString(Source), Frequency, PluginParam);
|
||||
+ modification |= CHANNELMOD_TRANSP;
|
||||
+ Channels.SetModified();
|
||||
+ }
|
||||
+ source = Source;
|
||||
+ frequency = Frequency;
|
||||
+ pluginParam = strcpyrealloc(pluginParam, PluginParam);
|
||||
+ schedule = NULL;
|
||||
+ }
|
||||
+ return true;
|
||||
+}
|
||||
+
|
||||
bool cChannel::SetSatTransponderData(int Source, int Frequency, char Polarization, int Srate, int CoderateH)
|
||||
{
|
||||
// Workarounds for broadcaster stupidity:
|
||||
@@ -407,6 +428,18 @@
|
||||
}
|
||||
}
|
||||
|
||||
+void cChannel::SetPluginParam(const char *PluginParam)
|
||||
+{
|
||||
+ if (!isempty(PluginParam) && strcmp(pluginParam, PluginParam) != 0) {
|
||||
+ if (Number()) {
|
||||
+ dsyslog("changing plugin parameters of channel %d from '%s' to '%s'", Number(), pluginParam, PluginParam);
|
||||
+ modification |= CHANNELMOD_TRANSP;
|
||||
+ Channels.SetModified();
|
||||
+ }
|
||||
+ pluginParam = strcpyrealloc(pluginParam, PluginParam);
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
#define STRDIFF 0x01
|
||||
#define VALDIFF 0x02
|
||||
|
||||
@@ -593,7 +626,7 @@
|
||||
if (isdigit(type))
|
||||
type = 'S';
|
||||
#define ST(s) if (strchr(s, type))
|
||||
- char buffer[64];
|
||||
+ char buffer[256];
|
||||
char *q = buffer;
|
||||
*q = 0;
|
||||
ST(" S ") q += sprintf(q, "%c", polarization);
|
||||
@@ -605,6 +638,7 @@
|
||||
ST(" T") q += PrintParameter(q, 'T', MapToUser(transmission, TransmissionValues));
|
||||
ST(" T") q += PrintParameter(q, 'G', MapToUser(guard, GuardValues));
|
||||
ST(" T") q += PrintParameter(q, 'Y', MapToUser(hierarchy, HierarchyValues));
|
||||
+ ST("P ") snprintf(buffer, sizeof(buffer), "%s", pluginParam);
|
||||
return buffer;
|
||||
}
|
||||
|
||||
@@ -626,7 +660,7 @@
|
||||
|
||||
bool cChannel::StringToParameters(const char *s)
|
||||
{
|
||||
- while (s && *s) {
|
||||
+ while (s && *s && !IsPlug()) {
|
||||
switch (toupper(*s)) {
|
||||
case 'B': s = ParseParameter(s, bandwidth, BandwidthValues); break;
|
||||
case 'C': s = ParseParameter(s, coderateH, CoderateValues); break;
|
||||
@@ -736,7 +770,7 @@
|
||||
dpids[0] = 0;
|
||||
ok = false;
|
||||
if (parambuf && sourcebuf && vpidbuf && apidbuf) {
|
||||
- ok = StringToParameters(parambuf) && (source = cSource::FromString(sourcebuf)) >= 0;
|
||||
+ ok = ((source = cSource::FromString(sourcebuf)) >= 0) && StringToParameters(parambuf);
|
||||
|
||||
char *p = strchr(vpidbuf, '+');
|
||||
if (p)
|
||||
@@ -827,6 +861,7 @@
|
||||
shortName = strcpyrealloc(shortName, p);
|
||||
}
|
||||
name = strcpyrealloc(name, namebuf);
|
||||
+ if (IsPlug()) pluginParam = strcpyrealloc(pluginParam, parambuf);
|
||||
|
||||
free(parambuf);
|
||||
free(sourcebuf);
|
||||
diff -Nru vdr-1.5.10-vanilla/channels.h vdr-1.5.10-pluginparam/channels.h
|
||||
--- vdr-1.5.10-vanilla/channels.h 2007-10-14 18:21:57.000000000 +0300
|
||||
+++ vdr-1.5.10-pluginparam/channels.h 2007-10-27 01:53:27.000000000 +0300
|
||||
@@ -114,6 +114,7 @@
|
||||
char *shortName;
|
||||
char *provider;
|
||||
char *portalName;
|
||||
+ char *pluginParam;
|
||||
int __BeginData__;
|
||||
int frequency; // MHz
|
||||
int source;
|
||||
@@ -165,6 +166,7 @@
|
||||
int Frequency(void) const { return frequency; } ///< Returns the actual frequency, as given in 'channels.conf'
|
||||
int Transponder(void) const; ///< Returns the transponder frequency in MHz, plus the polarization in case of sat
|
||||
static int Transponder(int Frequency, char Polarization); ///< builds the transponder from the given Frequency and Polarization
|
||||
+ const char *PluginParam(void) const { return pluginParam; }
|
||||
int Source(void) const { return source; }
|
||||
int Srate(void) const { return srate; }
|
||||
int Vpid(void) const { return vpid; }
|
||||
@@ -199,6 +201,7 @@
|
||||
int Hierarchy(void) const { return hierarchy; }
|
||||
const cLinkChannels* LinkChannels(void) const { return linkChannels; }
|
||||
const cChannel *RefChannel(void) const { return refChannel; }
|
||||
+ bool IsPlug(void) const { return cSource::IsPlug(source); }
|
||||
bool IsCable(void) const { return cSource::IsCable(source); }
|
||||
bool IsSat(void) const { return cSource::IsSat(source); }
|
||||
bool IsTerr(void) const { return cSource::IsTerr(source); }
|
||||
@@ -206,12 +209,14 @@
|
||||
bool HasTimer(void) const;
|
||||
int Modification(int Mask = CHANNELMOD_ALL);
|
||||
void CopyTransponderData(const cChannel *Channel);
|
||||
+ bool SetPlugTransponderData(int Source, int Frequency, const char *PluginParam);
|
||||
bool SetSatTransponderData(int Source, int Frequency, char Polarization, int Srate, int CoderateH);
|
||||
bool SetCableTransponderData(int Source, int Frequency, int Modulation, int Srate, int CoderateH);
|
||||
bool SetTerrTransponderData(int Source, int Frequency, int Bandwidth, int Modulation, int Hierarchy, int CodeRateH, int CodeRateL, int Guard, int Transmission);
|
||||
void SetId(int Nid, int Tid, int Sid, int Rid = 0);
|
||||
void SetName(const char *Name, const char *ShortName, const char *Provider);
|
||||
void SetPortalName(const char *PortalName);
|
||||
+ void SetPluginParam(const char *PluginParam);
|
||||
void SetPids(int Vpid, int Ppid, int *Apids, char ALangs[][MAXLANGCODE2], int *Dpids, char DLangs[][MAXLANGCODE2], int *Spids, char SLangs[][MAXLANGCODE2], int Tpid);
|
||||
void SetCaIds(const int *CaIds); // list must be zero-terminated
|
||||
void SetCaDescriptors(int Level);
|
||||
diff -Nru vdr-1.5.10-vanilla/config.h vdr-1.5.10-pluginparam/config.h
|
||||
--- vdr-1.5.10-vanilla/config.h 2007-10-14 18:21:57.000000000 +0300
|
||||
+++ vdr-1.5.10-pluginparam/config.h 2007-10-27 01:53:59.000000000 +0300
|
||||
@@ -30,6 +30,8 @@
|
||||
#define APIVERSION "1.5.10"
|
||||
#define APIVERSNUM 10510 // Version * 10000 + Major * 100 + Minor
|
||||
|
||||
+#define PLUGINPARAMPATCHVERSNUM 1
|
||||
+
|
||||
// When loading plugins, VDR searches them by their APIVERSION, which
|
||||
// may be smaller than VDRVERSION in case there have been no changes to
|
||||
// VDR header files since the last APIVERSION. This allows compiled
|
||||
diff -Nru vdr-1.5.10-vanilla/menu.c vdr-1.5.10-pluginparam/menu.c
|
||||
--- vdr-1.5.10-vanilla/menu.c 2007-10-14 18:21:57.000000000 +0300
|
||||
+++ vdr-1.5.10-pluginparam/menu.c 2007-10-27 01:53:27.000000000 +0300
|
||||
@@ -219,6 +219,7 @@
|
||||
cChannel *channel;
|
||||
cChannel data;
|
||||
char name[256];
|
||||
+ char pluginParam[256];
|
||||
void Setup(void);
|
||||
public:
|
||||
cMenuEditChannel(cChannel *Channel, bool New = false);
|
||||
@@ -251,6 +252,7 @@
|
||||
|
||||
// Parameters for all types of sources:
|
||||
strn0cpy(name, data.name, sizeof(name));
|
||||
+ strn0cpy(pluginParam, data.pluginParam, sizeof(pluginParam));
|
||||
Add(new cMenuEditStrItem( tr("Name"), name, sizeof(name), tr(FileNameChars)));
|
||||
Add(new cMenuEditSrcItem( tr("Source"), &data.source));
|
||||
Add(new cMenuEditIntItem( tr("Frequency"), &data.frequency));
|
||||
@@ -281,6 +283,7 @@
|
||||
ST(" T") Add(new cMenuEditMapItem( tr("Transmission"), &data.transmission, TransmissionValues));
|
||||
ST(" T") Add(new cMenuEditMapItem( tr("Guard"), &data.guard, GuardValues));
|
||||
ST(" T") Add(new cMenuEditMapItem( tr("Hierarchy"), &data.hierarchy, HierarchyValues, tr("none")));
|
||||
+ ST("P ") Add(new cMenuEditStrItem( tr("Parameters"), pluginParam, sizeof(pluginParam), tr(FileNameChars)));
|
||||
|
||||
SetCurrent(Get(current));
|
||||
Display();
|
||||
@@ -295,6 +298,7 @@
|
||||
if (Key == kOk) {
|
||||
if (Channels.HasUniqueChannelID(&data, channel)) {
|
||||
data.name = strcpyrealloc(data.name, name);
|
||||
+ data.pluginParam = strcpyrealloc(data.pluginParam, pluginParam);
|
||||
if (channel) {
|
||||
*channel = data;
|
||||
isyslog("edited channel %d %s", channel->Number(), *data.ToText());
|
||||
diff -Nru vdr-1.5.10-vanilla/po/fi_FI.po vdr-1.5.10-pluginparam/po/fi_FI.po
|
||||
--- vdr-1.5.10-vanilla/po/fi_FI.po 2007-10-14 18:21:57.000000000 +0300
|
||||
+++ vdr-1.5.10-pluginparam/po/fi_FI.po 2007-10-27 01:53:27.000000000 +0300
|
||||
@@ -998,3 +998,6 @@
|
||||
#, c-format
|
||||
msgid "VDR will shut down in %s minutes"
|
||||
msgstr "VDR sammuu %s minuutin kuluttua"
|
||||
+
|
||||
+msgid "Parameters"
|
||||
+msgstr "Parametrit"
|
||||
diff -Nru vdr-1.5.10-vanilla/sources.c vdr-1.5.10-pluginparam/sources.c
|
||||
--- vdr-1.5.10-vanilla/sources.c 2007-10-14 18:21:57.000000000 +0300
|
||||
+++ vdr-1.5.10-pluginparam/sources.c 2007-10-27 01:53:27.000000000 +0300
|
||||
@@ -37,6 +37,7 @@
|
||||
char buffer[16];
|
||||
char *q = buffer;
|
||||
switch (Code & st_Mask) {
|
||||
+ case stPlug: *q++ = 'P'; break;
|
||||
case stCable: *q++ = 'C'; break;
|
||||
case stSat: *q++ = 'S';
|
||||
{
|
||||
@@ -56,6 +57,7 @@
|
||||
{
|
||||
int type = stNone;
|
||||
switch (toupper(*s)) {
|
||||
+ case 'P': type = stPlug; break;
|
||||
case 'C': type = stCable; break;
|
||||
case 'S': type = stSat; break;
|
||||
case 'T': type = stTerr; break;
|
||||
diff -Nru vdr-1.5.10-vanilla/sources.conf vdr-1.5.10-pluginparam/sources.conf
|
||||
--- vdr-1.5.10-vanilla/sources.conf 2007-10-14 18:21:57.000000000 +0300
|
||||
+++ vdr-1.5.10-pluginparam/sources.conf 2007-10-27 01:53:27.000000000 +0300
|
||||
@@ -188,3 +188,7 @@
|
||||
# Terrestrial
|
||||
|
||||
T Terrestrial
|
||||
+
|
||||
+# Plugin
|
||||
+
|
||||
+P Plugin
|
||||
diff -Nru vdr-1.5.10-vanilla/sources.h vdr-1.5.10-pluginparam/sources.h
|
||||
--- vdr-1.5.10-vanilla/sources.h 2007-10-14 18:21:57.000000000 +0300
|
||||
+++ vdr-1.5.10-pluginparam/sources.h 2007-10-27 01:53:27.000000000 +0300
|
||||
@@ -16,10 +16,11 @@
|
||||
public:
|
||||
enum eSourceType {
|
||||
stNone = 0x0000,
|
||||
+ stPlug = 0x2000,
|
||||
stCable = 0x4000,
|
||||
stSat = 0x8000,
|
||||
stTerr = 0xC000,
|
||||
- st_Mask = 0xC000,
|
||||
+ st_Mask = 0xE000,
|
||||
st_Neg = 0x0800,
|
||||
st_Pos = 0x07FF,
|
||||
};
|
||||
@@ -35,6 +36,7 @@
|
||||
static cString ToString(int Code);
|
||||
static int FromString(const char *s);
|
||||
static int FromData(eSourceType SourceType, int Position = 0, bool East = false);
|
||||
+ static bool IsPlug(int Code) { return (Code & st_Mask) == stPlug; }
|
||||
static bool IsCable(int Code) { return (Code & st_Mask) == stCable; }
|
||||
static bool IsSat(int Code) { return (Code & st_Mask) == stSat; }
|
||||
static bool IsTerr(int Code) { return (Code & st_Mask) == stTerr; }
|
||||
@@ -1,6 +1,6 @@
|
||||
diff -Nru vdr-1.5.11-vanilla/channels.c vdr-1.5.11-pluginparam/channels.c
|
||||
--- vdr-1.5.11-vanilla/channels.c 2007-11-04 14:14:22.000000000 +0200
|
||||
+++ vdr-1.5.11-pluginparam/channels.c 2007-11-04 14:57:08.000000000 +0200
|
||||
diff -Nru vdr-1.5.13-vanilla/channels.c vdr-1.5.13-pluginparam/channels.c
|
||||
--- vdr-1.5.13-vanilla/channels.c 2008-01-13 17:31:25.000000000 +0200
|
||||
+++ vdr-1.5.13-pluginparam/channels.c 2008-01-20 02:00:08.000000000 +0200
|
||||
@@ -166,6 +166,7 @@
|
||||
shortName = strdup("");
|
||||
provider = strdup("");
|
||||
@@ -122,9 +122,9 @@ diff -Nru vdr-1.5.11-vanilla/channels.c vdr-1.5.11-pluginparam/channels.c
|
||||
|
||||
free(parambuf);
|
||||
free(sourcebuf);
|
||||
diff -Nru vdr-1.5.11-vanilla/channels.h vdr-1.5.11-pluginparam/channels.h
|
||||
--- vdr-1.5.11-vanilla/channels.h 2007-11-04 14:14:22.000000000 +0200
|
||||
+++ vdr-1.5.11-pluginparam/channels.h 2007-11-04 14:57:08.000000000 +0200
|
||||
diff -Nru vdr-1.5.13-vanilla/channels.h vdr-1.5.13-pluginparam/channels.h
|
||||
--- vdr-1.5.13-vanilla/channels.h 2008-01-13 17:31:25.000000000 +0200
|
||||
+++ vdr-1.5.13-pluginparam/channels.h 2008-01-20 02:00:08.000000000 +0200
|
||||
@@ -114,6 +114,7 @@
|
||||
char *shortName;
|
||||
char *provider;
|
||||
@@ -164,21 +164,21 @@ diff -Nru vdr-1.5.11-vanilla/channels.h vdr-1.5.11-pluginparam/channels.h
|
||||
void SetPids(int Vpid, int Ppid, int *Apids, char ALangs[][MAXLANGCODE2], int *Dpids, char DLangs[][MAXLANGCODE2], int *Spids, char SLangs[][MAXLANGCODE2], int Tpid);
|
||||
void SetCaIds(const int *CaIds); // list must be zero-terminated
|
||||
void SetCaDescriptors(int Level);
|
||||
diff -Nru vdr-1.5.11-vanilla/config.h vdr-1.5.11-pluginparam/config.h
|
||||
--- vdr-1.5.11-vanilla/config.h 2007-11-04 14:14:22.000000000 +0200
|
||||
+++ vdr-1.5.11-pluginparam/config.h 2007-11-04 14:57:08.000000000 +0200
|
||||
diff -Nru vdr-1.5.13-vanilla/config.h vdr-1.5.13-pluginparam/config.h
|
||||
--- vdr-1.5.13-vanilla/config.h 2008-01-13 17:31:25.000000000 +0200
|
||||
+++ vdr-1.5.13-pluginparam/config.h 2008-01-20 02:00:08.000000000 +0200
|
||||
@@ -30,6 +30,8 @@
|
||||
#define APIVERSION "1.5.11"
|
||||
#define APIVERSNUM 10511 // Version * 10000 + Major * 100 + Minor
|
||||
#define APIVERSION "1.5.13"
|
||||
#define APIVERSNUM 10513 // Version * 10000 + Major * 100 + Minor
|
||||
|
||||
+#define PLUGINPARAMPATCHVERSNUM 1
|
||||
+
|
||||
// When loading plugins, VDR searches them by their APIVERSION, which
|
||||
// may be smaller than VDRVERSION in case there have been no changes to
|
||||
// VDR header files since the last APIVERSION. This allows compiled
|
||||
diff -Nru vdr-1.5.11-vanilla/menu.c vdr-1.5.11-pluginparam/menu.c
|
||||
--- vdr-1.5.11-vanilla/menu.c 2007-11-04 14:14:22.000000000 +0200
|
||||
+++ vdr-1.5.11-pluginparam/menu.c 2007-11-04 14:58:03.000000000 +0200
|
||||
diff -Nru vdr-1.5.13-vanilla/menu.c vdr-1.5.13-pluginparam/menu.c
|
||||
--- vdr-1.5.13-vanilla/menu.c 2008-01-13 17:31:25.000000000 +0200
|
||||
+++ vdr-1.5.13-pluginparam/menu.c 2008-01-20 02:00:08.000000000 +0200
|
||||
@@ -219,6 +219,7 @@
|
||||
cChannel *channel;
|
||||
cChannel data;
|
||||
@@ -211,19 +211,19 @@ diff -Nru vdr-1.5.11-vanilla/menu.c vdr-1.5.11-pluginparam/menu.c
|
||||
if (channel) {
|
||||
*channel = data;
|
||||
isyslog("edited channel %d %s", channel->Number(), *data.ToText());
|
||||
diff -Nru vdr-1.5.11-vanilla/po/fi_FI.po vdr-1.5.11-pluginparam/po/fi_FI.po
|
||||
--- vdr-1.5.11-vanilla/po/fi_FI.po 2007-11-04 14:14:23.000000000 +0200
|
||||
+++ vdr-1.5.11-pluginparam/po/fi_FI.po 2007-11-04 14:57:08.000000000 +0200
|
||||
@@ -998,3 +998,6 @@
|
||||
diff -Nru vdr-1.5.13-vanilla/po/fi_FI.po vdr-1.5.13-pluginparam/po/fi_FI.po
|
||||
--- vdr-1.5.13-vanilla/po/fi_FI.po 2008-01-13 17:31:25.000000000 +0200
|
||||
+++ vdr-1.5.13-pluginparam/po/fi_FI.po 2008-01-20 02:00:08.000000000 +0200
|
||||
@@ -1001,3 +1001,6 @@
|
||||
#, c-format
|
||||
msgid "VDR will shut down in %s minutes"
|
||||
msgstr "VDR sammuu %s minuutin kuluttua"
|
||||
+
|
||||
+msgid "Parameters"
|
||||
+msgstr "Parametrit"
|
||||
diff -Nru vdr-1.5.11-vanilla/sources.c vdr-1.5.11-pluginparam/sources.c
|
||||
--- vdr-1.5.11-vanilla/sources.c 2007-11-04 14:14:22.000000000 +0200
|
||||
+++ vdr-1.5.11-pluginparam/sources.c 2007-11-04 14:57:08.000000000 +0200
|
||||
diff -Nru vdr-1.5.13-vanilla/sources.c vdr-1.5.13-pluginparam/sources.c
|
||||
--- vdr-1.5.13-vanilla/sources.c 2008-01-13 17:31:25.000000000 +0200
|
||||
+++ vdr-1.5.13-pluginparam/sources.c 2008-01-20 02:00:08.000000000 +0200
|
||||
@@ -37,6 +37,7 @@
|
||||
char buffer[16];
|
||||
char *q = buffer;
|
||||
@@ -240,9 +240,9 @@ diff -Nru vdr-1.5.11-vanilla/sources.c vdr-1.5.11-pluginparam/sources.c
|
||||
case 'C': type = stCable; break;
|
||||
case 'S': type = stSat; break;
|
||||
case 'T': type = stTerr; break;
|
||||
diff -Nru vdr-1.5.11-vanilla/sources.conf vdr-1.5.11-pluginparam/sources.conf
|
||||
--- vdr-1.5.11-vanilla/sources.conf 2007-11-04 14:14:22.000000000 +0200
|
||||
+++ vdr-1.5.11-pluginparam/sources.conf 2007-11-04 14:57:08.000000000 +0200
|
||||
diff -Nru vdr-1.5.13-vanilla/sources.conf vdr-1.5.13-pluginparam/sources.conf
|
||||
--- vdr-1.5.13-vanilla/sources.conf 2008-01-13 17:31:25.000000000 +0200
|
||||
+++ vdr-1.5.13-pluginparam/sources.conf 2008-01-20 02:00:08.000000000 +0200
|
||||
@@ -188,3 +188,7 @@
|
||||
# Terrestrial
|
||||
|
||||
@@ -251,9 +251,9 @@ diff -Nru vdr-1.5.11-vanilla/sources.conf vdr-1.5.11-pluginparam/sources.conf
|
||||
+# Plugin
|
||||
+
|
||||
+P Plugin
|
||||
diff -Nru vdr-1.5.11-vanilla/sources.h vdr-1.5.11-pluginparam/sources.h
|
||||
--- vdr-1.5.11-vanilla/sources.h 2007-11-04 14:14:23.000000000 +0200
|
||||
+++ vdr-1.5.11-pluginparam/sources.h 2007-11-04 14:57:08.000000000 +0200
|
||||
diff -Nru vdr-1.5.13-vanilla/sources.h vdr-1.5.13-pluginparam/sources.h
|
||||
--- vdr-1.5.13-vanilla/sources.h 2008-01-13 17:31:25.000000000 +0200
|
||||
+++ vdr-1.5.13-pluginparam/sources.h 2008-01-20 02:00:08.000000000 +0200
|
||||
@@ -16,10 +16,11 @@
|
||||
public:
|
||||
enum eSourceType {
|
||||
50
po/de_DE.po
50
po/de_DE.po
@@ -1,13 +1,13 @@
|
||||
# German translations for iptv package.
|
||||
# Copyright (C) 2007 THE iptv'S COPYRIGHT HOLDER
|
||||
# VDR plugin language source file.
|
||||
# Copyright (C) 2007 Rolf Ahrenberg & Antti Seppala
|
||||
# This file is distributed under the same license as the iptv package.
|
||||
# Tobias <vdr@e-tobi.net>, 2007.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: iptv 0.0.2.x\n"
|
||||
"Project-Id-Version: iptv 0.0.6\n"
|
||||
"Report-Msgid-Bugs-To: Rolf Ahrenberg\n"
|
||||
"POT-Creation-Date: 2007-10-27 12:49+0200\n"
|
||||
"POT-Creation-Date: 2008-01-20 16:10+0200\n"
|
||||
"PO-Revision-Date: 2007-10-29 21:19+0100\n"
|
||||
"Last-Translator: Tobias Grimm <tg@e-tobi.net>\n"
|
||||
"Language-Team: German\n"
|
||||
@@ -106,22 +106,64 @@ msgstr "IPTV Informationen nicht verfügbar!"
|
||||
msgid "TS buffer size [MB]"
|
||||
msgstr "TS Puffergröße [MB]"
|
||||
|
||||
msgid ""
|
||||
"Define a ringbuffer size for transport streams in megabytes.\n"
|
||||
"\n"
|
||||
"Smaller sizes help memory consumption, but are more prone to buffer overflows."
|
||||
msgstr ""
|
||||
|
||||
msgid "TS buffer prefill ratio [%]"
|
||||
msgstr "TS Puffer-Preload [%]"
|
||||
|
||||
msgid ""
|
||||
"Define a prefill ratio of the ringbuffer for transport streams before data is transferred to VDR.\n"
|
||||
"\n"
|
||||
"This is useful if streaming media over a slow or unreliable connection."
|
||||
msgstr ""
|
||||
|
||||
msgid "EXT protocol base port"
|
||||
msgstr "EXT Protokoll Basisport"
|
||||
|
||||
msgid ""
|
||||
"Define a base port used by EXT protocol.\n"
|
||||
"\n"
|
||||
"The port range is defined by the number of IPTV devices. This setting sets the port which is listened for connections from external applications when using the EXT protocol."
|
||||
msgstr ""
|
||||
|
||||
msgid "Use section filtering"
|
||||
msgstr "Benutze Abschnittsfilterung"
|
||||
|
||||
msgid ""
|
||||
"Define whether the section filtering shall be used.\n"
|
||||
"\n"
|
||||
"Section filtering means that IPTV plugin tries to parse and provide VDR with secondary data about the currently active stream. VDR can then use this data for providing various functionalities such as automatic pid change detection and EPG etc.\n"
|
||||
"Enabling this feature does not affect streams that do not contain section data."
|
||||
msgstr ""
|
||||
|
||||
msgid "Scan Sid automatically"
|
||||
msgstr "Scanne SID automatisch"
|
||||
|
||||
msgid ""
|
||||
"Define whether the service id shall be scanned automatically.\n"
|
||||
"\n"
|
||||
"Requires the section filtering. Automatic Sid scanning helps VDR to detect changed pids of streams."
|
||||
msgstr ""
|
||||
|
||||
msgid "Disable filters"
|
||||
msgstr "Deaktiviere Filter"
|
||||
|
||||
msgid ""
|
||||
"Define number of section filters to be disabled.\n"
|
||||
"\n"
|
||||
"Certain section filters might cause some unwanted behaviour to VDR such as time being falsely synchronized. By black-listing the filters here useful section data can be left intact for VDR to process."
|
||||
msgstr ""
|
||||
|
||||
#. TRANSLATORS: note the singular!
|
||||
msgid "Disable filter"
|
||||
msgstr "Deaktiviere Filter"
|
||||
|
||||
msgid "Define an ill-behaving filter to be blacklisted."
|
||||
msgstr ""
|
||||
|
||||
msgid "Help"
|
||||
msgstr "Hilfe"
|
||||
|
||||
70
po/fi_FI.po
70
po/fi_FI.po
@@ -1,13 +1,13 @@
|
||||
# VDR plugin language source file.
|
||||
# Copyright (C) 2007 Klaus Schmidinger <kls@cadsoft.de>
|
||||
# This file is distributed under the same license as the VDR package.
|
||||
# Copyright (C) 2007 Rolf Ahrenberg & Antti Seppala
|
||||
# This file is distributed under the same license as the iptv package.
|
||||
# Rolf Ahrenberg
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: VDR 1.5.7\n"
|
||||
"Project-Id-Version: iptv 0.0.6\n"
|
||||
"Report-Msgid-Bugs-To: Rolf Ahrenberg\n"
|
||||
"POT-Creation-Date: 2007-10-20 19:43+0300\n"
|
||||
"POT-Creation-Date: 2008-01-20 15:37+0200\n"
|
||||
"PO-Revision-Date: 2007-08-12 23:22+0300\n"
|
||||
"Last-Translator: Rolf Ahrenberg\n"
|
||||
"Language-Team: <vdr@linuxtv.org>\n"
|
||||
@@ -105,21 +105,83 @@ msgstr "IPTV-tietoja ei saatavilla!"
|
||||
msgid "TS buffer size [MB]"
|
||||
msgstr "TS-puskurin koko [MB]"
|
||||
|
||||
msgid ""
|
||||
"Define a ringbuffer size for transport streams in megabytes.\n"
|
||||
"\n"
|
||||
"Smaller sizes help memory consumption, but are more prone to buffer overflows."
|
||||
msgstr ""
|
||||
"M<><4D>rit<69> rengaspuskurin koko TS-l<>hetteelle megatavuina.\n"
|
||||
"\n"
|
||||
"Pienempi rengaspuskuri v<>hent<6E><74> muistinkulutusta, mutta on virhealttiimpi puskurin ylivuodolle."
|
||||
|
||||
msgid "TS buffer prefill ratio [%]"
|
||||
msgstr "TS-puskurin esit<69>ytt<74>aste [%]"
|
||||
|
||||
msgid ""
|
||||
"Define a prefill ratio of the ringbuffer for transport streams before data is transferred to VDR.\n"
|
||||
"\n"
|
||||
"This is useful if streaming media over a slow or unreliable connection."
|
||||
msgstr ""
|
||||
"M<><4D>rittele TS-rengaspuskurin esit<69>ytt<74>aste, jonka j<>lkeen l<>hetett<74> aletaan siirt<72>m<EFBFBD><6D>n eteenp<6E>in VDR:lle.\n"
|
||||
"\n"
|
||||
"Puskurin esit<69>ytt<74> parantaa suoratoistoa hitailla ja ep<65>luotettavilla yhteyksill<6C>."
|
||||
|
||||
msgid "EXT protocol base port"
|
||||
msgstr "EXT-protokollan perusportti"
|
||||
|
||||
msgid ""
|
||||
"Define a base port used by EXT protocol.\n"
|
||||
"\n"
|
||||
"The port range is defined by the number of IPTV devices. This setting sets the port which is listened for connections from external applications when using the EXT protocol."
|
||||
msgstr ""
|
||||
"M<><4D>rittele EXT-protokollan k<>ytt<74>m<EFBFBD> perusportti.\n"
|
||||
"\n"
|
||||
"Porttiavaruuden koko m<><6D>r<EFBFBD>ytyy k<>ytettyjen IPTV-laitteiden mukaan. Laajennos lukee EXT-protokollan yhteydess<73> perusportista dataa, jota ulkoiset ohjelmistot tarjoavat."
|
||||
|
||||
msgid "Use section filtering"
|
||||
msgstr "K<>yt<79> sektioiden suodatusta"
|
||||
|
||||
msgid ""
|
||||
"Define whether the section filtering shall be used.\n"
|
||||
"\n"
|
||||
"Section filtering means that IPTV plugin tries to parse and provide VDR with secondary data about the currently active stream. VDR can then use this data for providing various functionalities such as automatic pid change detection and EPG etc.\n"
|
||||
"Enabling this feature does not affect streams that do not contain section data."
|
||||
msgstr ""
|
||||
"M<><4D>rittele suodatuksen k<>ytt<74> sektioille.\n"
|
||||
"\n"
|
||||
"IPTV-laajennos voi suodattaa l<>hetteest<73> VDR:lle tarjottavia sektioita, joita k<>ytet<65><74>n esim. ohjelmaoppaan ja ohjelmatunnisteiden (PID) p<>ivitt<74>miseen.\n"
|
||||
"Toiminto ei vaikuta l<>hetteeseen, jossa ei ole sektioita."
|
||||
|
||||
msgid "Scan Sid automatically"
|
||||
msgstr "Etsi palvelu-ID automaattisesti"
|
||||
|
||||
msgid ""
|
||||
"Define whether the service id shall be scanned automatically.\n"
|
||||
"\n"
|
||||
"Requires the section filtering. Automatic Sid scanning helps VDR to detect changed pids of streams."
|
||||
msgstr ""
|
||||
"M<><4D>rittele etsit<69><74>nk<6E> palvelutunniste (SID) automaattisesti.\n"
|
||||
"\n"
|
||||
"Asetus vaatii suodatuksen k<>ytt<74><74>noton sektioille. Automaattinen palvelutunnisteen (SID) etsint<6E> auttaa VDR:<3A><> havaitsemaan ohjelmatunnisteiden (PID) muutokset l<>hetteest<73>."
|
||||
|
||||
msgid "Disable filters"
|
||||
msgstr "Poista suodattimia k<>yt<79>st<73>"
|
||||
|
||||
msgid ""
|
||||
"Define number of section filters to be disabled.\n"
|
||||
"\n"
|
||||
"Certain section filters might cause some unwanted behaviour to VDR such as time being falsely synchronized. By black-listing the filters here useful section data can be left intact for VDR to process."
|
||||
msgstr ""
|
||||
"M<><4D>rittele k<>yt<79>st<73> poistettavien suodattimien lukum<75><6D>r<EFBFBD> sektioille.\n"
|
||||
"\n"
|
||||
"Tietyt sektiot saattavat aiheuttaa virheellist<73> toimintaa VDR:ss<73>, esimerkiksi asettavat v<><76>r<EFBFBD>n kellonajan, ja n<>iden poistaminen auttaa VDR:<3A><> toimimaan kunnolla j<>ljelle j<><6A>vien sektioiden kanssa."
|
||||
|
||||
#. TRANSLATORS: note the singular!
|
||||
msgid "Disable filter"
|
||||
msgstr "Poista suodatin k<>yt<79>st<73>"
|
||||
|
||||
msgid "Define an ill-behaving filter to be blacklisted."
|
||||
msgstr "M<><4D>rittele k<>yt<79>st<73> poistettava suodatin, joka lis<69>t<EFBFBD><74>n mustalle listalle."
|
||||
|
||||
msgid "Help"
|
||||
msgstr "Opaste"
|
||||
|
||||
169
po/fr_FR.po
Normal file
169
po/fr_FR.po
Normal file
@@ -0,0 +1,169 @@
|
||||
# French translations for iptv package.
|
||||
# Copyright (C) 2007 Rolf Ahrenberg & Antti Seppala
|
||||
# This file is distributed under the same license as the iptv package.
|
||||
# Bruno ROUSSEL <bruno.roussel@free.fr>, 2007.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: iptv 0.0.6\n"
|
||||
"Report-Msgid-Bugs-To: Rolf Ahrenberg\n"
|
||||
"POT-Creation-Date: 2008-01-20 16:10+0200\n"
|
||||
"PO-Revision-Date: 2007-11-07 20:18+0100\n"
|
||||
"Last-Translator: Bruno ROUSSEL <bruno.roussel@free.fr>\n"
|
||||
"Language-Team: French\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
msgid "PAT (0x00)"
|
||||
msgstr "PAT (0x00)"
|
||||
|
||||
msgid "NIT (0x40)"
|
||||
msgstr "NIT (0x40)"
|
||||
|
||||
msgid "SDT (0x42)"
|
||||
msgstr "SDT (0x42)"
|
||||
|
||||
msgid "EIT (0x4E/0x4F)"
|
||||
msgstr "EIT (0x4E/0x4F)"
|
||||
|
||||
msgid "EIT (0x5X)"
|
||||
msgstr "EIT (0x5X)"
|
||||
|
||||
msgid "EIT (0x6X)"
|
||||
msgstr "EIT (0x6X)"
|
||||
|
||||
msgid "TDT (0x70)"
|
||||
msgstr "TDT (0x70)"
|
||||
|
||||
msgid "Experience the IPTV"
|
||||
msgstr "L'expérience IPTV"
|
||||
|
||||
msgid "UDP"
|
||||
msgstr "UDP"
|
||||
|
||||
msgid "HTTP"
|
||||
msgstr "HTTP"
|
||||
|
||||
msgid "FILE"
|
||||
msgstr "FICHIER"
|
||||
|
||||
msgid "EXT"
|
||||
msgstr "EXT"
|
||||
|
||||
msgid "Protocol"
|
||||
msgstr "Protocole"
|
||||
|
||||
msgid "Delay (ms)"
|
||||
msgstr "Délai (ms)"
|
||||
|
||||
msgid "Script"
|
||||
msgstr "Script"
|
||||
|
||||
msgid "Parameter"
|
||||
msgstr "Paramètre"
|
||||
|
||||
msgid "Address"
|
||||
msgstr "Adresse"
|
||||
|
||||
msgid "Port"
|
||||
msgstr "Port"
|
||||
|
||||
msgid "Nid"
|
||||
msgstr "Nid"
|
||||
|
||||
msgid "Tid"
|
||||
msgstr "Tid"
|
||||
|
||||
msgid "Rid"
|
||||
msgstr "Rid"
|
||||
|
||||
msgid "Cannot find unique channel settings!"
|
||||
msgstr "Impossible de trouver un paramètre de chaîne unique !"
|
||||
|
||||
msgid "IPTV Channels"
|
||||
msgstr "Canal IPTV"
|
||||
|
||||
msgid "IPTV Information"
|
||||
msgstr "Information sur IPTV"
|
||||
|
||||
msgid "General"
|
||||
msgstr "Général"
|
||||
|
||||
msgid "Pids"
|
||||
msgstr "Pids"
|
||||
|
||||
msgid "Filters"
|
||||
msgstr "Filtres"
|
||||
|
||||
msgid "Bits/bytes"
|
||||
msgstr "Bits/Bytes"
|
||||
|
||||
msgid "IPTV information not available!"
|
||||
msgstr "Information sur IPTV non disponible !"
|
||||
|
||||
msgid "TS buffer size [MB]"
|
||||
msgstr "Taille du buffer TS [MB]"
|
||||
|
||||
msgid ""
|
||||
"Define a ringbuffer size for transport streams in megabytes.\n"
|
||||
"\n"
|
||||
"Smaller sizes help memory consumption, but are more prone to buffer overflows."
|
||||
msgstr ""
|
||||
|
||||
msgid "TS buffer prefill ratio [%]"
|
||||
msgstr "Taux du buffer de pré-remplissage TS [%]"
|
||||
|
||||
msgid ""
|
||||
"Define a prefill ratio of the ringbuffer for transport streams before data is transferred to VDR.\n"
|
||||
"\n"
|
||||
"This is useful if streaming media over a slow or unreliable connection."
|
||||
msgstr ""
|
||||
|
||||
msgid "EXT protocol base port"
|
||||
msgstr "Port de base du protocole EXT"
|
||||
|
||||
msgid ""
|
||||
"Define a base port used by EXT protocol.\n"
|
||||
"\n"
|
||||
"The port range is defined by the number of IPTV devices. This setting sets the port which is listened for connections from external applications when using the EXT protocol."
|
||||
msgstr ""
|
||||
|
||||
msgid "Use section filtering"
|
||||
msgstr "Utiliser le filtrage de section"
|
||||
|
||||
msgid ""
|
||||
"Define whether the section filtering shall be used.\n"
|
||||
"\n"
|
||||
"Section filtering means that IPTV plugin tries to parse and provide VDR with secondary data about the currently active stream. VDR can then use this data for providing various functionalities such as automatic pid change detection and EPG etc.\n"
|
||||
"Enabling this feature does not affect streams that do not contain section data."
|
||||
msgstr ""
|
||||
|
||||
msgid "Scan Sid automatically"
|
||||
msgstr "Scanne les SID automatiquement"
|
||||
|
||||
msgid ""
|
||||
"Define whether the service id shall be scanned automatically.\n"
|
||||
"\n"
|
||||
"Requires the section filtering. Automatic Sid scanning helps VDR to detect changed pids of streams."
|
||||
msgstr ""
|
||||
|
||||
msgid "Disable filters"
|
||||
msgstr "Désactiver les filtres"
|
||||
|
||||
msgid ""
|
||||
"Define number of section filters to be disabled.\n"
|
||||
"\n"
|
||||
"Certain section filters might cause some unwanted behaviour to VDR such as time being falsely synchronized. By black-listing the filters here useful section data can be left intact for VDR to process."
|
||||
msgstr ""
|
||||
|
||||
#. TRANSLATORS: note the singular!
|
||||
msgid "Disable filter"
|
||||
msgstr "Désactiver le filtre"
|
||||
|
||||
msgid "Define an ill-behaving filter to be blacklisted."
|
||||
msgstr ""
|
||||
|
||||
msgid "Help"
|
||||
msgstr "Aide"
|
||||
169
po/it_IT.po
Normal file
169
po/it_IT.po
Normal file
@@ -0,0 +1,169 @@
|
||||
# VDR plugin language source file.
|
||||
# Copyright (C) 2007 Rolf Ahrenberg & Antti Seppala
|
||||
# This file is distributed under the same license as the iptv package.
|
||||
# Gringo <vdr-italian@tiscali.it>, 2008.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: iptv 0.0.6\n"
|
||||
"Report-Msgid-Bugs-To: Rolf Ahrenberg\n"
|
||||
"POT-Creation-Date: 2008-01-20 16:10+0200\n"
|
||||
"PO-Revision-Date: 2008-01-13 16:46+0100\n"
|
||||
"Last-Translator: Gringo <vdr-italian@tiscali.it>\n"
|
||||
"Language-Team: Italian\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
msgid "PAT (0x00)"
|
||||
msgstr "PAT (0x00)"
|
||||
|
||||
msgid "NIT (0x40)"
|
||||
msgstr "NIT (0x40)"
|
||||
|
||||
msgid "SDT (0x42)"
|
||||
msgstr "SDT (0x42)"
|
||||
|
||||
msgid "EIT (0x4E/0x4F)"
|
||||
msgstr "EIT (0x4E/0x4F)"
|
||||
|
||||
msgid "EIT (0x5X)"
|
||||
msgstr "EIT (0x5X)"
|
||||
|
||||
msgid "EIT (0x6X)"
|
||||
msgstr "EIT (0x6X)"
|
||||
|
||||
msgid "TDT (0x70)"
|
||||
msgstr "TDT (0x70)"
|
||||
|
||||
msgid "Experience the IPTV"
|
||||
msgstr "Esperimenta la IPTV"
|
||||
|
||||
msgid "UDP"
|
||||
msgstr "UDP"
|
||||
|
||||
msgid "HTTP"
|
||||
msgstr "HTTP"
|
||||
|
||||
msgid "FILE"
|
||||
msgstr "DATEI"
|
||||
|
||||
msgid "EXT"
|
||||
msgstr "EXT"
|
||||
|
||||
msgid "Protocol"
|
||||
msgstr "Protocollo"
|
||||
|
||||
msgid "Delay (ms)"
|
||||
msgstr "Ritardo (ms)"
|
||||
|
||||
msgid "Script"
|
||||
msgstr "Skript"
|
||||
|
||||
msgid "Parameter"
|
||||
msgstr "Parametro"
|
||||
|
||||
msgid "Address"
|
||||
msgstr "Indirizzo"
|
||||
|
||||
msgid "Port"
|
||||
msgstr "Porta"
|
||||
|
||||
msgid "Nid"
|
||||
msgstr "Nid"
|
||||
|
||||
msgid "Tid"
|
||||
msgstr "Tid"
|
||||
|
||||
msgid "Rid"
|
||||
msgstr "Rid"
|
||||
|
||||
msgid "Cannot find unique channel settings!"
|
||||
msgstr "Impossibile trovare impostazioni canale unico!"
|
||||
|
||||
msgid "IPTV Channels"
|
||||
msgstr "Canali IPTV"
|
||||
|
||||
msgid "IPTV Information"
|
||||
msgstr "Informazione IPTV"
|
||||
|
||||
msgid "General"
|
||||
msgstr "Generale"
|
||||
|
||||
msgid "Pids"
|
||||
msgstr "Pids"
|
||||
|
||||
msgid "Filters"
|
||||
msgstr "Filtri"
|
||||
|
||||
msgid "Bits/bytes"
|
||||
msgstr "Bits/bytes"
|
||||
|
||||
msgid "IPTV information not available!"
|
||||
msgstr "Informazione IPTV non disponibile!"
|
||||
|
||||
msgid "TS buffer size [MB]"
|
||||
msgstr "Dimensione buffer TS [MB]"
|
||||
|
||||
msgid ""
|
||||
"Define a ringbuffer size for transport streams in megabytes.\n"
|
||||
"\n"
|
||||
"Smaller sizes help memory consumption, but are more prone to buffer overflows."
|
||||
msgstr ""
|
||||
|
||||
msgid "TS buffer prefill ratio [%]"
|
||||
msgstr "Percentuale preriempimento buffer TS [%]"
|
||||
|
||||
msgid ""
|
||||
"Define a prefill ratio of the ringbuffer for transport streams before data is transferred to VDR.\n"
|
||||
"\n"
|
||||
"This is useful if streaming media over a slow or unreliable connection."
|
||||
msgstr ""
|
||||
|
||||
msgid "EXT protocol base port"
|
||||
msgstr "Porta base protocollo EXT"
|
||||
|
||||
msgid ""
|
||||
"Define a base port used by EXT protocol.\n"
|
||||
"\n"
|
||||
"The port range is defined by the number of IPTV devices. This setting sets the port which is listened for connections from external applications when using the EXT protocol."
|
||||
msgstr ""
|
||||
|
||||
msgid "Use section filtering"
|
||||
msgstr "Utilizza sezione filtri"
|
||||
|
||||
msgid ""
|
||||
"Define whether the section filtering shall be used.\n"
|
||||
"\n"
|
||||
"Section filtering means that IPTV plugin tries to parse and provide VDR with secondary data about the currently active stream. VDR can then use this data for providing various functionalities such as automatic pid change detection and EPG etc.\n"
|
||||
"Enabling this feature does not affect streams that do not contain section data."
|
||||
msgstr ""
|
||||
|
||||
msgid "Scan Sid automatically"
|
||||
msgstr "Scansione Sid automatica"
|
||||
|
||||
msgid ""
|
||||
"Define whether the service id shall be scanned automatically.\n"
|
||||
"\n"
|
||||
"Requires the section filtering. Automatic Sid scanning helps VDR to detect changed pids of streams."
|
||||
msgstr ""
|
||||
|
||||
msgid "Disable filters"
|
||||
msgstr "Disabilita filtri"
|
||||
|
||||
msgid ""
|
||||
"Define number of section filters to be disabled.\n"
|
||||
"\n"
|
||||
"Certain section filters might cause some unwanted behaviour to VDR such as time being falsely synchronized. By black-listing the filters here useful section data can be left intact for VDR to process."
|
||||
msgstr ""
|
||||
|
||||
#. TRANSLATORS: note the singular!
|
||||
msgid "Disable filter"
|
||||
msgstr "Disabilita filtro"
|
||||
|
||||
msgid "Define an ill-behaving filter to be blacklisted."
|
||||
msgstr ""
|
||||
|
||||
msgid "Help"
|
||||
msgstr "Aiuto"
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: protocolext.c,v 1.20 2007/10/21 19:32:14 ajhseppa Exp $
|
||||
* $Id: protocolext.c,v 1.22 2008/01/06 20:19:02 rahrenbe Exp $
|
||||
*/
|
||||
|
||||
#include <sys/wait.h>
|
||||
@@ -33,7 +33,7 @@ cIptvProtocolExt::~cIptvProtocolExt()
|
||||
{
|
||||
debug("cIptvProtocolExt::~cIptvProtocolExt()\n");
|
||||
// Drop the socket connection
|
||||
Close();
|
||||
cIptvProtocolExt::Close();
|
||||
// Free allocated memory
|
||||
free(scriptFile);
|
||||
free(listenAddr);
|
||||
@@ -60,7 +60,7 @@ void cIptvProtocolExt::ExecuteScript(void)
|
||||
asprintf(&cmd, "%s %d %d", scriptFile, scriptParameter, socketPort);
|
||||
debug("cIptvProtocolExt::ExecuteScript(child): %s\n", cmd);
|
||||
if (execl("/bin/sh", "sh", "-c", cmd, NULL) == -1) {
|
||||
error("ERROR: Script executionfailed: %s", cmd);
|
||||
error("ERROR: Script execution failed: %s", cmd);
|
||||
free(cmd);
|
||||
_exit(-1);
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: protocolext.h,v 1.8 2007/10/21 17:32:43 ajhseppa Exp $
|
||||
* $Id: protocolext.h,v 1.9 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_PROTOCOLEXT_H
|
||||
@@ -28,10 +28,10 @@ public:
|
||||
cIptvProtocolExt();
|
||||
virtual ~cIptvProtocolExt();
|
||||
int Read(unsigned char* *BufferAddr);
|
||||
virtual bool Set(const char* Location, const int Parameter, const int Index);
|
||||
virtual bool Open(void);
|
||||
virtual bool Close(void);
|
||||
virtual cString GetInformation(void);
|
||||
bool Set(const char* Location, const int Parameter, const int Index);
|
||||
bool Open(void);
|
||||
bool Close(void);
|
||||
cString GetInformation(void);
|
||||
};
|
||||
|
||||
#endif // __IPTV_PROTOCOLEXT_H
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: protocolfile.c,v 1.14 2007/10/20 23:25:14 ajhseppa Exp $
|
||||
* $Id: protocolfile.c,v 1.15 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#include <fcntl.h>
|
||||
@@ -32,7 +32,7 @@ cIptvProtocolFile::~cIptvProtocolFile()
|
||||
{
|
||||
debug("cIptvProtocolFile::~cIptvProtocolFile()\n");
|
||||
// Drop open handles
|
||||
Close();
|
||||
cIptvProtocolFile::Close();
|
||||
// Free allocated memory
|
||||
free(fileLocation);
|
||||
free(readBuffer);
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: protocolfile.h,v 1.7 2007/10/19 22:18:55 rahrenbe Exp $
|
||||
* $Id: protocolfile.h,v 1.8 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_PROTOCOLFILE_H
|
||||
@@ -28,11 +28,11 @@ private:
|
||||
public:
|
||||
cIptvProtocolFile();
|
||||
virtual ~cIptvProtocolFile();
|
||||
virtual int Read(unsigned char* *BufferAddr);
|
||||
virtual bool Set(const char* Location, const int Parameter, const int Index);
|
||||
virtual bool Open(void);
|
||||
virtual bool Close(void);
|
||||
virtual cString GetInformation(void);
|
||||
int Read(unsigned char* *BufferAddr);
|
||||
bool Set(const char* Location, const int Parameter, const int Index);
|
||||
bool Open(void);
|
||||
bool Close(void);
|
||||
cString GetInformation(void);
|
||||
};
|
||||
|
||||
#endif // __IPTV_PROTOCOLFILE_H
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: protocolhttp.c,v 1.21 2007/10/21 19:46:03 rahrenbe Exp $
|
||||
* $Id: protocolhttp.c,v 1.22 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
@@ -30,7 +30,7 @@ cIptvProtocolHttp::~cIptvProtocolHttp()
|
||||
{
|
||||
debug("cIptvProtocolHttp::~cIptvProtocolHttp()\n");
|
||||
// Close the socket
|
||||
Close();
|
||||
cIptvProtocolHttp::Close();
|
||||
// Free allocated memory
|
||||
free(streamPath);
|
||||
free(streamAddr);
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: protocolhttp.h,v 1.11 2007/10/21 17:32:43 ajhseppa Exp $
|
||||
* $Id: protocolhttp.h,v 1.12 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_PROTOCOLHTTP_H
|
||||
@@ -29,10 +29,10 @@ public:
|
||||
cIptvProtocolHttp();
|
||||
virtual ~cIptvProtocolHttp();
|
||||
int Read(unsigned char* *BufferAddr);
|
||||
virtual bool Set(const char* Location, const int Parameter, const int Index);
|
||||
virtual bool Open(void);
|
||||
virtual bool Close(void);
|
||||
virtual cString GetInformation(void);
|
||||
bool Set(const char* Location, const int Parameter, const int Index);
|
||||
bool Open(void);
|
||||
bool Close(void);
|
||||
cString GetInformation(void);
|
||||
};
|
||||
|
||||
#endif // __IPTV_PROTOCOLHTTP_H
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: protocoludp.c,v 1.21 2007/10/21 19:32:15 ajhseppa Exp $
|
||||
* $Id: protocoludp.c,v 1.22 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
@@ -29,7 +29,7 @@ cIptvProtocolUdp::~cIptvProtocolUdp()
|
||||
{
|
||||
debug("cIptvProtocolUdp::~cIptvProtocolUdp()\n");
|
||||
// Drop the multicast group and close the socket
|
||||
Close();
|
||||
cIptvProtocolUdp::Close();
|
||||
// Free allocated memory
|
||||
free(streamAddr);
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: protocoludp.h,v 1.12 2007/10/21 17:32:43 ajhseppa Exp $
|
||||
* $Id: protocoludp.h,v 1.13 2008/01/04 23:36:37 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_PROTOCOLUDP_H
|
||||
@@ -25,10 +25,10 @@ public:
|
||||
cIptvProtocolUdp();
|
||||
virtual ~cIptvProtocolUdp();
|
||||
int Read(unsigned char* *BufferAddr);
|
||||
virtual bool Set(const char* Location, const int Parameter, const int Index);
|
||||
virtual bool Open(void);
|
||||
virtual bool Close(void);
|
||||
virtual cString GetInformation(void);
|
||||
bool Set(const char* Location, const int Parameter, const int Index);
|
||||
bool Open(void);
|
||||
bool Close(void);
|
||||
cString GetInformation(void);
|
||||
};
|
||||
|
||||
#endif // __IPTV_PROTOCOLUDP_H
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: sectionfilter.c,v 1.15 2007/10/20 23:25:14 ajhseppa Exp $
|
||||
* $Id: sectionfilter.c,v 1.17 2008/01/19 21:08:02 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#include "sectionfilter.h"
|
||||
@@ -106,7 +106,7 @@ int cIptvSectionFilter::dmxdev_section_callback(const uint8_t *buffer1, size_t b
|
||||
retval = write(fifoDescriptor, buffer1, buffer1_len);
|
||||
ERROR_IF(retval < 0, "write()");
|
||||
// Update statistics
|
||||
AddStatistic(retval, 1);
|
||||
AddSectionStatistic(retval, 1);
|
||||
}
|
||||
#ifdef DEBUG_PRINTF
|
||||
else if (retval)
|
||||
@@ -283,7 +283,7 @@ void cIptvSectionFilter::ProcessData(const uint8_t* buf)
|
||||
const uint8_t *before = &buf[p + 1];
|
||||
uint8_t before_len = buf[p];
|
||||
const uint8_t *after = &before[before_len];
|
||||
uint8_t after_len = count - 1 - before_len;
|
||||
uint8_t after_len = (count - 1) - before_len;
|
||||
|
||||
demux_swfilter_section_copy_dump(before, before_len);
|
||||
/* before start of new section, set pusi_seen = 1 */
|
||||
|
||||
73
setup.c
73
setup.c
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: setup.c,v 1.44 2007/11/04 15:23:16 rahrenbe Exp $
|
||||
* $Id: setup.c,v 1.50 2008/01/20 16:15:14 rahrenbe Exp $
|
||||
*/
|
||||
|
||||
#include <string.h>
|
||||
@@ -11,6 +11,7 @@
|
||||
#include <vdr/device.h>
|
||||
#include <vdr/interface.h>
|
||||
#include <vdr/status.h>
|
||||
#include <vdr/menu.h>
|
||||
|
||||
#include "common.h"
|
||||
#include "config.h"
|
||||
@@ -73,7 +74,7 @@ cString cIptvMenuEditChannel::GetIptvSettings(const char *Param, int *Parameter,
|
||||
char *tag = NULL;
|
||||
char *proto = NULL;
|
||||
char *loc = NULL;
|
||||
if (sscanf(Param, "%a[^|]|%a[^|]|%a[^|]|%u", &tag, &proto, &loc, Parameter) == 4) {
|
||||
if (sscanf(Param, "%a[^|]|%a[^|]|%a[^|]|%d", &tag, &proto, &loc, Parameter) == 4) {
|
||||
cString tagstr(tag, true);
|
||||
cString protostr(proto, true);
|
||||
cString locstr(loc, true);
|
||||
@@ -106,13 +107,13 @@ void cIptvMenuEditChannel::GetChannelData(cChannel *Channel)
|
||||
data.vpid = Channel->Vpid();
|
||||
data.ppid = Channel->Ppid();
|
||||
data.tpid = Channel->Tpid();
|
||||
for (unsigned int i = 0; i < sizeof(data.apid); ++i)
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(data.apid); ++i)
|
||||
data.apid[i] = Channel->Apid(i);
|
||||
for (unsigned int i = 0; i < sizeof(data.dpid); ++i)
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(data.dpid); ++i)
|
||||
data.dpid[i] = Channel->Dpid(i);
|
||||
for (unsigned int i = 0; i < sizeof(data.spid); ++i)
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(data.spid); ++i)
|
||||
data.spid[i] = Channel->Spid(i);
|
||||
for (unsigned int i = 0; i < sizeof(data.caids); ++i)
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(data.caids); ++i)
|
||||
data.caids[i] = Channel->Ca(i);
|
||||
data.sid = Channel->Sid();
|
||||
data.nid = Channel->Nid();
|
||||
@@ -129,13 +130,13 @@ void cIptvMenuEditChannel::GetChannelData(cChannel *Channel)
|
||||
data.vpid = 0;
|
||||
data.ppid = 0;
|
||||
data.tpid = 0;
|
||||
for (unsigned int i = 0; i < sizeof(data.apid); ++i)
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(data.apid); ++i)
|
||||
data.apid[i] = 0;
|
||||
for (unsigned int i = 0; i < sizeof(data.dpid); ++i)
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(data.dpid); ++i)
|
||||
data.dpid[i] = 0;
|
||||
for (unsigned int i = 0; i < sizeof(data.spid); ++i)
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(data.spid); ++i)
|
||||
data.spid[i] = 0;
|
||||
for (unsigned int i = 0; i < sizeof(data.caids); ++i)
|
||||
for (unsigned int i = 0; i < ARRAY_SIZE(data.caids); ++i)
|
||||
data.caids[i] = 0;
|
||||
data.sid = 1;
|
||||
data.nid = 0;
|
||||
@@ -636,19 +637,52 @@ cIptvPluginSetup::cIptvPluginSetup()
|
||||
void cIptvPluginSetup::Setup(void)
|
||||
{
|
||||
int current = Current();
|
||||
|
||||
Clear();
|
||||
Add(new cMenuEditIntItem( tr("TS buffer size [MB]"), &tsBufferSize, 1, 4));
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
help.Clear();
|
||||
#endif
|
||||
|
||||
Add(new cMenuEditIntItem( tr("TS buffer size [MB]"), &tsBufferSize, 1, 4));
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
help.Append(tr("Define a ringbuffer size for transport streams in megabytes.\n\nSmaller sizes help memory consumption, but are more prone to buffer overflows."));
|
||||
#endif
|
||||
|
||||
Add(new cMenuEditIntItem( tr("TS buffer prefill ratio [%]"), &tsBufferPrefill, 0, 40));
|
||||
Add(new cMenuEditIntItem( tr("EXT protocol base port"), &extProtocolBasePort, 0, 0xFFF7));
|
||||
Add(new cMenuEditBoolItem(tr("Use section filtering"), §ionFiltering));
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
help.Append(tr("Define a prefill ratio of the ringbuffer for transport streams before data is transferred to VDR.\n\nThis is useful if streaming media over a slow or unreliable connection."));
|
||||
#endif
|
||||
|
||||
Add(new cMenuEditIntItem( tr("EXT protocol base port"), &extProtocolBasePort, 0, 0xFFF7));
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
help.Append(tr("Define a base port used by EXT protocol.\n\nThe port range is defined by the number of IPTV devices. This setting sets the port which is listened for connections from external applications when using the EXT protocol."));
|
||||
#endif
|
||||
|
||||
Add(new cMenuEditBoolItem(tr("Use section filtering"), §ionFiltering));
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
help.Append(tr("Define whether the section filtering shall be used.\n\nSection filtering means that IPTV plugin tries to parse and provide VDR with secondary data about the currently active stream. VDR can then use this data for providing various functionalities such as automatic pid change detection and EPG etc.\nEnabling this feature does not affect streams that do not contain section data."));
|
||||
#endif
|
||||
|
||||
if (sectionFiltering) {
|
||||
Add(new cMenuEditBoolItem(tr("Scan Sid automatically"), &sidScanning));
|
||||
Add(new cMenuEditIntItem( tr("Disable filters"), &numDisabledFilters, 0, SECTION_FILTER_TABLE_SIZE));
|
||||
Add(new cMenuEditBoolItem(tr("Scan Sid automatically"), &sidScanning));
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
help.Append(tr("Define whether the service id shall be scanned automatically.\n\nRequires the section filtering. Automatic Sid scanning helps VDR to detect changed pids of streams."));
|
||||
#endif
|
||||
|
||||
Add(new cMenuEditIntItem( tr("Disable filters"), &numDisabledFilters, 0, SECTION_FILTER_TABLE_SIZE));
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
help.Append(tr("Define number of section filters to be disabled.\n\nCertain section filters might cause some unwanted behaviour to VDR such as time being falsely synchronized. By black-listing the filters here useful section data can be left intact for VDR to process."));
|
||||
#endif
|
||||
|
||||
for (int i = 0; i < numDisabledFilters; ++i) {
|
||||
// TRANSLATORS: note the singular!
|
||||
Add(new cMenuEditStraItem(tr("Disable filter"), &disabledFilterIndexes[i], SECTION_FILTER_TABLE_SIZE, disabledFilterNames));
|
||||
Add(new cMenuEditStraItem(tr("Disable filter"), &disabledFilterIndexes[i], SECTION_FILTER_TABLE_SIZE, disabledFilterNames));
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
help.Append(tr("Define an ill-behaving filter to be blacklisted."));
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
SetCurrent(Get(current));
|
||||
Display();
|
||||
}
|
||||
@@ -674,18 +708,25 @@ eOSState cIptvPluginSetup::ProcessKey(eKeys Key)
|
||||
int oldsectionFiltering = sectionFiltering;
|
||||
int oldNumDisabledFilters = numDisabledFilters;
|
||||
eOSState state = cMenuSetupPage::ProcessKey(Key);
|
||||
|
||||
if (state == osUnknown) {
|
||||
switch (Key) {
|
||||
case kRed: return EditChannel();
|
||||
case kBlue: return ShowInfo();
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
case kInfo: if (Current() < help.Size())
|
||||
return AddSubMenu(new cMenuText(cString::sprintf("%s - %s '%s'", tr("Help"), trVDR("Plugin"), PLUGIN_NAME_I18N), help[Current()]));
|
||||
#endif
|
||||
default: state = osContinue;
|
||||
}
|
||||
}
|
||||
|
||||
if ((Key != kNone) && ((numDisabledFilters != oldNumDisabledFilters) || (sectionFiltering != oldsectionFiltering))) {
|
||||
while ((numDisabledFilters < oldNumDisabledFilters) && (oldNumDisabledFilters > 0))
|
||||
disabledFilterIndexes[--oldNumDisabledFilters] = -1;
|
||||
Setup();
|
||||
}
|
||||
|
||||
return state;
|
||||
}
|
||||
|
||||
|
||||
5
setup.h
5
setup.h
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: setup.h,v 1.16 2007/10/20 17:26:46 rahrenbe Exp $
|
||||
* $Id: setup.h,v 1.18 2008/01/20 16:15:14 rahrenbe Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_SETUP_H
|
||||
@@ -23,6 +23,9 @@ private:
|
||||
int numDisabledFilters;
|
||||
int disabledFilterIndexes[SECTION_FILTER_TABLE_SIZE];
|
||||
const char *disabledFilterNames[SECTION_FILTER_TABLE_SIZE];
|
||||
#if defined(APIVERSNUM) && APIVERSNUM >= 10513
|
||||
cVector<const char*> help;
|
||||
#endif
|
||||
|
||||
eOSState EditChannel(void);
|
||||
eOSState ShowInfo(void);
|
||||
|
||||
@@ -1,25 +0,0 @@
|
||||
/*
|
||||
* statisticif.h: IPTV plugin for the Video Disk Recorder
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: statisticif.h,v 1.4 2007/10/07 19:06:33 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_STATISTICIF_H
|
||||
#define __IPTV_STATISTICIF_H
|
||||
|
||||
#include <vdr/tools.h>
|
||||
|
||||
class cIptvStatisticIf {
|
||||
public:
|
||||
cIptvStatisticIf() {}
|
||||
virtual ~cIptvStatisticIf() {}
|
||||
virtual cString GetStatistic() = 0;
|
||||
|
||||
private:
|
||||
cIptvStatisticIf(const cIptvStatisticIf&);
|
||||
cIptvStatisticIf& operator=(const cIptvStatisticIf&);
|
||||
};
|
||||
|
||||
#endif // __IPTV_STATISTICIF_H
|
||||
22
statistics.c
22
statistics.c
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: statistics.c,v 1.20 2007/10/11 23:06:49 rahrenbe Exp $
|
||||
* $Id: statistics.c,v 1.22 2008/01/19 21:08:03 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#include <limits.h>
|
||||
@@ -27,7 +27,7 @@ cIptvSectionStatistics::~cIptvSectionStatistics()
|
||||
//debug("cIptvSectionStatistics::~cIptvSectionStatistics()\n");
|
||||
}
|
||||
|
||||
cString cIptvSectionStatistics::GetStatistic()
|
||||
cString cIptvSectionStatistics::GetSectionStatistic()
|
||||
{
|
||||
//debug("cIptvSectionStatistics::GetStatistic()\n");
|
||||
cMutexLock MutexLock(&mutex);
|
||||
@@ -43,7 +43,7 @@ cString cIptvSectionStatistics::GetStatistic()
|
||||
return info;
|
||||
}
|
||||
|
||||
void cIptvSectionStatistics::AddStatistic(long Bytes, long Calls)
|
||||
void cIptvSectionStatistics::AddSectionStatistic(long Bytes, long Calls)
|
||||
{
|
||||
//debug("cIptvSectionStatistics::AddStatistic(Bytes=%ld, Calls=%ld)\n", Bytes, Calls);
|
||||
cMutexLock MutexLock(&mutex);
|
||||
@@ -67,7 +67,7 @@ cIptvPidStatistics::~cIptvPidStatistics()
|
||||
debug("cIptvPidStatistics::~cIptvPidStatistics()\n");
|
||||
}
|
||||
|
||||
cString cIptvPidStatistics::GetStatistic()
|
||||
cString cIptvPidStatistics::GetPidStatistic()
|
||||
{
|
||||
//debug("cIptvPidStatistics::GetStatistic()\n");
|
||||
cMutexLock MutexLock(&mutex);
|
||||
@@ -84,7 +84,7 @@ cString cIptvPidStatistics::GetStatistic()
|
||||
IptvConfig.GetUseBytes() ? "B" : "bit");
|
||||
}
|
||||
}
|
||||
memset(&mostActivePids, '\0', sizeof(mostActivePids));
|
||||
memset(mostActivePids, '\0', sizeof(mostActivePids));
|
||||
return info;
|
||||
}
|
||||
|
||||
@@ -100,7 +100,7 @@ int cIptvPidStatistics::SortPids(const void* data1, const void* data2)
|
||||
return 0;
|
||||
}
|
||||
|
||||
void cIptvPidStatistics::AddStatistic(u_short Pid, long Payload)
|
||||
void cIptvPidStatistics::AddPidStatistic(u_short Pid, long Payload)
|
||||
{
|
||||
//debug("cIptvPidStatistics::AddStatistic(pid=%ld, payload=%ld)\n", Pid, Payload);
|
||||
cMutexLock MutexLock(&mutex);
|
||||
@@ -110,7 +110,7 @@ void cIptvPidStatistics::AddStatistic(u_short Pid, long Payload)
|
||||
if (mostActivePids[i].pid == Pid) {
|
||||
mostActivePids[i].DataAmount += Payload;
|
||||
// Now re-sort the array and quit
|
||||
qsort(&mostActivePids, numberOfElements, sizeof(pidStruct), SortPids);
|
||||
qsort(mostActivePids, numberOfElements, sizeof(pidStruct), SortPids);
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -140,7 +140,7 @@ cIptvStreamerStatistics::~cIptvStreamerStatistics()
|
||||
debug("cIptvStreamerStatistics::~cIptvStreamerStatistics()\n");
|
||||
}
|
||||
|
||||
cString cIptvStreamerStatistics::GetStatistic()
|
||||
cString cIptvStreamerStatistics::GetStreamerStatistic()
|
||||
{
|
||||
//debug("cIptvStreamerStatistics::GetStatistic()\n");
|
||||
cMutexLock MutexLock(&mutex);
|
||||
@@ -154,7 +154,7 @@ cString cIptvStreamerStatistics::GetStatistic()
|
||||
return info;
|
||||
}
|
||||
|
||||
void cIptvStreamerStatistics::AddStatistic(long Bytes)
|
||||
void cIptvStreamerStatistics::AddStreamerStatistic(long Bytes)
|
||||
{
|
||||
//debug("cIptvStreamerStatistics::AddStatistic(Bytes=%ld)\n", Bytes);
|
||||
cMutexLock MutexLock(&mutex);
|
||||
@@ -177,7 +177,7 @@ cIptvBufferStatistics::~cIptvBufferStatistics()
|
||||
debug("cIptvBufferStatistics::~cIptvBufferStatistics()\n");
|
||||
}
|
||||
|
||||
cString cIptvBufferStatistics::GetStatistic()
|
||||
cString cIptvBufferStatistics::GetBufferStatistic()
|
||||
{
|
||||
//debug("cIptvBufferStatistics::GetStatistic()\n");
|
||||
cMutexLock MutexLock(&mutex);
|
||||
@@ -201,7 +201,7 @@ cString cIptvBufferStatistics::GetStatistic()
|
||||
return info;
|
||||
}
|
||||
|
||||
void cIptvBufferStatistics::AddStatistic(long Bytes, long Used)
|
||||
void cIptvBufferStatistics::AddBufferStatistic(long Bytes, long Used)
|
||||
{
|
||||
//debug("cIptvBufferStatistics::AddStatistic(Bytes=%ld, Used=%ld)\n", Bytes, Used);
|
||||
cMutexLock MutexLock(&mutex);
|
||||
|
||||
28
statistics.h
28
statistics.h
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: statistics.h,v 1.10 2007/10/11 23:06:49 rahrenbe Exp $
|
||||
* $Id: statistics.h,v 1.11 2008/01/19 21:08:03 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#ifndef __IPTV_STATISTICS_H
|
||||
@@ -11,17 +11,15 @@
|
||||
|
||||
#include <vdr/thread.h>
|
||||
|
||||
#include "statisticif.h"
|
||||
|
||||
// Section statistics
|
||||
class cIptvSectionStatistics : public cIptvStatisticIf {
|
||||
class cIptvSectionStatistics {
|
||||
public:
|
||||
cIptvSectionStatistics();
|
||||
virtual ~cIptvSectionStatistics();
|
||||
cString GetStatistic();
|
||||
cString GetSectionStatistic();
|
||||
|
||||
protected:
|
||||
void AddStatistic(long Bytes, long Calls);
|
||||
void AddSectionStatistic(long Bytes, long Calls);
|
||||
|
||||
private:
|
||||
long filteredData;
|
||||
@@ -31,14 +29,14 @@ private:
|
||||
};
|
||||
|
||||
// Pid statistics
|
||||
class cIptvPidStatistics : public cIptvStatisticIf {
|
||||
class cIptvPidStatistics {
|
||||
public:
|
||||
cIptvPidStatistics();
|
||||
virtual ~cIptvPidStatistics();
|
||||
cString GetStatistic();
|
||||
cString GetPidStatistic();
|
||||
|
||||
protected:
|
||||
void AddStatistic(u_short Pid, long Payload);
|
||||
void AddPidStatistic(u_short Pid, long Payload);
|
||||
|
||||
private:
|
||||
struct pidStruct {
|
||||
@@ -54,14 +52,14 @@ private:
|
||||
};
|
||||
|
||||
// Streamer statistics
|
||||
class cIptvStreamerStatistics : public cIptvStatisticIf {
|
||||
class cIptvStreamerStatistics {
|
||||
public:
|
||||
cIptvStreamerStatistics();
|
||||
virtual ~cIptvStreamerStatistics();
|
||||
cString GetStatistic();
|
||||
cString GetStreamerStatistic();
|
||||
|
||||
protected:
|
||||
void AddStatistic(long Bytes);
|
||||
void AddStreamerStatistic(long Bytes);
|
||||
|
||||
private:
|
||||
long dataBytes;
|
||||
@@ -70,14 +68,14 @@ private:
|
||||
};
|
||||
|
||||
// Buffer statistics
|
||||
class cIptvBufferStatistics : public cIptvStatisticIf {
|
||||
class cIptvBufferStatistics {
|
||||
public:
|
||||
cIptvBufferStatistics();
|
||||
virtual ~cIptvBufferStatistics();
|
||||
cString GetStatistic();
|
||||
cString GetBufferStatistic();
|
||||
|
||||
protected:
|
||||
void AddStatistic(long Bytes, long Used);
|
||||
void AddBufferStatistic(long Bytes, long Used);
|
||||
|
||||
private:
|
||||
long dataBytes;
|
||||
|
||||
12
streamer.c
12
streamer.c
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* See the README file for copyright information and how to reach the author.
|
||||
*
|
||||
* $Id: streamer.c,v 1.27 2007/10/20 08:58:15 ajhseppa Exp $
|
||||
* $Id: streamer.c,v 1.29 2008/01/19 21:08:03 ajhseppa Exp $
|
||||
*/
|
||||
|
||||
#include <vdr/thread.h>
|
||||
@@ -38,7 +38,7 @@ void cIptvStreamer::Action(void)
|
||||
mutex->Lock();
|
||||
int length = protocol->Read(&buffer);
|
||||
if (length >= 0) {
|
||||
AddStatistic(length);
|
||||
AddStreamerStatistic(length);
|
||||
int p = ringBuffer->Put(buffer, length);
|
||||
if (p != length && Running())
|
||||
ringBuffer->ReportOverflow(length - p);
|
||||
@@ -76,11 +76,13 @@ bool cIptvStreamer::Close(void)
|
||||
// Close the protocol. A mutex should be taken here to avoid a race condition
|
||||
// where thread Action() may be in the process of accessing the protocol.
|
||||
// Taking a mutex serializes the Close() and Action() -calls.
|
||||
if (protocol) {
|
||||
mutex->Lock();
|
||||
if (mutex)
|
||||
mutex->Lock();
|
||||
if (protocol)
|
||||
protocol->Close();
|
||||
if (mutex)
|
||||
mutex->Unlock();
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user