MythTV  master
channelscanmiscsettings.h
Go to the documentation of this file.
1 /* -*- Mode: c++ -*-
2  * vim: set expandtab tabstop=4 shiftwidth=4:
3  *
4  * Original Project
5  * MythTV http://www.mythtv.org
6  *
7  * Copyright (c) 2004, 2005 John Pullan <john@pullan.org>
8  * Copyright (c) 2005 - 2007 Daniel Kristjansson
9  *
10  * Description:
11  * Collection of classes to provide channel scanning functionallity
12  *
13  * This program is free software; you can redistribute it and/or
14  * modify it under the terms of the GNU General Public License
15  * as published by the Free Software Foundation; either version 2
16  * of the License, or (at your option) any later version.
17  *
18  * This program is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21  * GNU General Public License for more details.
22  *
23  * You should have received a copy of the GNU General Public License
24  * along with this program; if not, write to the Free Software
25  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
26  * Or, point your browser to http://www.gnu.org/copyleft/gpl.html
27  *
28  */
29 
30 #ifndef _MISC_SETTINGS_H_
31 #define _MISC_SETTINGS_H_
32 
33 #include "standardsettings.h"
34 #include "channelscantypes.h"
35 
36 class TransLabelSetting;
37 class ScanWizard;
38 class OptionalTypeSetting;
39 class PaneDVBT;
40 class PaneDVBS;
41 class PaneDVBS2;
42 class PaneATSC;
43 class PaneDVBC;
44 class PaneAnalog;
45 class STPane;
46 class DVBUtilsImportPane;
47 
48 // ///////////////////////////////
49 // Settings Below Here
50 // ///////////////////////////////
51 
53 {
54  public:
56  {
57  setLabel(QObject::tr("Ignore Signal Timeout"));
59  QObject::tr("This option allows you to slow down the scan for "
60  "broken drivers, such as the DVB drivers for the "
61  "Leadtek LR6650 DVB card."));
62  }
63 };
64 
66 {
67  public:
69  {
70  setLabel(QObject::tr("Search new Transports"));
72  QObject::tr("Digital transmissions may signal other available "
73  "Transports. If this option is enabled the scanner "
74  "scans all signaled transports for new/updated "
75  "channels."));
76  }
77 };
78 
80 {
81  public:
83  {
84  setLabel(QObject::tr("Desired Services"));
85  setHelpText(QObject::tr(
86  "TV - Adds A/V services only, "
87  "TV+Radio - Adds all services with audio, "
88  "All - Adds all services "
89  "(including data only services)."));
90  addSelection(QObject::tr("TV"), "tv", true);
91  addSelection(QObject::tr("TV+Radio"), "audio");
92  addSelection(QObject::tr("All"), "all");
93  };
94 
96  {
97  QString val = getValue();
98  int ret = kRequireVideo | kRequireAudio;
99  if (val == "tv")
101  else if (val == "audio")
102  ret = kRequireAudio;
103  else if (val == "all")
104  ret = 0;
105  return (ServiceRequirements) ret;
106  }
107 };
108 
110 {
111  public:
113  {
114  setValue(true);
115  setLabel(QObject::tr("Unencrypted Only"));
116  setHelpText(
117  QObject::tr(
118  "If set, only non-encrypted channels will be "
119  "added during the scan."));
120  };
121 };
122 
124 {
125  public:
127  {
128  setValue(false);
129  setLabel(QObject::tr("Logical Channel Numbers required"));
130  setHelpText(
131  QObject::tr(
132  "If set, only services with a Logical Channel Number will "
133  "be added during the scan. This will filter out services "
134  "for set-top-box firmware download and video-on-demand "
135  "that can be present on DVB-C networks."));
136  };
137 };
138 
140 {
141  public:
143  {
144  setValue(true);
145  setLabel(QObject::tr("Complete scan data required"));
146  setHelpText(
147  QObject::tr(
148  "If set, only services that are present in the PAT, the PMT "
149  "and the SDT and that have a name will be added during the scan. "
150  "On satellites there are many incomplete channels, "
151  "such as feeds and offline channels, "
152  "that are not useful in a MythTV system. "
153  "These are filtered out by this option."));
154  };
155 };
156 
158 {
159  public:
161  {
162  setValue(false);
163  setLabel(QObject::tr("Full search for old channels"));
164  setHelpText(
165  QObject::tr(
166  "If set, compare all channels in the database with the channels found in "
167  "the scan; otherwise only the channels in the same transport are compared. "
168  "This option is useful when you want to keep channel data such as "
169  "the xmltvid and the icon path when doing a rescan "
170  "after channels have been rearranged across transports."));
171  };
172 };
173 
175 {
176  public:
178  {
179  setValue(false);
180  setLabel(QObject::tr("Add full Transport Stream channels"));
181  setHelpText(
182  QObject::tr(
183  "If set, Create MPTS channels, which allow "
184  "recording of the full, unaltered, transport stream."));
185  };
186 };
187 
189 {
190  public:
192  {
193  setLabel(QObject::tr("Test Decryptability"));
194  setHelpText(
195  QObject::tr("Test all channels to see if they can be decrypted "
196  "with installed CAM/smartcard. Sometimes the encrypted "
197  "flag is set spuriously. Attention: Enabling this "
198  "option increases the scan time for each encrypted "
199  "channel by a couple of seconds."));
200  }
201 };
202 
204 {
205  public:
207  {
208  setLabel(QObject::tr("Frequency"));
209  setHelpText(QObject::tr("Frequency (Option has no default)\n"
210  "The frequency for this channel in kHz."));
211  };
212 };
213 
215 {
216  public:
218  {
219  setLabel(QObject::tr("Frequency"));
220  setHelpText(QObject::tr("Frequency (Option has no default)\n"
221  "The frequency for this channel in Hz."));
222  };
223 };
224 
226 {
227  public:
229  {
230  setLabel(QObject::tr("Symbol Rate"));
231  setHelpText(
232  QObject::tr(
233  "Symbol Rate (symbols/second).\n"
234  "Most DVB-S transponders transmit at 27.5 "
235  "million symbols per second."));
236  addSelection("3333000");
237  addSelection("22000000");
238  addSelection("22500000");
239  addSelection("23000000");
240  addSelection("27500000", "27500000", true);
241  addSelection("28000000");
242  addSelection("28500000");
243  addSelection("29500000");
244  addSelection("29700000");
245  addSelection("29900000");
246  }
247 };
248 
250 {
251  public:
253  {
254  setLabel(QObject::tr("Symbol Rate"));
255  setHelpText(
256  QObject::tr(
257  "Symbol Rate (symbols/second).\n"
258  "Most DVB-C transports transmit at 6.9 or 6.875 "
259  "million symbols per second."));
260  addSelection("3450000");
261  addSelection("5000000");
262  addSelection("5900000");
263  addSelection("6875000");
264  addSelection("6900000", "6900000", true);
265  addSelection("6950000");
266  }
267 };
268 
270 {
271  public:
273  {
274  setLabel(QObject::tr("Polarity"));
275  setHelpText(QObject::tr("Polarity (Option has no default)"));
276  addSelection(QObject::tr("Horizontal"), "h",true);
277  addSelection(QObject::tr("Vertical"), "v");
278  addSelection(QObject::tr("Right Circular"), "r");
279  addSelection(QObject::tr("Left Circular"), "l");
280  };
281 };
282 
284 {
285  public:
287  {
288  setLabel(QObject::tr("Inversion"));
289  setHelpText(QObject::tr(
290  "Inversion (Default: Auto):\n"
291  "Most cards can autodetect this now, so "
292  "leave it at Auto unless it won't work."));
293  addSelection(QObject::tr("Auto"), "a",true);
294  addSelection(QObject::tr("On"), "1");
295  addSelection(QObject::tr("Off"), "0");
296  };
297 };
298 
300 {
301  public:
303  {
304  setLabel(QObject::tr("Bandwidth"));
305  setHelpText(QObject::tr("Bandwidth (Default: Auto)\n"));
306  addSelection(QObject::tr("Auto"),"a",true);
307  addSelection(QObject::tr("6 MHz"),"6");
308  addSelection(QObject::tr("7 MHz"),"7");
309  addSelection(QObject::tr("8 MHz"),"8");
310  };
311 };
312 
314 {
315  public:
317  {
318  addSelection(QObject::tr("Auto"),"auto",true);
319  addSelection(QObject::tr("None"),"none");
320  addSelection("1/2");
321  addSelection("2/3");
322  addSelection("3/4");
323  addSelection("4/5");
324  addSelection("5/6");
325  addSelection("6/7");
326  addSelection("7/8");
327  addSelection("8/9");
328  addSelection("3/5");
329  addSelection("9/10");
330  }
331 };
332 
333 class ScanFec: public ScanFecSetting
334 {
335  public:
337  {
338  setLabel(QObject::tr("FEC"));
339  setHelpText(QObject::tr(
340  "Forward Error Correction (Default: Auto)"));
341  }
342 };
343 
345 {
346  public:
348  {
349  setLabel(QObject::tr("LP Coderate"));
350  setHelpText(QObject::tr("Low Priority Code Rate (Default: Auto)"));
351  }
352 };
353 
355 {
356  public:
358  {
359  setLabel(QObject::tr("HP Coderate"));
360  setHelpText(QObject::tr("High Priority Code Rate (Default: Auto)"));
361  };
362 };
363 
365 {
366  public:
368  {
369  setLabel(QObject::tr("Guard Interval"));
370  setHelpText(QObject::tr("Guard Interval (Default: Auto)"));
371  addSelection(QObject::tr("Auto"),"auto");
372  addSelection("1/4");
373  addSelection("1/8");
374  addSelection("1/16");
375  addSelection("1/32");
376  };
377 };
378 
380 {
381  public:
383  {
384  setLabel(QObject::tr("Trans. Mode"));
385  setHelpText(QObject::tr("Transmission Mode (Default: Auto)"));
386  addSelection(QObject::tr("Auto"),"a");
387  addSelection("2K","2");
388  addSelection("8K","8");
389  };
390 };
391 
393 {
394  public:
396  {
397  setLabel(QObject::tr("Hierarchy"));
398  setHelpText(QObject::tr("Hierarchy (Default: Auto)"));
399  addSelection(QObject::tr("Auto"),"a");
400  addSelection(QObject::tr("None"), "n");
401  addSelection("1");
402  addSelection("2");
403  addSelection("4");
404  };
405 };
406 
408 {
409  public:
411  {
412  setLabel(QObject::tr("Mod Sys"));
413  setHelpText(QObject::tr("Modulation system (Default: DVB-S)"));
414  addSelection("DVB-S");
415  addSelection("DVB-S2");
416  };
417 };
418 
420 {
421  public:
423  {
424  setLabel(QObject::tr("Mod Sys"));
425  setHelpText(QObject::tr("Modulation system (Default: DVB-T)"));
426  addSelection("DVB-T");
427  addSelection("DVB-T2");
428  };
429 };
430 
432 {
433  public:
435  {
436  setLabel(QObject::tr("Roll-off"));
437  setHelpText(QObject::tr("Roll-off factor (Default: 0.35)"));
438  addSelection("0.35");
439  addSelection("0.20");
440  addSelection("0.25");
441  addSelection(QObject::tr("Auto"),"auto");
442  };
443 };
444 
445 class PaneError : public GroupSetting
446 {
447  public:
448  explicit PaneError(const QString &error)
449  {
451  label->setValue(error);
452  addChild(label);
453  }
454 };
455 
456 #endif // _MISC_SETTINGS_H_
VERBOSE_PREAMBLE Most true
Definition: verbosedefs.h:91
static void error(const char *str,...)
Definition: vbi.c:42
void addSelection(const QString &label, QString value=QString(), bool select=false)
virtual void setHelpText(const QString &str)
virtual QString getValue(void) const
virtual void setLabel(QString str)
PaneError(const QString &error)
virtual void addChild(StandardSetting *child)
ServiceRequirements
void setValue(const QString &) override
ServiceRequirements GetServiceRequirements(void) const
virtual void setValue(const QString &newValue)