]> git.vomp.tv Git - vompclient.git/blob - vvideorec.h
Rename TCP class to TCPOld
[vompclient.git] / vvideorec.h
1 /*
2     Copyright 2004-2019 Chris Tallon
3
4     This file is part of VOMP.
5
6     VOMP is free software; you can redistribute it and/or modify
7     it under the terms of the GNU General Public License as published by
8     the Free Software Foundation; either version 2 of the License, or
9     (at your option) any later version.
10
11     VOMP is distributed in the hope that it will be useful,
12     but WITHOUT ANY WARRANTY; without even the implied warranty of
13     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14     GNU General Public License for more details.
15
16     You should have received a copy of the GNU General Public License
17     along with VOMP.  If not, see <https://www.gnu.org/licenses/>.
18 */
19
20 #ifndef VVIDEOREC_H
21 #define VVIDEOREC_H
22
23 #include <stdio.h>
24
25 #include "boxx.h"
26 #include "timers.h"
27 #include "region.h"
28 #include "colour.h"
29 #include "osdreceiver.h"
30
31 #include "video.h"
32
33 class VDR;
34 class PlayerVideoRec;
35 class Recording;
36 class VAudioSelector;
37 class Message;
38 class BoxStack;
39 class VInfo;
40 class Bitmap;
41
42
43 //#include "vepg.h" // for testing EPG in NTSC with a NTSC test video
44
45 class VVideoRec : public Boxx, public TimerReceiver, public OSDReceiver
46 {
47   public:
48     VVideoRec(Recording* rec, bool ish264);
49     virtual ~VVideoRec();
50     void preDelete();
51     int handleCommand(int command);
52     void go(bool resume);
53
54     void timercall(int clientReference);
55     void processMessage(Message* m);
56
57     void drawOSDBitmap(UINT posX, UINT posY, const Bitmap&, const DisplayRegion& region);
58     void clearOSD();
59     void clearOSDArea(UINT posX, UINT posY, UINT width, UINT height, const DisplayRegion& region);
60
61     void doTeletext();
62
63   private:
64     BoxStack* boxstack;
65     VDR* vdr;
66     Video* video;
67     Timers* timers;
68     PlayerVideoRec* player;
69     Recording* myRec;
70
71     VAudioSelector* vas;
72
73     DrawStyle transparent;
74     DrawStyle barBlue;
75
76     UCHAR videoMode;
77     void toggleChopSides();
78
79     bool playing{};
80
81     bool barShowing;
82     bool barGenHold;
83     bool barScanHold;
84     bool barVasHold;
85
86     void doAudioSelector();
87     void doBar(int action);
88     void drawBarClocks();
89     void stopPlay();
90     void removeBar();
91     void doSummary();
92     void removeSummary();
93     Region barRegion;
94     Region clocksRegion;
95
96     UINT startMargin{};
97     UINT endMargin{};
98
99     int lastbar{-1};
100     
101     VInfo* vsummary;
102 };
103
104 #endif