mirror of
https://github.com/vdr-projects/vdr.git
synced 2025-03-01 10:50:46 +00:00
- The CAM is now accessed only if the current channel actually has a non-zero Ca value, and CAM access is completely suppressed during replay, which avoids problems in case the CAM is attached to the primary DVB device. - The "Left" and "Right" buttons now set the cursor to the first or last list item even if the list consist only of a single page, like, for instance, the Main menu (thanks to Oliver Endriss). - Made the log message "OSD window width must be a multiple of 4..." a debug message instead of an error message, so it can be avoided by using a log level less than 3. - Updated Greek language texts (thanks to Dimitrios Dimitrakos). - Fixed faulty behaviour of the "Mute" key in case the channel display is visible (thanks to Florian Bartels for reporting this one and Sascha Volkenandt for helping to fix it). - Modified LOF handling to allow for C-band reception (thanks to Malcolm Caldwell). - Added some missing cAudio handling calls (thanks to Werner Fink). - Replaced the 'for' loops in StripAudioPackets() with memset() calls (thanks to Werner Fink). - Further increased the timeout until an index file is considerd no longer to be written. - Fixed a crash in case the index file can't be accessed any more during replay (thanks to Stefan Huelswitt for reporting this one). - Fixed displaying messages in the status line in case they exceed the OSD width (thanks to Gerhard Steiner for reporting this one). - Avoiding high CPU load in case the connection to LIRC gets lost (thanks to Ludwig Nussel). - Fixed handling repeat function with LIRC (thanks to Ludwig Nussel). - Fixed handling min/max borders when entering integer values (thanks to Andy Grobb for reporting this one). - Implemented a "resume ID" which allows several users to each have their own resume.vdr files (thanks to Martin Hammerschmid). This parameter can be set in the "Setup/Replay" menu (see MANUAL for details). - Now using 'libdtv' version 0.0.5 (thanks to Rolf Hakenes for the new version and Stefan Huelswitt for adapting VDR to it). - If no device with an MPEG decoder can be found at startup, the first device is now used as primary device (just to have some device). - Adjusted some Premiere channels in 'channels.conf' (thanks to Thomas Koch). - Updated 'channels.conf.cable' (thanks to Stefan Hußfeldt). - The 'epg.data' file is now read after all plugins have been started (thanks to Sascha Volkenandt). - The LIRC remote control no longer tries to learn keys if it can't connect to the LIRC daemon (thanks to Ludwig Nussel for reporting this one). The same applies to the RCU remote control in case of errors during startup. - Fixed handling of Ca parameters with values <= MAXDEVICES, which don't indicate an actual encrypted channel (thanks to Stefan Huelswitt for reporting this one).
109 lines
2.7 KiB
C++
109 lines
2.7 KiB
C++
/*
|
|
* ci.h: Common Interface
|
|
*
|
|
* See the main source file 'vdr.c' for copyright information and
|
|
* how to reach the author.
|
|
*
|
|
* $Id: ci.h 1.4 2003/03/23 15:18:40 kls Exp $
|
|
*/
|
|
|
|
#ifndef __CI_H
|
|
#define __CI_H
|
|
|
|
#include <stdint.h>
|
|
#include <stdio.h>
|
|
#include "thread.h"
|
|
|
|
class cCiMMI;
|
|
|
|
class cCiMenu {
|
|
friend class cCiMMI;
|
|
private:
|
|
enum { MAX_CIMENU_ENTRIES = 64 }; ///< XXX is there a specified maximum?
|
|
cCiMMI *mmi;
|
|
bool selectable;
|
|
char *titleText;
|
|
char *subTitleText;
|
|
char *bottomText;
|
|
char *entries[MAX_CIMENU_ENTRIES];
|
|
int numEntries;
|
|
bool AddEntry(char *s);
|
|
cCiMenu(cCiMMI *MMI, bool Selectable);
|
|
public:
|
|
~cCiMenu();
|
|
const char *TitleText(void) { return titleText; }
|
|
const char *SubTitleText(void) { return subTitleText; }
|
|
const char *BottomText(void) { return bottomText; }
|
|
const char *Entry(int n) { return n < numEntries ? entries[n] : NULL; }
|
|
int NumEntries(void) { return numEntries; }
|
|
bool Selectable(void) { return selectable; }
|
|
bool Select(int Index);
|
|
bool Cancel(void);
|
|
};
|
|
|
|
class cCiEnquiry {
|
|
friend class cCiMMI;
|
|
private:
|
|
cCiMMI *mmi;
|
|
char *text;
|
|
bool blind;
|
|
int expectedLength;
|
|
cCiEnquiry(cCiMMI *MMI);
|
|
public:
|
|
~cCiEnquiry();
|
|
const char *Text(void) { return text; }
|
|
bool Blind(void) { return blind; }
|
|
int ExpectedLength(void) { return expectedLength; }
|
|
bool Reply(const char *s);
|
|
bool Cancel(void);
|
|
};
|
|
|
|
class cCiCaPmt {
|
|
friend class cCiConditionalAccessSupport;
|
|
private:
|
|
int length;
|
|
int esInfoLengthPos;
|
|
uint8_t capmt[2048]; ///< XXX is there a specified maximum?
|
|
public:
|
|
cCiCaPmt(int ProgramNumber);
|
|
void AddPid(int Pid);
|
|
void AddCaDescriptor(int Length, uint8_t *Data);
|
|
};
|
|
|
|
#define MAX_CI_SESSION 16 //XXX
|
|
|
|
class cCiSession;
|
|
class cCiTransportLayer;
|
|
class cCiTransportConnection;
|
|
|
|
class cCiHandler {
|
|
private:
|
|
cMutex mutex;
|
|
int numSlots;
|
|
bool enabled;
|
|
cCiSession *sessions[MAX_CI_SESSION];
|
|
cCiTransportLayer *tpl;
|
|
cCiTransportConnection *tc;
|
|
int ResourceIdToInt(const uint8_t *Data);
|
|
bool Send(uint8_t Tag, int SessionId, int ResourceId = 0, int Status = -1);
|
|
cCiSession *GetSessionBySessionId(int SessionId);
|
|
cCiSession *GetSessionByResourceId(int ResourceId, int Slot);
|
|
cCiSession *CreateSession(int ResourceId);
|
|
bool OpenSession(int Length, const uint8_t *Data);
|
|
bool CloseSession(int SessionId);
|
|
int CloseAllSessions(int Slot);
|
|
cCiHandler(int Fd, int NumSlots);
|
|
public:
|
|
~cCiHandler();
|
|
static cCiHandler *CreateCiHandler(const char *FileName);
|
|
void SetEnabled(bool Enabled) { enabled = Enabled; }
|
|
bool Process(void);
|
|
bool EnterMenu(int Slot);
|
|
cCiMenu *GetMenu(void);
|
|
cCiEnquiry *GetEnquiry(void);
|
|
bool SetCaPmt(cCiCaPmt &CaPmt);
|
|
bool Reset(int Slot);
|
|
};
|
|
|
|
#endif //__CI_H
|