@@ -23,6 +23,7 @@ import { DBSegment } from '@sofie-automation/corelib/dist/dataModel/Segment'
2323import { SegmentHandler } from '../collections/segmentHandler'
2424import { SegmentsHandler } from '../collections/segmentsHandler'
2525import { normalizeArray } from '@sofie-automation/corelib/dist/lib'
26+ import { PlaylistTimingType } from '@sofie-automation/blueprints-integration'
2627
2728const THROTTLE_PERIOD_MS = 100
2829
@@ -68,6 +69,13 @@ export interface ActivePlaylistStatus {
6869 nextPart : PartStatus | null
6970 quickLoop : ActivePlaylistQuickLoopStatus | undefined
7071 publicData : unknown
72+ timing : {
73+ timingMode : PlaylistTimingType
74+ startedPlayback ?: number
75+ expectedStart ?: number
76+ expectedDuration ?: number
77+ expectedEnd ?: number
78+ }
7179}
7280
7381export class ActivePlaylistTopic
@@ -170,6 +178,19 @@ export class ActivePlaylistTopic
170178 : null ,
171179 quickLoop : this . transformQuickLoopStatus ( ) ,
172180 publicData : this . _activePlaylist . publicData ,
181+ timing : {
182+ timingMode : this . _activePlaylist . timing . type ,
183+ startedPlayback : this . _activePlaylist . startedPlayback ,
184+ expectedDuration : this . _activePlaylist . timing . expectedDuration ,
185+ expectedStart :
186+ this . _activePlaylist . timing . type !== PlaylistTimingType . None
187+ ? this . _activePlaylist . timing . expectedStart
188+ : undefined ,
189+ expectedEnd :
190+ this . _activePlaylist . timing . type !== PlaylistTimingType . None
191+ ? this . _activePlaylist . timing . expectedEnd
192+ : undefined ,
193+ } ,
173194 } )
174195 : literal < ActivePlaylistStatus > ( {
175196 event : 'activePlaylist' ,
@@ -181,6 +202,9 @@ export class ActivePlaylistTopic
181202 nextPart : null ,
182203 quickLoop : undefined ,
183204 publicData : undefined ,
205+ timing : {
206+ timingMode : PlaylistTimingType . None ,
207+ } ,
184208 } )
185209
186210 this . sendMessage ( subscribers , message )
0 commit comments