Summary: Playback rate is not preserved after seek/sample replacement.#532
Summary: Playback rate is not preserved after seek/sample replacement.#532philipjames123 wants to merge 2 commits into
Conversation
|
Pull request must be merged with a description containing the required fields, Summary: If there is no jira releated to this change, please put 'Jira: NO-JIRA'. Description can be changed by editing the top comment on your pull request and making a new commit. |
There was a problem hiding this comment.
Pull request overview
Fixes an issue where playback rate could be lost after seeking / sample replacement by ensuring newly-pushed GstSegments use a pending playback rate (when one is queued) instead of always using the currently-applied playback rate.
Changes:
- Selects the segment seek rate from
pendingPlaybackRatewhen set, otherwise falls back toplaybackRate. - Applies the selected rate when creating/pushing initial
GstSegments viagstSegmentDoSeek.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Coverage statistics of your commit: |
1 similar comment
|
Coverage statistics of your commit: |
3536ea7 to
573a2ae
Compare
| // Use pendingPlaybackRate if set (race condition mitigation) | ||
| double segmentRate = (m_context.pendingPlaybackRate != kNoPendingPlaybackRate) | ||
| ? m_context.pendingPlaybackRate | ||
| : m_context.playbackRate; | ||
|
|
||
| if (!m_gstWrapper->gstSegmentDoSeek(segment, segmentRate, GST_FORMAT_TIME, seekFlag, | ||
| GST_SEEK_TYPE_SET, position, GST_SEEK_TYPE_SET, stopPosition, nullptr)) |
573a2ae to
002ac43
Compare
|
Coverage statistics of your commit: |
002ac43 to
0dca3c1
Compare
|
Coverage statistics of your commit: |
1 similar comment
|
Coverage statistics of your commit: |
Summary: Playback rate is not preserved after seek Type: Fix Test Plan: UT/CT, Fullstack Jira: RDKEMW-15125 [WPEWebKit] playback rate after seeking/rebuffering.
0dca3c1 to
f8a311a
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.
Comments suppressed due to low confidence (1)
media/server/gstplayer/source/GstGenericPlayer.cpp:1441
- The new branch that prefers
m_context.pendingPlaybackRatewhen building the segment changes the behavior ofpushSampleIfRequired, but there doesn’t appear to be unit test coverage for the case wherependingPlaybackRateis set (existing GstGenericPlayerPrivate tests only exerciseplaybackRate). Adding a test that setscontext.pendingPlaybackRate(and a differentcontext.playbackRate) and expectsgstSegmentDoSeekto be called with the pending value would help prevent regressions in this fix.
{
m_gstWrapper->gstCapsSetSimple(newCaps, "height", G_TYPE_INT, height, NULL);
}
if ((kUndefinedSize != frameRate.numerator) && (kUndefinedSize != frameRate.denominator))
{
|
Coverage statistics of your commit: |
|
Coverage statistics of your commit: |
Summary: Playback rate is not preserved after seek
Type: Fix
Test Plan: All Seek related tests
Jira: RDKEMW-15125 [WPEWebKit] playback rate after seeking/rebuffering.