Permalink
Browse files

Apply EITfixup NL to Dutch/Belgian DVB-S(2) channels

Fixes #11226
  • Loading branch information...
stuarta authored and jyavenard committed Feb 28, 2013
1 parent 72946d9 commit 338939b93e67e1c192463328357897b6fcd0ca1b
Showing with 30 additions and 2 deletions.
  1. +20 −1 mythtv/libs/libmythtv/eitfixup.cpp
  2. +1 −0 mythtv/libs/libmythtv/eitfixup.h
  3. +9 −1 mythtv/libs/libmythtv/eithelper.cpp
@@ -106,6 +106,7 @@ EITFixUp::EITFixUp()
m_nlRepeat("herh."),
m_nlHD("\\sHD$"),
m_nlSub("\\sAfl\\.:\\s([^\\.]+)\\."),
m_nlSub2("\\s\"([^\"]+)\""),
m_nlActors("\\sMet:\\s.+e\\.a\\."),
m_nlPres("\\sPresentatie:\\s([^\\.]+)\\."),
m_nlPersSeparator("(, |\\sen\\s)"),
@@ -1574,6 +1575,12 @@ void EITFixUp::FixNL(DBEventEIT &event) const
event.categoryType = kCategoryNone;
}
// Film - categories are usually not Films
if (event.category.startsWith("Film -"))
{
event.categoryType = kCategorySeries;
}
// Get stereo info
int position;
if ((position = fullinfo.indexOf(m_Stereo)) != -1)
@@ -1608,7 +1615,7 @@ void EITFixUp::FixNL(DBEventEIT &event) const
event.title = event.title.replace(m_nlHD, "");
}
// Try to make subtitle
// Try to make subtitle from Afl.:
QRegExp tmpSub = m_nlSub;
QString tmpSubString;
if (tmpSub.indexIn(fullinfo) != -1)
@@ -1619,6 +1626,18 @@ void EITFixUp::FixNL(DBEventEIT &event) const
fullinfo = fullinfo.replace(tmpSub.cap(0), "");
}
// Try to make subtitle from " "
QRegExp tmpSub2 = m_nlSub2;
//QString tmpSubString2;
if (tmpSub2.indexIn(fullinfo) != -1)
{
tmpSubString = tmpSub2.cap(0);
tmpSubString = tmpSubString.right(tmpSubString.length() - 2);
event.subtitle = tmpSubString.left(tmpSubString.length() -1);
fullinfo = fullinfo.replace(tmpSub2.cap(0), "");
}
// This is trying to catch the case where the subtitle is in the main title
// but avoid cases where it isn't a subtitle e.g cd:uk
if (((position = event.title.indexOf(":")) != -1) &&
@@ -183,6 +183,7 @@ class EITFixUp
const QRegExp m_nlRepeat;
const QRegExp m_nlHD;
const QRegExp m_nlSub;
const QRegExp m_nlSub2;
const QRegExp m_nlActors;
const QRegExp m_nlPres;
const QRegExp m_nlPersSeparator;
@@ -965,8 +965,16 @@ static void init_fixup(QMap<uint64_t,uint> &fix)
fix[ 6LL << 32 | 133 << 16 | 129] = EITFixUp::kFixHDTV;
fix[ 6LL << 32 | 133 << 16 | 130] = EITFixUp::kFixHDTV;
// Netherlands
// Netherlands DVB-C
fix[ 1000U << 16] = EITFixUp::kFixNL;
// Canal Digitaal DVB-S 19.2 Dutch/Belgian ONID 53 covers all CanalDigitaal TiD
fix[ 53U << 16] = EITFixUp::kFixNL;
// Canal Digitaal DVB-S 23.5 Dutch/Belgian
fix[ 3202LL << 32 | 3U << 16] = EITFixUp::kFixNL;
fix[ 3208LL << 32 | 3U << 16] = EITFixUp::kFixNL;
fix[ 3211LL << 32 | 3U << 16] = EITFixUp::kFixNL;
fix[ 3222LL << 32 | 3U << 16] = EITFixUp::kFixNL;
fix[ 3225LL << 32 | 3U << 16] = EITFixUp::kFixNL;
// Finland
fix[ 8438U << 16] = // DVB-T Espoo

0 comments on commit 338939b

Please sign in to comment.