FireBirdLib - Topfield TMS PVR TAP Programming Library
EPGInfo_FindFirst.c
Go to the documentation of this file.
1#include "FBLib_EPG.h"
2
8byte *EPGInfoCacheMap = NULL;
13char EPGCacheFile[40];
15
17{
18 TRACEENTER();
19
20 dword *x;
21 byte PointerOffset;
22 TYPE_EvtInfo *Evt;
23
25 {
27 {
28 //For whatever reason, the hashed pointer list runs into the wrong direction (from younger to older events)
30 PointerOffset = 0x20;
32 }
33 else
34 {
36 x = (dword*)&Evt->TreeByHash;
37 PointerOffset = 0x20;
39 }
40 }
41 else
42 {
44 PointerOffset = 0x28;
45 EPGInfoReverseOrder = FALSE;
46 }
47
49 if(EPGInfoCacheEntries == 0)
50 {
51 if(EPGData) memset(EPGData, 0, sizeof(TYPE_EPGInfo));
52
53 TRACEEXIT();
54 return 0;
55 }
57 EPGInfo_CloneToCache(x, PointerOffset, &EPGFilter);
58
60
62 {
64 {
65 memcpy(EPGData, &EPGInfoCache[EPGInfoNrEntries - 1], sizeof(TYPE_EPGInfo));
66 }
67 else
68 {
69 memcpy(EPGData, &EPGInfoCache[0], sizeof(TYPE_EPGInfo));
70 }
71 }
72
73 TRACEEXIT();
74 return EPGInfoNrEntries;
75}
dword * Appl_GetEvtListHeadInHash(word NetID, word TSID, word ServiceID)
dword * Appl_GetEvtListHeadInUsePool(void)
void * Appl_GetSameTimeEvent(byte SatIndex, word NetID, word TSID, word ServiceID)
void EPGInfo_CloneToCache(dword *TreePointer, byte StructOffset, tEPGFilter *EPGFilter)
dword EPGInfo_CountEvents(dword *TreePointer)
bool EPGInfo_CreateCache(int NrRecords)
char EPGCacheFile[40]
tEPGFilter EPGFilter
dword EPGInfoCacheSize
byte * EPGInfoCacheMap
int EPGAbortLoad
bool EPGInfoReverseOrder
int EPGInfoCurrentEntry
int EPGInfoNrEntries
int EPGInfoCacheEntries
int EPGInfo_FindFirst(TYPE_EPGInfo *EPGData)
int EPGInfoCacheFile
TYPE_EPGInfo * EPGInfoCache
dword EPGInfoStructSize
#define TRACEEXIT()
Definition: libFireBird.h:1244
#define TRACEENTER()
Definition: libFireBird.h:1243
tTreeEntry TreeByHash
Definition: FBLib_EPG.h:61
bool StartCurrent
Definition: FBLib_EPG.h:20
byte SatIndex
Definition: FBLib_EPG.h:19
word TSID
Definition: FBLib_EPG.h:17
bool ChannelFilter
Definition: FBLib_EPG.h:15
word ServiceID
Definition: FBLib_EPG.h:18
word NetworkID
Definition: FBLib_EPG.h:16