From 6b2090e9ad27ea79313aed7c29b452a243f63621 Mon Sep 17 00:00:00 2001 From: Rolf Ahrenberg Date: Sun, 16 Nov 2014 16:30:45 +0200 Subject: [PATCH] Moved tuner statistics back to cSatipTuner. --- device.c | 1 - device.h | 2 +- tuner.c | 4 +++- tuner.h | 1 - 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/device.c b/device.c index 83f2c3a..2b543ae 100644 --- a/device.c +++ b/device.c @@ -407,7 +407,6 @@ bool cSatipDevice::HasInternalCam(void) void cSatipDevice::WriteData(uchar *bufferP, int lengthP) { //debug("cSatipDevice::%s(%u)", __FUNCTION__, deviceIndexM); - AddTunerStatistic(lengthP); // Fill up TS buffer if (tsBufferM) { int len = tsBufferM->Put(bufferP, lengthP); diff --git a/device.h b/device.h index 370dcd8..b852c01 100644 --- a/device.h +++ b/device.h @@ -15,7 +15,7 @@ #include "sectionfilter.h" #include "statistics.h" -class cSatipDevice : public cDevice, public cSatipPidStatistics, public cSatipBufferStatistics, public cSatipTunerStatistics, public cSatipDeviceIf { +class cSatipDevice : public cDevice, public cSatipPidStatistics, public cSatipBufferStatistics, public cSatipDeviceIf { // static ones public: static unsigned int deviceCount; diff --git a/tuner.c b/tuner.c index c9c92ce..b1268a3 100644 --- a/tuner.c +++ b/tuner.c @@ -242,8 +242,10 @@ unsigned int cSatipTuner::GetVideoDataSize(void) void cSatipTuner::ProcessVideoData(u_char *bufferP, int lengthP) { //debug("cSatipTuner::%s(%d) [device %d]", __FUNCTION__, lengthP, deviceIdM); - if (lengthP > 0) + if (lengthP > 0) { + AddTunerStatistic(lengthP); deviceM->WriteData(bufferP, lengthP); + } cMutexLock MutexLock(&mutexM); reConnectM.Set(eConnectTimeoutMs); } diff --git a/tuner.h b/tuner.h index 57ad887..e3aa6f3 100644 --- a/tuner.h +++ b/tuner.h @@ -17,7 +17,6 @@ #include "rtsp.h" #include "server.h" #include "statistics.h" -#include "socket.h" class cSatipPid : public cVector { private: