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  setLabel(QObject::tr("Unencrypted Only"));
115  setHelpText(
116  QObject::tr(
117  "If set, only non-encrypted channels will be "
118  "added during the scan."));
119  setValue(true);
120  };
121 };
122 
124 {
125  public:
127  {
128  setLabel(QObject::tr("Logical Channel Numbers required"));
129  setHelpText(
130  QObject::tr(
131  "If set, only services with a Logical Channel Number will "
132  "be added during the scan. This will filter out services "
133  "for set-top-box firmware download and video-on-demand "
134  "that can be present on DVB-C networks."));
135  setValue(false);
136  };
137 };
138 
140 {
141  public:
143  {
144  setLabel(QObject::tr("Complete scan data required"));
145  setHelpText(
146  QObject::tr(
147  "If set, only services that are present in the PAT, the PMT "
148  "and the SDT and that have a name will be added during the scan. "
149  "On satellites there are many incomplete channels, "
150  "such as feeds and offline channels, "
151  "that are not useful in a MythTV system. "
152  "These are filtered out by this option."));
153  setValue(true);
154  };
155 };
156 
158 {
159  public:
161  {
162  setLabel(QObject::tr("Full search for old channels"));
163  setHelpText(
164  QObject::tr(
165  "If set, compare all channels in the database with the channels found in "
166  "the scan; otherwise only the channels in the same transport are compared. "
167  "This option is useful when you want to keep channel data such as "
168  "the xmltvid and the icon path when doing a rescan "
169  "after channels have been rearranged across transports."));
170  setValue(true);
171  };
172 };
173 
175 {
176  public:
178  {
179  setLabel(QObject::tr("Add full Transport Stream channels"));
180  setHelpText(
181  QObject::tr(
182  "If set, create MPTS channels, which allow "
183  "recording of the full, unaltered, transport stream."));
184  setValue(false);
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  setValue(false);
201  }
202 };
203 
205 {
206  public:
208  {
209  setLabel(QObject::tr("Frequency"));
210  setHelpText(QObject::tr("Frequency (Option has no default)\n"
211  "The frequency for this transport (multiplex) in kHz."));
212  };
213 };
214 
216 {
217  public:
219  {
220  setLabel(QObject::tr("Frequency"));
221  setHelpText(QObject::tr("Frequency (Option has no default)\n"
222  "The frequency for this transport (multiplex) in Hz."));
223  };
224 };
225 
227 {
228  public:
230  {
231  setLabel(QObject::tr("Symbol Rate"));
232  setHelpText(
233  QObject::tr(
234  "Symbol Rate (symbols/second).\n"
235  "Most DVB-S transponders transmit at 27.5 "
236  "million symbols per second."));
237  addSelection("3333000");
238  addSelection("22000000");
239  addSelection("22500000");
240  addSelection("23000000");
241  addSelection("27500000", "27500000", true);
242  addSelection("28000000");
243  addSelection("28500000");
244  addSelection("29500000");
245  addSelection("29700000");
246  addSelection("29900000");
247  }
248 };
249 
251 {
252  public:
254  {
255  setLabel(QObject::tr("Symbol Rate"));
256  setHelpText(
257  QObject::tr(
258  "Symbol Rate (symbols/second).\n"
259  "Most DVB-C transports transmit at 6.9 or 6.875 "
260  "million symbols per second."));
261  addSelection("3450000");
262  addSelection("5000000");
263  addSelection("5900000");
264  addSelection("6875000");
265  addSelection("6900000", "6900000", true);
266  addSelection("6950000");
267  }
268 };
269 
271 {
272  public:
274  {
275  setLabel(QObject::tr("Polarity"));
276  setHelpText(QObject::tr("Polarity (Option has no default)"));
277  addSelection(QObject::tr("Horizontal"), "h",true);
278  addSelection(QObject::tr("Vertical"), "v");
279  addSelection(QObject::tr("Right Circular"), "r");
280  addSelection(QObject::tr("Left Circular"), "l");
281  };
282 };
283 
285 {
286  public:
288  {
289  setLabel(QObject::tr("Inversion"));
290  setHelpText(QObject::tr(
291  "Inversion (Default: Auto):\n"
292  "Most cards can autodetect this now, so "
293  "leave it at Auto unless it won't work."));
294  addSelection(QObject::tr("Auto"), "a",true);
295  addSelection(QObject::tr("On"), "1");
296  addSelection(QObject::tr("Off"), "0");
297  };
298 };
299 
301 {
302  public:
304  {
305  setLabel(QObject::tr("Bandwidth"));
306  setHelpText(QObject::tr("Bandwidth (Default: Auto)\n"));
307  addSelection(QObject::tr("Auto"),"a",true);
308  addSelection(QObject::tr("6 MHz"),"6");
309  addSelection(QObject::tr("7 MHz"),"7");
310  addSelection(QObject::tr("8 MHz"),"8");
311  };
312 };
313 
315 {
316  public:
318  {
319  addSelection(QObject::tr("Auto"),"auto",true);
320  addSelection(QObject::tr("None"),"none");
321  addSelection("1/2");
322  addSelection("2/3");
323  addSelection("3/4");
324  addSelection("4/5");
325  addSelection("5/6");
326  addSelection("6/7");
327  addSelection("7/8");
328  addSelection("8/9");
329  addSelection("3/5");
330  addSelection("9/10");
331  }
332 };
333 
334 class ScanFec: public ScanFecSetting
335 {
336  public:
338  {
339  setLabel(QObject::tr("FEC"));
340  setHelpText(QObject::tr(
341  "Forward Error Correction (Default: Auto)"));
342  }
343 };
344 
346 {
347  public:
349  {
350  setLabel(QObject::tr("LP Coderate"));
351  setHelpText(QObject::tr("Low Priority Code Rate (Default: Auto)"));
352  }
353 };
354 
356 {
357  public:
359  {
360  setLabel(QObject::tr("HP Coderate"));
361  setHelpText(QObject::tr("High Priority Code Rate (Default: Auto)"));
362  };
363 };
364 
366 {
367  public:
369  {
370  setLabel(QObject::tr("Guard Interval"));
371  setHelpText(QObject::tr("Guard Interval (Default: Auto)"));
372  addSelection(QObject::tr("Auto"),"auto");
373  addSelection("1/4");
374  addSelection("1/8");
375  addSelection("1/16");
376  addSelection("1/32");
377  };
378 };
379 
381 {
382  public:
384  {
385  setLabel(QObject::tr("Trans. Mode"));
386  setHelpText(QObject::tr("Transmission Mode (Default: Auto)"));
387  addSelection(QObject::tr("Auto"),"a");
388  addSelection("2K","2");
389  addSelection("8K","8");
390  };
391 };
392 
394 {
395  public:
397  {
398  setLabel(QObject::tr("Hierarchy"));
399  setHelpText(QObject::tr("Hierarchy (Default: Auto)"));
400  addSelection(QObject::tr("Auto"),"a");
401  addSelection(QObject::tr("None"), "n");
402  addSelection("1");
403  addSelection("2");
404  addSelection("4");
405  };
406 };
407 
409 {
410  public:
412  {
413  setLabel(QObject::tr("Mod Sys"));
414  setHelpText(QObject::tr("Modulation system (Default: DVB-S)"));
415  addSelection("DVB-S");
416  addSelection("DVB-S2");
417  };
418 };
419 
421 {
422  public:
424  {
425  setLabel(QObject::tr("Mod Sys"));
426  setHelpText(QObject::tr("Modulation system (Default: DVB-T)"));
427  addSelection("DVB-T");
428  addSelection("DVB-T2");
429  };
430 };
431 
433 {
434  public:
436  {
437  setLabel(QObject::tr("Roll-off"));
438  setHelpText(QObject::tr("Roll-off factor (Default: 0.35)"));
439  addSelection("0.35");
440  addSelection("0.20");
441  addSelection("0.25");
442  addSelection(QObject::tr("Auto"),"auto");
443  };
444 };
445 
446 class PaneError : public GroupSetting
447 {
448  public:
449  explicit PaneError(const QString &error)
450  {
452  label->setValue(error);
453  addChild(label);
454  }
455 };
456 
457 #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)