5#include "libmythbase/mythconfig.h"
15 QString idTag(
":WHEREID");
16 QString query(
"id = " + idTag);
28 const QString& name) :
44 QString profileTag(
":SETPROFILE");
45 QString nameTag(
":SETNAME");
46 QString valueTag(
":SETVALUE");
48 QString query(
"profile = " + profileTag +
", name = " + nameTag
49 +
", value = " + valueTag);
60 QString profileTag(
":WHEREPROFILE");
61 QString nameTag(
":WHERENAME");
63 QString query(
"profile = " + profileTag +
" AND name = " + nameTag);
90 setLabel(QObject::tr(
"MP3 quality"));
92 setHelpText(QObject::tr(
"The higher the slider number, the lower the "
93 "quality of the audio. Better quality audio (lower "
94 "numbers) requires more CPU."));
105 setLabel(QObject::tr(
"Volume (%)"));
107 setHelpText(QObject::tr(
"Recording volume of the capture card."));
117 setLabel(QObject::tr(
"Sampling rate"));
118 setHelpText(QObject::tr(
"Sets the audio sampling rate for your DSP. "
119 "Ensure that you choose a sampling rate appropriate "
120 "for your device. btaudio may only allow 32000."));
127 for (
uint i = 0; analog && (i <
m_rates.size()); i++)
152 const QString value = QString(),
153 bool select =
false)
override
155 QString val = value.isEmpty() ? label : value;
156 uint rate = val.toUInt();
163 LOG(VB_GENERAL, LOG_ERR, QString(
"SampleRate: ") +
164 QString(
"Attempted to add a rate %1 Hz, which is "
165 "not in the list of allowed rates.").arg(rate));
177 bool layer1,
bool layer2,
bool layer3) :
190 uint allowed_cnt = 0;
195 if (1 == allowed_cnt)
268 setHelpText(QObject::tr(
"Sets the audio bitrate"));
296 setHelpText(QObject::tr(
"Sets the audio bitrate"));
324 setHelpText(QObject::tr(
"Sets the audio bitrate"));
336 setLabel(QObject::tr(
"Volume (%)"));
338 setHelpText(QObject::tr(
"Volume of the recording "));
346 bool layer1,
bool layer2,
bool layer3,
349 const std::array<const QString,3> layers {
"Layer I",
"Layer II",
"Layer III", };
351 setLabel(QObject::tr(
"Bitrate Settings"));
353 auto *audType =
new MPEG2audType(parent, layer1, layer2, layer3);
362 int which = audType->getValueIndex(layers[desired_layer]);
364 audType->setValue(which);
374 setLabel(QObject::tr(
"SAP/Bilingual"));
382 "Chooses the language(s) to record when "
383 "two languages are broadcast. Only Layer II "
384 "supports the recording of two languages (Dual)."
385 "Requires ivtv 0.4.0 or later."));
393 const QString& setting =
"mpeg2bitratemode") :
397 setLabel(QObject::tr(
"Bitrate Mode"));
414 setName(QObject::tr(
"Audio Quality"));
418 QString label(
"MP3");
423 label =
"MPEG-2 Hardware Encoder";
431 label =
"Uncompressed";
455 for (
const auto & option : std::as_const(
options))
459 for (
const auto & Imenu : std::as_const(option.m_menu))
461 if (!Imenu.isEmpty())
469 for (
const auto & option : std::as_const(
options))
476 else if (option.m_category ==
482 else if (option.m_category ==
494 for (
const auto & Imenu : std::as_const(option.m_menu))
496 if (Imenu.indexOf(
"Layer III") >= 0)
498 else if (Imenu.indexOf(
"Layer II") >= 0)
500 else if (Imenu.indexOf(
"Layer I") >= 0)
504 if (layer1 || layer2 || layer3)
527 if (!groupType.isNull())
529 if (groupType ==
"MPEG")
533 else if (groupType ==
"HDPVR")
538 else if (groupType.startsWith(
"V4L2:"))
582 setLabel(QObject::tr(
"RTjpeg Quality"));
584 setHelpText(QObject::tr(
"Higher is better quality."));
595 setLabel(QObject::tr(
"Luma filter"));
608 setLabel(QObject::tr(
"Chroma filter"));
621 setLabel(QObject::tr(
"Bitrate (kb/s)"));
623 setHelpText(QObject::tr(
"Bitrate in kilobits/second. As a guide, "
624 "2200 kb/s is approximately 1 GB/hr."));
635 setLabel(QObject::tr(
"Scale bitrate for frame size"));
637 setHelpText(QObject::tr(
"If set, the bitrate specified will be used "
638 "for 640x480. If other resolutions are used, the "
639 "bitrate will be scaled appropriately."));
650 setLabel(QObject::tr(
"Minimum quality"));
652 setHelpText(QObject::tr(
"Modifying the default may have severe "
664 setLabel(QObject::tr(
"Maximum quality"));
666 setHelpText(QObject::tr(
"Modifying the default may have severe "
679 setLabel(QObject::tr(
"Max quality difference between frames"));
681 setHelpText(QObject::tr(
"Modifying the default may have severe "
693 setLabel(QObject::tr(
"Enable interlaced DCT encoding"));
695 setHelpText(QObject::tr(
"If set, the MPEG4 encoder will use "
696 "interlaced DCT encoding. You may want this when encoding "
697 "interlaced video; however, this is experimental and may "
698 "cause damaged video."));
709 setLabel(QObject::tr(
"Enable interlaced motion estimation"));
711 setHelpText(QObject::tr(
"If set, the MPEG4 encoder will use "
712 "interlaced motion estimation. You may want this when "
713 "encoding interlaced video; however, this is experimental "
714 "and may cause damaged video."));
725 setLabel(QObject::tr(
"Enable high-quality encoding"));
727 setHelpText(QObject::tr(
"If set, the MPEG4 encoder will use "
728 "'high-quality' encoding options. This requires much "
729 "more processing, but can result in better video."));
740 setLabel(QObject::tr(
"Enable 4MV encoding"));
742 setHelpText(QObject::tr(
"If set, the MPEG4 encoder will use '4MV' "
743 "motion-vector encoding. This requires "
744 "much more processing, but can result in better "
745 "video. It is highly recommended that the HQ option is "
746 "enabled if 4MV is enabled."));
758 setLabel(QObject::tr(
"Number of threads"));
761 QObject::tr(
"Threads to use for software encoding.") +
" " +
762 QObject::tr(
"Set to a value less than or equal to the "
763 "number of processors on the backend that "
764 "will be doing the encoding."));
772 const QString& setting =
"mpeg2bitrate",
773 uint min_br = 1000,
uint max_br = 16000,
774 uint default_br = 4500,
uint increment = 100,
775 QString label = QString()) :
780 label = QObject::tr(
"Avg. Bitrate (kb/s)");
784 "Average bitrate in kilobits/second. As a guide, "
785 "2200 kb/s is approximately 1 GB/hour."));
793 const QString& setting =
"mpeg2maxbitrate",
794 uint min_br = 1000,
uint max_br = 16000,
795 uint default_br = 6000,
uint increment = 100,
796 QString label = QString()) :
801 label = QObject::tr(
"Max. Bitrate (kb/s)");
804 setHelpText(QObject::tr(
"Maximum bitrate in kilobits/second. "
805 "As a guide, 2200 kb/s is approximately 1 GB/hour."));
817 maxopt = std::min<uint>(maxopt, 8);
819 setLabel(QObject::tr(
"Stream Type"));
821 const std::array<const QString,9>
options {
"MPEG-2 PS",
"MPEG-2 TS",
822 "MPEG-1 VCD",
"PES AV",
824 "DVD",
"DVD-Special 1",
"DVD-Special 2" };
826 for (
uint idx = minopt; idx <= maxopt; ++idx)
830 setHelpText(QObject::tr(
"Sets the type of stream generated by "
843 maxopt = std::min<uint>(maxopt, 3);
845 setLabel(QObject::tr(
"Aspect Ratio"));
847 const std::array<const QString,4>
options { QObject::tr(
"Square"),
"4:3",
850 for (
uint idx = minopt; idx <= maxopt; ++idx)
854 setHelpText(QObject::tr(
"Sets the aspect ratio of stream generated "
879 setLabel(QObject::tr(
"Horizontal Decimation"));
894 setLabel(QObject::tr(
"Vertical Decimation"));
910 setName(QObject::tr(
"Video Compression"));
914 QString label(
"RTjpeg");
943 label =
"Hardware MJPEG";
948 label =
"MPEG-2 Hardware Encoder";
954 label =
"MPEG-4 AVC Hardware Encoder";
956 h0->setLabel(QObject::tr(
"Low Resolution"));
958 1000, 13500, 4500, 500));
960 1100, 20200, 6000, 500));
964 h1->setLabel(QObject::tr(
"Medium Resolution"));
966 1000, 13500, 9000, 500));
968 1100, 20200, 11000, 500));
972 h2->setLabel(QObject::tr(
"High Resolution"));
974 1000, 13500, 13500, 500));
976 1100, 20200, 20200, 500));
990 for (
const auto & option : std::as_const(
options))
994 for (
const auto & Imenu : std::as_const(option.m_menu))
996 if (!Imenu.isEmpty())
1007 bool dynamic_res = !v4l2->UserAdjustableResolution();
1017 option.m_defaultValue));
1025 option.m_defaultValue));
1027 else if (option.m_category ==
1033 "low_mpegbitratemode"));
1035 "medium_mpegbitratemode"));
1037 "medium_mpegbitratemode"));
1048 bit_low->setLabel(QObject::tr(
"Low Resolution"));
1050 "low_mpegavgbitrate",
1051 option.m_minimum / 1000,
1052 option.m_maximum / 1000,
1053 option.m_defaultValue / 1000,
1054 option.m_step / 1000));
1056 bit_medium->setLabel(QObject::
1057 tr(
"Medium Resolution"));
1059 "medium_mpegavgbitrate",
1060 option.m_minimum / 1000,
1061 option.m_maximum / 1000,
1062 option.m_defaultValue / 1000,
1063 option.m_step / 1000));
1065 bit_high->setLabel(QObject::
1066 tr(
"High Resolution"));
1068 "high_mpegavgbitrate",
1069 option.m_minimum / 1000,
1070 option.m_maximum / 1000,
1071 option.m_defaultValue / 1000,
1072 option.m_step / 1000));
1076 bit_low->setLabel(QObject::tr(
"Bitrate"));
1079 option.m_minimum / 1000,
1080 option.m_maximum / 1000,
1081 option.m_defaultValue / 1000,
1082 option.m_step / 1000));
1085 else if (option.m_category ==
1091 "low_mpegpeakbitrate",
1092 option.m_minimum / 1000,
1093 option.m_maximum / 1000,
1094 option.m_defaultValue / 1000,
1095 option.m_step / 1000));
1097 "medium_mpegpeakbitrate",
1098 option.m_minimum / 1000,
1099 option.m_maximum / 1000,
1100 option.m_defaultValue / 1000,
1101 option.m_step / 1000));
1103 "high_mpegpeakbitrate",
1104 option.m_minimum / 1000,
1105 option.m_maximum / 1000,
1106 option.m_defaultValue / 1000,
1107 option.m_step / 1000));
1113 option.m_minimum / 1000,
1114 option.m_maximum / 1000,
1115 option.m_defaultValue / 1000,
1116 option.m_step / 1000));
1141 if (!groupType.isNull())
1143 if (groupType ==
"HDPVR")
1147 else if (groupType.startsWith(
"V4L2:"))
1152 else if (groupType ==
"MPEG")
1156 else if (groupType ==
"MJPEG")
1160 else if (groupType ==
"GO7007")
1194 setLabel(QObject::tr(
"Enable auto-transcode after recording"));
1196 setHelpText(QObject::tr(
"Automatically transcode when a recording is "
1197 "made using this profile and the recording's "
1198 "schedule is configured to allow transcoding."));
1209 setLabel(QObject::tr(
"Resize video while transcoding"));
1211 setHelpText(QObject::tr(
"Allows the transcoder to "
1212 "resize the video during transcoding."));
1223 setLabel(QObject::tr(
"Lossless transcoding"));
1225 setHelpText(QObject::tr(
"Only reencode where absolutely needed "
1226 "(normally only around cutpoints). Otherwise "
1227 "keep audio and video formats identical to "
1228 "the source. This should result in the "
1229 "highest quality, but won't save as much "
1240 setLabel(QObject::tr(
"Recording Type"));
1242 QString msg = QObject::tr(
1243 "This option allows you to filter out unwanted streams. "
1244 "'Normal' will record all relevant streams including "
1245 "interactive television data. 'TV Only' will record only "
1246 "audio, video and subtitle streams. ");
1262 setLabel(QObject::tr(
"Record Full TS?"));
1264 QString msg = QObject::tr(
1265 "If set, extra files will be created for each recording with "
1266 "the name of the recording followed by '.ts.raw'. "
1267 "These extra files represent the full contents of the transport "
1268 "stream used to generate the recording. (For debugging purposes)");
1284 setLabel(QObject::tr(
"Custom filters"));
1285 setHelpText(QObject::tr(
"Filters used when transcoding with this "
1286 "profile. This value must be blank to perform "
1287 "lossless transcoding. Format: "
1288 "[[<filter>=<options>,]...]"
1301 bool transcoding =
false) :
1304 transcoding ? QObject::tr(
"Auto") : QString()),
1310 QString
help = transcoding ?
1311 QObject::tr(
"If the width is set to 'Auto', the width "
1312 "will be calculated based on the height and "
1313 "the recording's physical aspect ratio.") :
1314 QObject::tr(
"Width to use for encoding. "
1315 "Note: PVR-x50 cards may produce ghosting if "
1316 "this is not set to 720 or 768 for NTSC and "
1317 "PAL, respectively.");
1327 uint defaultheight,
uint maxheight,
1328 bool transcoding =
false):
1331 transcoding ? QObject::tr(
"Auto") : QString()),
1337 QString
help = transcoding ?
1338 QObject::tr(
"If the height is set to 'Auto', the height "
1339 "will be calculated based on the width and "
1340 "the recording's physical aspect ratio.") :
1341 QObject::tr(
"Height to use for encoding. "
1342 "Note: PVR-x50 cards may produce ghosting if "
1343 "this is not set to 480 or 576 for NTSC and "
1344 "PAL, respectively.");
1351 const QString& tvFormat,
const QString& profName)
1353 setLabel(QObject::tr(
"Image size"));
1355 QSize defaultsize(768, 576);
1356 QSize maxsize(768, 576);
1357 bool transcoding = profName.startsWith(
"Transcoders");
1358 bool ivtv = profName.startsWith(
"IVTV MPEG-2 Encoders");
1362 maxsize = QSize(1920, 1088);
1363 if (tvFormat.toLower() ==
"ntsc" || tvFormat.toLower() ==
"atsc")
1364 defaultsize = QSize(480, 480);
1366 defaultsize = QSize(480, 576);
1368 else if (tvFormat.startsWith(
"ntsc", Qt::CaseInsensitive))
1370 maxsize = QSize(720, 480);
1371 defaultsize = ivtv ? QSize(720, 480) : QSize(480, 480);
1373 else if (tvFormat.toLower() ==
"atsc")
1375 maxsize = QSize(1920, 1088);
1376 defaultsize = QSize(1920, 1088);
1380 maxsize = QSize(768, 576);
1381 defaultsize = ivtv ? QSize(720, 576) : QSize(480, 576);
1385 maxsize.width(), transcoding));
1387 maxsize.height(), transcoding));
1394 m_name(new
Name(*this)),
1395 m_profileName(profName)
1403 if (!profName.isEmpty())
1405 if (profName.startsWith(
"Transcoders"))
1462 "SELECT cardtype, profilegroups.name "
1463 "FROM profilegroups, recordingprofiles "
1464 "WHERE profilegroups.id = recordingprofiles.profilegroup AND "
1465 " recordingprofiles.id = :PROFILEID");
1466 result.
bindValue(
":PROFILEID", profileId);
1474 else if (result.
next())
1477 name = result.
value(1).toString();
1486 if (!val.trimmed().isEmpty())
1498 [[maybe_unused]]
const QString &videodev)
1504 QString cardtype = card;
1505 if (cardtype ==
"V4L2ENC")
1512 const QString& cardtype = card;
1517 "SELECT recordingprofiles.id, profilegroups.hostname, "
1518 " profilegroups.is_default "
1519 "FROM recordingprofiles, profilegroups "
1520 "WHERE profilegroups.id = recordingprofiles.profilegroup AND "
1521 " profilegroups.cardtype = :CARDTYPE AND "
1522 " recordingprofiles.name = :NAME");
1523 result.
bindValue(
":CARDTYPE", cardtype);
1532 while (result.
next())
1536 profileId = result.
value(0).toUInt();
1538 else if (result.
value(2).toInt() == 1)
1540 profileId = result.
value(0).toUInt();
1558 "SELECT recordingprofiles.id, cardtype "
1559 "FROM recordingprofiles, profilegroups "
1560 "WHERE recordingprofiles.profilegroup = profilegroups.id AND "
1561 " profilegroups.name = :GROUPNAME AND "
1562 " recordingprofiles.name = :NAME");
1574 uint profileId = result.
value(0).toUInt();
1575 QString
type = result.
value(1).toString();
1585 const QString &name)
1595 if (
type.startsWith(
"V4L2:"))
1598 if (!devices.isEmpty())
1600 for (
const auto & device : std::as_const(devices))
1616 if (
type !=
"HDPVR" &&
1668 m_group(id), m_labelName(std::move(profName))
1688 tr(
"Enter the name of the new profile"));
1690 if (settingdialog->Create())
1698 delete settingdialog;
1706 "INSERT INTO recordingprofiles "
1707 "(name, videocodec, audiocodec, profilegroup) "
1709 "(:NAME, :VIDEOCODEC, :AUDIOCODEC, :PROFILEGROUP);");
1711 query.
bindValue(
":VIDEOCODEC",
"MPEG-4");
1722 "FROM recordingprofiles "
1723 "WHERE name = :NAME AND profilegroup = :PROFILEGROUP;");
1746 bool foldautodetect)
1762 "FROM recordingprofiles "
1763 "WHERE profilegroup = :GROUP "
1773 while (result.
next())
1775 if ((result.
at() == 0) && foldautodetect &&
1779 autodetect->setLabel(QObject::tr(
"Autodetect"));
1783 QString name = result.
value(0).toString();
1784 QString
id = result.
value(1).toString();
1787 (name ==
"RTjpeg/MPEG4" || name ==
"MPEG2") &&
1789 name = QObject::tr(
"Autodetect from %1").arg(name);
1793 profile->loadByID(
id.toInt());
1801 QMap<int, QString> profiles;
1813 "FROM recordingprofiles "
1814 "WHERE profilegroup = :GROUPID "
1824 while (query.
next())
1829 profiles[id] = QObject::tr(
"Transcode using Autodetect");
1832 QString name = query.
value(0).toString();
1833 int id = query.
value(1).toInt();
1838 if (name !=
"RTjpeg/MPEG4" && name !=
"MPEG2")
1840 QString lbl = QObject::tr(
"Transcode using \"%1\"").arg(name);
1846 QString lbl = QObject::tr(
"Record using the \"%1\" profile").arg(name);
1850 if (query.
at() == QSql::BeforeFirstRow)
1852 LOG(VB_GENERAL, LOG_WARNING,
1853 "RecordingProfile::fillselections, Warning: "
1854 "Failed to locate recording id for recording group.");
1869 "SELECT profilegroups.cardtype "
1870 "FROM profilegroups, recordingprofiles "
1871 "WHERE profilegroups.id = recordingprofiles.profilegroup AND "
1872 " recordingprofiles.id = :ID");
1877 else if (result.
next())
1878 return result.
value(0).toString();
1888 "FROM recordingprofiles "
1895 else if (result.
next())
1896 return result.
value(0).toString();
1911 "FROM recordingprofiles "
AudioCodecName(const RecordingProfile &parent)
AudioCodecName * m_codecName
const RecordingProfile & m_parent
void selectCodecs(const QString &groupType)
AudioCompressionSettings(const RecordingProfile &parentProfile, V4L2util *v4l2)
AutoTranscode(const RecordingProfile &parent)
AverageBitrate(const RecordingProfile &parent, const QString &setting="mpeg2bitrate", uint min_br=1000, uint max_br=16000, uint default_br=4500, uint increment=100, QString label=QString())
BTTVVolume(const RecordingProfile &parent)
BitrateMode(const RecordingProfile &parent, const QString &setting="mpeg2bitratemode")
static bool IsTunerSharingCapable(const QString &rawtype)
static QStringList GetVideoDevices(const QString &rawtype, QString hostname=QString())
Returns the videodevices of the matching inputs, duplicates removed.
static bool IsEITCapable(const QString &rawtype)
static bool IsEncoder(const QString &rawtype)
const RecordingProfile & m_parent
QString GetSetClause(MSqlBindings &bindings) const override
QString GetWhereClause(MSqlBindings &bindings) const override
CodecParamStorage(StandardSetting *_setting, const RecordingProfile &parentProfile, const QString &name)
EncodingThreadCount(const RecordingProfile &parent)
HardwareMJPEGHDecimation(const RecordingProfile &parent)
HardwareMJPEGQuality(const RecordingProfile &parent)
HardwareMJPEGVDecimation(const RecordingProfile &parent)
Height(const RecordingProfile &parent, uint defaultheight, uint maxheight, bool transcoding=false)
Width(const RecordingProfile &parent, uint defaultwidth, uint maxwidth, bool transcoding=false)
ImageSize(const RecordingProfile &parent, const QString &tvFormat, const QString &profName)
MP3Quality(const RecordingProfile &parent)
MPEG2AudioBitrateSettings(const RecordingProfile &parent, bool layer1, bool layer2, bool layer3, uint default_layer)
MPEG2Language(const RecordingProfile &parent)
MPEG2aspectRatio(const RecordingProfile &parent, uint minopt=0, uint maxopt=8, uint defopt=0)
MPEG2audBitrateL1(const RecordingProfile &parent)
MPEG2audBitrateL2(const RecordingProfile &parent)
MPEG2audBitrateL3(const RecordingProfile &parent)
MPEG2audType(const RecordingProfile &parent, bool layer1, bool layer2, bool layer3)
MPEG2audVolume(const RecordingProfile &parent)
MPEG2streamType(const RecordingProfile &parent, uint minopt=0, uint maxopt=8, uint defopt=0)
MPEG4MaxQuality(const RecordingProfile &parent)
MPEG4MinQuality(const RecordingProfile &parent)
MPEG4Option4MV(const RecordingProfile &parent)
MPEG4OptionIDCT(const RecordingProfile &parent)
MPEG4OptionIME(const RecordingProfile &parent)
MPEG4OptionVHQ(const RecordingProfile &parent)
MPEG4QualDiff(const RecordingProfile &parent)
MPEG4bitrate(const RecordingProfile &parent)
QSqlQuery wrapper that fetches a DB connection from the connection pool.
bool prepare(const QString &query)
QSqlQuery::prepare() is not thread safe in Qt <= 3.3.2.
QVariant value(int i) const
bool exec(void)
Wrap QSqlQuery::exec() so we can display SQL.
void bindValue(const QString &placeholder, const QVariant &val)
Add a single binding.
bool next(void)
Wrap QSqlQuery::next() so we can display the query results.
static MSqlQueryInfo InitCon(ConnectionReuse _reuse=kNormalConnection)
Only use this in combination with MSqlQuery constructor.
QString GetHostName(void)
QString GetSetting(const QString &key, const QString &defaultval="")
static void DBError(const QString &where, const MSqlQuery &query)
MythScreenStack * GetStack(const QString &Stackname)
virtual void AddScreen(MythScreenType *screen, bool allowFade=true)
Dialog prompting the user to enter a text string.
void setValue(const QString &newValue) override
virtual void addSelection(const QString &label, QString value=QString(), bool select=false)
void setValue(int value) override
int getValueIndex(const QString &value) const
PeakBitrate(const RecordingProfile &parent, const QString &setting="mpeg2maxbitrate", uint min_br=1000, uint max_br=16000, uint default_br=6000, uint increment=100, QString label=QString())
RTjpegChromaFilter(const RecordingProfile &parent)
RTjpegLumaFilter(const RecordingProfile &parent)
RTjpegQuality(const RecordingProfile &parent)
RecordFullTSStream(const RecordingProfile &parent)
void CreateNewProfile(const QString &profName)
void ShowNewProfileDialog() const
RecordingProfileEditor(int id, QString profName)
QString GetWhereClause(MSqlBindings &bindings) const override
const RecordingProfile & m_parent
~RecordingProfile(void) override
int getProfileNum(void) const
static const uint kTranscoderAutodetect
sentinel value
void FiltersChanged(const QString &val)
QString getName(void) const
RecordingProfile(const QString &profName=QString())
TranscodeResize * m_trResize
bool canDelete(void) override
void SetLosslessTranscode(const QString &val)
virtual void CompleteLoad(int profileId, const QString &type, const QString &name)
static QMap< int, QString > GetTranscodingProfiles()
virtual bool loadByType(const QString &name, const QString &cardtype, const QString &videodev)
TranscodeFilters * m_trFilters
static QMap< int, QString > GetProfiles(RecProfileGroup group=AllGroups)
static void fillSelections(GroupSetting *setting, int group, bool foldautodetect=false)
void ResizeTranscode(const QString &val)
TranscodeLossless * m_trLossless
VideoCompressionSettings * m_videoSettings
virtual void loadByID(int id)
QString groupType(void) const
AudioCompressionSettings * m_audioSettings
virtual bool loadByGroup(const QString &name, const QString &group)
void deleteEntry(void) override
RecordingTypeStream(const RecordingProfile &parent)
QMap< uint, bool > m_allowedRate
SampleRate(const RecordingProfile &parent, bool analog=true)
void addSelection(const QString &label, const QString value=QString(), bool select=false) override
std::vector< uint > m_rates
ScaleBitrate(const RecordingProfile &parent)
virtual void addChild(StandardSetting *child)
virtual void setName(const QString &name)
void addTargetedChild(const QString &value, StandardSetting *setting)
virtual void clearSettings()
void settingsChanged(StandardSetting *selectedSetting=nullptr)
virtual void setHelpText(const QString &str)
virtual void setValue(const QString &newValue)
void valueChanged(const QString &newValue)
virtual QString getValue(void) const
virtual void setEnabled(bool enabled)
virtual void setLabel(QString str)
virtual QString GetDBValue(void) const =0
TranscodeFilters(const RecordingProfile &parent)
TranscodeLossless(const RecordingProfile &parent)
TranscodeResize(const RecordingProfile &parent)
bool UserAdjustableResolution(void) const
QString DriverName(void) const
QString ProfileName(void) const
VideoCodecName(const RecordingProfile &parent)
VideoCompressionSettings(const RecordingProfile &parentProfile, V4L2util *v4l2)
VideoCodecName * m_codecName
void selectCodecs(const QString &groupType)
const RecordingProfile & m_parent
MythCoreContext * gCoreContext
This global variable contains the MythCoreContext instance for the app.
QMap< QString, QVariant > MSqlBindings
typedef for a map of string -> string bindings for generic queries.
#define LOG(_MASK_, _LEVEL_, _QSTRING_)
MythMainWindow * GetMythMainWindow(void)
static eu8 clamp(eu8 value, eu8 low, eu8 high)
const std::array< QString, 4 > kAvailProfiles
QMap< category_t, DriverOption > Options