@@ -49,7 +49,7 @@ DecoderAdapter::DecoderAdapter(ProgrammeHandlerInterface &mr, int16_t bitRate, A
4949 }
5050
5151 // MOT, start of X-PAD data group, see EN 301 234
52- padDecoder.SetMOTAppType (12 );
52+ padDecoder.SetMOTAppType (X_PADAppType_MOT_StartOfX );
5353}
5454
5555void DecoderAdapter::addtoFrame (uint8_t *v)
@@ -140,19 +140,64 @@ void DecoderAdapter::FECInfo(int total_corr_count, bool uncorr_errors)
140140 myInterface.onRsErrors (uncorr_errors, total_corr_count);
141141}
142142
143- void DecoderAdapter::PADChangeDynamicLabel (const DL_STATE &dl)
143+ void DecoderAdapter::PADChangeDynamicLabel (const CDynamicLabel &dl)
144144{
145145 using charsets::CharacterSet;
146146
147+ #if 1
148+ fprintf (stderr, " _____________________________________________________\n " );
149+ fprintf (stderr, " Dynamic Label: %s\n " , dl.m_dynamicLabel .c_str ());
150+ if (!dl.m_playItems .empty ())
151+ {
152+ fprintf (stderr, " Playback:\n " );
153+ for (const auto & item : dl.m_playItems )
154+ {
155+ fprintf (stderr, " - %s: '%s'\n " , CDynamicLabel::DLPlusContentTypes[item.first ].name , item.second .c_str ());
156+ }
157+ }
158+
159+ if (!dl.m_infoItems .empty ())
160+ {
161+ fprintf (stderr, " Infos:\n " );
162+ for (const auto & item : dl.m_infoItems )
163+ {
164+ fprintf (stderr, " - %s: '%s'\n " , CDynamicLabel::DLPlusContentTypes[item.first ].name , item.second .c_str ());
165+ }
166+ }
167+
168+ if (!dl.m_programmeItems .empty ())
169+ {
170+ fprintf (stderr, " Programm:\n " );
171+ for (const auto & item : dl.m_programmeItems )
172+ {
173+ fprintf (stderr, " - %s: '%s'\n " , CDynamicLabel::DLPlusContentTypes[item.first ].name , item.second .c_str ());
174+ }
175+ }
176+
177+ if (!dl.m_interactivityItems .empty ())
178+ {
179+ fprintf (stderr, " Interactivity:\n " );
180+ for (const auto & item : dl.m_interactivityItems )
181+ {
182+ fprintf (stderr, " - %s: '%s'\n " , CDynamicLabel::DLPlusContentTypes[item.first ].name , item.second .c_str ());
183+ }
184+ }
185+
186+ if (!dl.m_descriptorItems .empty ())
187+ {
188+ fprintf (stderr, " Descriptor:\n " );
189+ for (const auto & item : dl.m_descriptorItems )
190+ {
191+ fprintf (stderr, " - %s: '%s'\n " , CDynamicLabel::DLPlusContentTypes[item.first ].name , item.second .c_str ());
192+ }
193+ }
194+ #endif
195+
147196 if (dl.raw .empty ()) {
148197 myInterface.onNewDynamicLabel (" " );
149198 }
150199 else {
151- myInterface.onNewDynamicLabel (
152- charsets::toUtf8 (
153- dl.raw .data (),
154- (CharacterSet)dl.charset ,
155- dl.raw .size ()));
200+ myInterface.onNewDynamicLabel (dl.m_dynamicLabel );
156201 }
157202}
158203
0 commit comments