summaryrefslogtreecommitdiffstats
path: root/src/fig/FIG2.cpp
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2019-02-13 10:30:59 +0100
committerMatthias P. Braendli <matthias.braendli@mpb.li>2019-02-13 10:30:59 +0100
commit8ff89e414770a922e45eee829b672aceb10ea609 (patch)
treeaccdab3630119096ce4f6361942a49152bd564b3 /src/fig/FIG2.cpp
parentfb6ab762301d5da6b0eb3293d19cf545c4caf6ad (diff)
downloaddabmux-8ff89e414770a922e45eee829b672aceb10ea609.tar.gz
dabmux-8ff89e414770a922e45eee829b672aceb10ea609.tar.bz2
dabmux-8ff89e414770a922e45eee829b672aceb10ea609.zip
Simplify and use isProgramme where possible
Diffstat (limited to 'src/fig/FIG2.cpp')
-rw-r--r--src/fig/FIG2.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/fig/FIG2.cpp b/src/fig/FIG2.cpp
index afa64eb..b88814c 100644
--- a/src/fig/FIG2.cpp
+++ b/src/fig/FIG2.cpp
@@ -202,8 +202,7 @@ FillStatus FIG2_1_and_5::fill(uint8_t *buf, size_t max_size)
// Rotate through the subchannels until there is no more space
while (service != ensemble->services.end()) {
- const bool is_programme = (*service)->getType(ensemble) == subchannel_type_t::DABAudio or
- ((*service)->getType(ensemble) == subchannel_type_t::DABPlusAudio);
+ const bool is_programme = (*service)->isProgramme(ensemble);
if (not (m_programme xor is_programme) and (*service)->label.has_fig2_label()) {
@@ -316,8 +315,7 @@ FillStatus FIG2_4::fill(uint8_t *buf, size_t max_size)
}
}
- const bool is_programme = (*service)->getType(ensemble) == subchannel_type_t::DABAudio or
- ((*service)->getType(ensemble) == subchannel_type_t::DABPlusAudio);
+ const bool is_programme = (*service)->isProgramme(ensemble);
const size_t id_length = is_programme ?
sizeof(FIGtype2_4_Programme_Identifier) :