Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The first second of a VOD asset was not played on Shaka player #338

Closed
hoimingw opened this issue Apr 15, 2016 · 13 comments
Closed

The first second of a VOD asset was not played on Shaka player #338

hoimingw opened this issue Apr 15, 2016 · 13 comments
Labels
status: archived Archived and locked; will not be updated type: bug Something isn't working correctly type: external An issue with an external dependency; not our issue; sometimes kept open for tracking zzz-outdated: Chrome PTS/DTS bug Related to the Chrome PTS/DTS bugs that were present from 2016 - 2019; do not use for new issues
Milestone

Comments

@hoimingw
Copy link

We tested a VOD asset on Shaka player, and found that the first second of video was not played. i.e. The playback was started from the 2nd second. After investigation, it was caused by the incorrect value of video.currentTime assigned by Shaka player.

MPD information:
<AdaptationSet mimeType="video/mp4" startWithSAP="1" segmentAlignment="true"> <SegmentTemplate timescale="10000000" presentationTimeOffset="0" media="$RepresentationID$/Segment-$Time$.m4v" initialization="$RepresentationID$/init.m4i"> <SegmentTimeline> <S t="9927777" d="20000000" r="256"/> <S t="5149927777" d="6800000"/> </SegmentTimeline> </SegmentTemplate> <Representation width="384" height="216" frameRate="25" codecs="avc1.4d400d" scanType="progressive" id="stream_0" bandwidth="280000"/> </AdaptationSet> <AdaptationSet mimeType="audio/mp4" startWithSAP="1" lang="rus" segmentAlignment="true"> <SegmentTemplate timescale="10000000" presentationTimeOffset="0" media="$RepresentationID$/Segment-$Time$.m4a" initialization="$RepresentationID$/init.m4i"> <SegmentTimeline> <S t="0" d="30720000"/> <S t="30720000" d="20480000"/> <S t="51200000" d="19200000"/> <S t="70400000" d="20480000"/>...

Shaka player set the currentTime of the video element to 9927777, which was the first PTS of the video stream, while the "Base media decode time" for the first video segment was 9527777. As a result, the timestampCorrection obtained (shaka.media.SourceBufferManager.prototype.fetch) for video and audio streams were -0.0400007 and 0, respectively.

However, Shaka player calculated the global timestampCorrection by choosing the maximum timestampCorrection among all streams, and then use the global timestampCorrection (value = 0) to call beginPlayback_, and thus the playback was started from 9927777 instead of 9527777 which had skipped the first IDR frame, and then resulted in the first second of video was not played.

After manually setting the global timestampCorrection to -0.0400007, all video were played successfully.

@joeyparrish
Copy link
Member

@hoimingw, can you please give us some more details? What version of Shaka are you using? Are you using shaka-player-demo.appspot.com or running from source?

@joeyparrish joeyparrish added the type: question A question from the community label Apr 15, 2016
@tdrews
Copy link
Contributor

tdrews commented Apr 20, 2016

We have completely done away with the timestamp correction mechanism in Shaka v2. What type of behavior do you see from the master branch?

@hoimingw
Copy link
Author

@joeyparrish , sorry for my late response. I was testing the issue with self-hosting Shaka player v1.6.5.

@hoimingw
Copy link
Author

@tdrews , Thanks for your information, we will test it on v2.

@tdrews
Copy link
Contributor

tdrews commented Apr 29, 2016

Hi, any luck with Shaka v2?

@hoimingw
Copy link
Author

hoimingw commented May 3, 2016

The issue is blocked by #348, the fix should have been committed to master but not officially released yet. We will test with the master branch though.
Thanks,

@hoimingw
Copy link
Author

hoimingw commented May 6, 2016

Test with Shaka player 2.0.0-beta2 (2016-05-04), the problem still exist. (The first second of video is missing).

@joeyparrish
Copy link
Member

Can you provide us with a manifest URL to reproduce the issue?

@hoimingw
Copy link
Author

hoimingw commented May 6, 2016

Hi joeyparrish,

I don't want to post our test content to public, may I have your email address so that I can share the content with you?

Thanks,

@joeyparrish
Copy link
Member

My email address can be found in CONTRIBUTORS. Please send to Joey Parrish and Timothy Drews.

@hoimingw
Copy link
Author

hoimingw commented May 9, 2016

Hi Joey,
The link to the test asset has been sent to you and Timothy.
Thanks,

@tdrews tdrews added this to the v2.0.0 milestone May 10, 2016
@tdrews tdrews added type: bug Something isn't working correctly type: external An issue with an external dependency; not our issue; sometimes kept open for tracking and removed type: question A question from the community labels May 12, 2016
@tdrews
Copy link
Contributor

tdrews commented May 12, 2016

@kqyang has determined that this is a bug in Chrome itself:
see https://bugs.chromium.org/p/chromium/issues/detail?id=398130

@hoimingw
Copy link
Author

Hi Tim,
Great thanks for your help!
Hoi Ming

@joeyparrish joeyparrish added the zzz-outdated: Chrome PTS/DTS bug Related to the Chrome PTS/DTS bugs that were present from 2016 - 2019; do not use for new issues label Aug 15, 2017
@shaka-project shaka-project locked and limited conversation to collaborators Mar 22, 2018
@shaka-bot shaka-bot added the status: archived Archived and locked; will not be updated label Apr 15, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: archived Archived and locked; will not be updated type: bug Something isn't working correctly type: external An issue with an external dependency; not our issue; sometimes kept open for tracking zzz-outdated: Chrome PTS/DTS bug Related to the Chrome PTS/DTS bugs that were present from 2016 - 2019; do not use for new issues
Projects
None yet
Development

No branches or pull requests

4 participants