Skip to main content

clarification TSB Media position changes

Please note these forums are being decommissioned and use the new and improved forums at
2 replies [Last post]
Joined: 2009-05-06

Consider the following 2 use cases below. What should the expected behavior and is RI compliant with that behavior?

Use case 1:
- Service is selected with 60 minute Timeshift buffer enabled and started.
- 30 minutes content is available in the TSB
- Rewind at the beginning of content
- As soon as we get Beginning Of Content and rate is changed to 1.0 : Press Pause (DVR is paused @ or very near the start of TSB)
- Jump backwards 10 minutes.

Use case 2: Same as Use case 1, but the Service has been presenting for more than 60 minutes (i.e the TSB has "wrapped" around)

I would like to know if in this case DVR start playing back from the beginning of the buffer (issuing BeginningOfBuffer and changing rate to 1.0) or
if SetMediaTime is considered invalid and results in a no-op


Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2009-02-02

A call to setMediaTime always results in a MediaTimeSetEvent. However, it may also result in a BeginningOfContentEvent or EndOfContentEvent if the requested mediatime is outside of the boundaries of the available TSBs.
In use case #1, the pause will result in a RateChangeEvent with a rate of 0.0 and the jump backward 10 minutes will result in a BeginningOfContentEvent (a RateChangeEvent) with a rate of 1.0 as well as a MediaTimeSetEvent, as the requested mediatime is before the start of available TSB content.
In use case #2, if there is a big enough delay between the setRate(0) and setmediatime calls, you will get a BeginningOfContentEvent with a rate of 1.0 due to encountering the start of the TSB while paused. If there is very little delay between the setRate(0) and setmediatime calls, you won't encounter the beginning of TSB while paused. The setMediatime call will always result in a BeginningOfContentEvent with a rate of 1.0 as well as a MediaTimeSetEvent with a mediatime representing the start mediatime of the first TSB .
The TSB impementation may or may not "wrap" when the minimum duration is exceeded. My description of use case #2 assumes the TSB is wrapping. If it does not wrap in use case #2, the behavior will be the same as use case #1.
The RI does implement this behavior, but during inspection I did find an issue in the start-of-TSB handling that will not result in a BeginningOfContentEvent if the current rate is greater than zero (this issue should only be encountered when play rate is near the start of TSB and rate is non-zero but less than one). I will file a Jira issue and resolve this bug.

Joined: 2009-02-02

Fix committed to svn trunk in revision 13302. The RI platform TSB implementation should support TSB wrapping, but it is not currently working - I've filed a Jira issue tracking that.
Commit msg:
OCORI-2773,RISK-low:BeginningOfContentEvent not generated when TSB is wrapped and rate is greater
than zero
- Removed no-opping guards in TSBServicePresentation handleEndOfFile and handleStartOfFile

Smoke tests pass, ran tune test, dvrexerciser scenarios