WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
184588
[GStreamer] Fix the way GstStreamCollection is handled
https://bugs.webkit.org/show_bug.cgi?id=184588
Summary
[GStreamer] Fix the way GstStreamCollection is handled
Thibault Saunier
Reported
2018-04-13 07:38:17 PDT
See commit message.
Attachments
[GStreamer] Fix the way GstStreamCollection is handled
(10.87 KB, patch)
2018-04-13 07:38 PDT
,
Thibault Saunier
no flags
Details
Formatted Diff
Diff
[GStreamer] Fix the way GstStreamCollection is handled
(10.89 KB, patch)
2018-04-13 07:48 PDT
,
Thibault Saunier
no flags
Details
Formatted Diff
Diff
[GStreamer] Fix the way GstStreamCollection is handled
(11.01 KB, patch)
2018-04-23 06:11 PDT
,
Thibault Saunier
no flags
Details
Formatted Diff
Diff
[GStreamer] Fix the way GstStreamCollection is handled
(11.34 KB, patch)
2018-05-09 11:21 PDT
,
Thibault Saunier
no flags
Details
Formatted Diff
Diff
Rebased version of the patch taking into account previous comments and fixing little details
(11.72 KB, patch)
2018-06-01 06:50 PDT
,
Thibault Saunier
pnormand
: commit-queue-
Details
Formatted Diff
Diff
Patch.
(11.69 KB, patch)
2018-06-06 15:22 PDT
,
Thibault Saunier
no flags
Details
Formatted Diff
Diff
Show Obsolete
(5)
View All
Add attachment
proposed patch, testcase, etc.
Thibault Saunier
Comment 1
2018-04-13 07:38:22 PDT
Created
attachment 337886
[details]
[GStreamer] Fix the way GstStreamCollection is handled The stream collection message replaces the collection of stream previously advertised, this means that we should rebuild our set of Track from scratch and not update previously exposed tracks. In the end, this simplifies the code as we do not care about what tracks existed previously, we just need to expose what GStreamer tells us, deleting any previous state. Handle the STREAM_COLLECTION message from the sync handler so that tracks are updated before we mark the pipeline as READY for the live case (everything happen synchronously with the call to the `load()` method in that case), still the update happens on the main thread.
Thibault Saunier
Comment 2
2018-04-13 07:48:04 PDT
Created
attachment 337887
[details]
[GStreamer] Fix the way GstStreamCollection is handled The stream collection message replaces the collection of stream previously advertised, this means that we should rebuild our set of Track from scratch and not update previously exposed tracks. In the end, this simplifies the code as we do not care about what tracks existed previously, we just need to expose what GStreamer tells us, deleting any previous state. Handle the STREAM_COLLECTION message from the sync handler so that tracks are updated before we mark the pipeline as READY for the live case (everything happen synchronously with the call to the `load()` method in that case), still the update happens on the main thread.
Thibault Saunier
Comment 3
2018-04-13 08:57:36 PDT
I found an issue with that patch, I will update as soon as I get it fixed.
Philippe Normand
Comment 4
2018-04-13 10:43:06 PDT
Comment on
attachment 337887
[details]
[GStreamer] Fix the way GstStreamCollection is handled View in context:
https://bugs.webkit.org/attachment.cgi?id=337887&action=review
> Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:-693 > - m_hasAudio = !validAudioStreams.isEmpty(); > - m_hasVideo = !validVideoStreams.isEmpty();
These are not set anymore, it seems.
Thibault Saunier
Comment 5
2018-04-13 11:19:01 PDT
(In reply to Philippe Normand from
comment #4
)
> Comment on
attachment 337887
[details]
> [GStreamer] Fix the way GstStreamCollection is handled > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=337887&action=review
> > > Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:-693 > > - m_hasAudio = !validAudioStreams.isEmpty(); > > - m_hasVideo = !validVideoStreams.isEmpty(); > > These are not set anymore, it seems.
Oops, that was supposed to be done in the macro.
Thibault Saunier
Comment 6
2018-04-23 06:11:00 PDT
Created
attachment 338581
[details]
[GStreamer] Fix the way GstStreamCollection is handled The stream collection message replaces the collection of stream previously advertised, this means that we should rebuild our set of Track from scratch and not update previously exposed tracks. In the end, this simplifies the code as we do not care about what tracks existed previously, we just need to expose what GStreamer tells us, deleting any previous state. Handle the STREAM_COLLECTION message from the sync handler so that tracks are updated before we mark the pipeline as READY for the live case (everything happen synchronously with the call to the `load()` method in that case), still the update happens on the main thread.
Philippe Normand
Comment 7
2018-04-23 06:24:28 PDT
Comment on
attachment 338581
[details]
[GStreamer] Fix the way GstStreamCollection is handled View in context:
https://bugs.webkit.org/attachment.cgi?id=338581&action=review
> Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:-646 > - unsigned localIndex = i - validVideoStreams.size() - validTextStreams.size(); > - if (localIndex < m_audioTracks.size()) { > - if (m_audioTracks.contains(streamId)) > - continue;
Hum, the reason for this was to avoid adding a track that exists already... Removing this code might lead to unintended track-added (or something) <video> events. Are you sure this patch doesn't break any test?
Thibault Saunier
Comment 8
2018-04-23 06:32:03 PDT
(In reply to Philippe Normand from
comment #7
)
> Comment on
attachment 338581
[details]
> [GStreamer] Fix the way GstStreamCollection is handled > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=338581&action=review
> > > Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:-646 > > - unsigned localIndex = i - validVideoStreams.size() - validTextStreams.size(); > > - if (localIndex < m_audioTracks.size()) { > > - if (m_audioTracks.contains(streamId)) > > - continue; > > Hum, the reason for this was to avoid adding a track that exists already... > Removing this code might lead to unintended track-added (or something) > <video> events. Are you sure this patch doesn't break any test?
Right, thing is that now my first step is to remove all tracks previously configure tracks, those track are being obseleted by the new StreamCollection, so they should not be taken in consideration. I will re run the tests again, do not merge yet.
Thibault Saunier
Comment 9
2018-05-09 11:21:05 PDT
Created
attachment 339991
[details]
[GStreamer] Fix the way GstStreamCollection is handled The stream collection message replaces the collection of stream previously advertised, this means that we should rebuild our set of Track from scratch and not update previously exposed tracks. In the end, this simplifies the code as we do not care about what tracks existed previously, we just need to expose what GStreamer tells us, deleting any previous state. Handle the STREAM_COLLECTION message from the sync handler so that tracks are updated before we mark the pipeline as READY for the live case (everything happen synchronously with the call to the `load()` method in that case), still the update happens on the main thread.
Philippe Normand
Comment 10
2018-05-09 12:37:50 PDT
What changed since the previous iteration?
Thibault Saunier
Comment 11
2018-05-09 12:41:04 PDT
(In reply to Philippe Normand from
comment #10
)
> What changed since the previous iteration?
Supposedly a rebase after the patch from #185479 - I am still working on that one though I think it is correct already. I will let you know when I am fully happy with it. (Sorry for the noise.)
Thibault Saunier
Comment 12
2018-06-01 06:50:49 PDT
Created
attachment 341757
[details]
Rebased version of the patch taking into account previous comments and fixing little details while using it (especially in the MediaStream use case). This new patch should be good to review.
Philippe Normand
Comment 13
2018-06-04 00:30:33 PDT
Comment on
attachment 341757
[details]
Rebased version of the patch taking into account previous comments and fixing little details View in context:
https://bugs.webkit.org/attachment.cgi?id=341757&action=review
> Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:700 > +#undef CLEAR_TRACKS
This looks like a duplicate.
Thibault Saunier
Comment 14
2018-06-06 15:22:00 PDT
Created
attachment 342084
[details]
Patch. (In reply to Philippe Normand from
comment #13
)
> Comment on
attachment 341757
[details]
> Rebased version of the patch taking into account previous comments and > fixing little details > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=341757&action=review
> > > Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:700 > > +#undef CLEAR_TRACKS > > This looks like a duplicate.
Fixed.
WebKit Commit Bot
Comment 15
2018-06-07 02:36:05 PDT
Comment on
attachment 342084
[details]
Patch. Clearing flags on attachment: 342084 Committed
r232579
: <
https://trac.webkit.org/changeset/232579
>
WebKit Commit Bot
Comment 16
2018-06-07 02:36:07 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug