Changeset 263656 in webkit
- Timestamp:
- Jun 29, 2020 4:50:21 AM (4 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 9 edited
- 2 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r263655 r263656 1 2020-06-29 Alicia Boya García <aboya@igalia.com> 2 3 [MSE][GStreamer] Rename MediaSourceGStreamer to MediaSourcePrivateGStreamer 4 https://bugs.webkit.org/show_bug.cgi?id=213722 5 6 Reviewed by Xabier Rodriguez-Calvar. 7 8 It's about time to remove this FIXME: 9 10 // FIXME: Should this be called MediaSourcePrivateGStreamer? 11 12 Yes, it should. Because it's a MediaSourcePrivate, and that is an 13 important fact. The MSE class diagram is confusing enough already, 14 let's fix this. 15 16 To rebase commits after this change use `git format-patch` first to 17 get them in a patch format and then run: 18 19 sed -i 's|\<MediaSourceGStreamer\>|MediaSourcePrivateGStreamer|g' *.patch 20 21 This patch is a refactor that produces no behavior changes. 22 23 * platform/GStreamer.cmake: 24 * platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp: 25 (WebCore::MediaPlayerPrivateGStreamerMSE::sourceSetup): 26 * platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.h: 27 * platform/graphics/gstreamer/mse/MediaSourceClientGStreamerMSE.h: 28 * platform/graphics/gstreamer/mse/MediaSourcePrivateGStreamer.cpp: Renamed from Source/WebCore/platform/graphics/gstreamer/mse/MediaSourceGStreamer.cpp. 29 (WebCore::MediaSourcePrivateGStreamer::open): 30 (WebCore::MediaSourcePrivateGStreamer::MediaSourcePrivateGStreamer): 31 (WebCore::MediaSourcePrivateGStreamer::~MediaSourcePrivateGStreamer): 32 (WebCore::MediaSourcePrivateGStreamer::addSourceBuffer): 33 (WebCore::MediaSourcePrivateGStreamer::removeSourceBuffer): 34 (WebCore::MediaSourcePrivateGStreamer::durationChanged): 35 (WebCore::MediaSourcePrivateGStreamer::markEndOfStream): 36 (WebCore::MediaSourcePrivateGStreamer::unmarkEndOfStream): 37 (WebCore::MediaSourcePrivateGStreamer::readyState const): 38 (WebCore::MediaSourcePrivateGStreamer::setReadyState): 39 (WebCore::MediaSourcePrivateGStreamer::waitForSeekCompleted): 40 (WebCore::MediaSourcePrivateGStreamer::seekCompleted): 41 (WebCore::MediaSourcePrivateGStreamer::sourceBufferPrivateDidChangeActiveState): 42 (WebCore::MediaSourcePrivateGStreamer::buffered): 43 (WebCore::MediaSourcePrivateGStreamer::logChannel const): 44 * platform/graphics/gstreamer/mse/MediaSourcePrivateGStreamer.h: Renamed from Source/WebCore/platform/graphics/gstreamer/mse/MediaSourceGStreamer.h. 45 * platform/graphics/gstreamer/mse/PlaybackPipeline.h: 46 * platform/graphics/gstreamer/mse/SourceBufferPrivateGStreamer.cpp: 47 (WebCore::SourceBufferPrivateGStreamer::create): 48 (WebCore::SourceBufferPrivateGStreamer::SourceBufferPrivateGStreamer): 49 * platform/graphics/gstreamer/mse/SourceBufferPrivateGStreamer.h: 50 * platform/graphics/gstreamer/mse/WebKitMediaSourceGStreamer.cpp: 51 1 52 2020-06-29 Youenn Fablet <youenn@apple.com> 2 53 -
trunk/Source/WebCore/platform/GStreamer.cmake
r261922 r263656 34 34 platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp 35 35 platform/graphics/gstreamer/mse/MediaSourceClientGStreamerMSE.cpp 36 platform/graphics/gstreamer/mse/MediaSource GStreamer.cpp36 platform/graphics/gstreamer/mse/MediaSourcePrivateGStreamer.cpp 37 37 platform/graphics/gstreamer/mse/PlaybackPipeline.cpp 38 38 platform/graphics/gstreamer/mse/SourceBufferPrivateGStreamer.cpp -
trunk/Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp
r261986 r263656 492 492 m_playbackPipeline->setWebKitMediaSrc(WEBKIT_MEDIA_SRC(m_source.get())); 493 493 494 MediaSource GStreamer::open(*m_mediaSource.get(), *this);494 MediaSourcePrivateGStreamer::open(*m_mediaSource.get(), *this); 495 495 g_signal_connect_swapped(m_source.get(), "video-changed", G_CALLBACK(videoChangedCallback), this); 496 496 g_signal_connect_swapped(m_source.get(), "audio-changed", G_CALLBACK(audioChangedCallback), this); -
trunk/Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.h
r258691 r263656 30 30 #include "MediaPlayerPrivateGStreamer.h" 31 31 #include "MediaSample.h" 32 #include "MediaSource GStreamer.h"32 #include "MediaSourcePrivateGStreamer.h" 33 33 #include "WebKitMediaSourceGStreamer.h" 34 34 -
trunk/Source/WebCore/platform/graphics/gstreamer/mse/MediaSourceClientGStreamerMSE.h
r251365 r263656 41 41 virtual ~MediaSourceClientGStreamerMSE(); 42 42 43 // From MediaSource GStreamer.43 // From MediaSourcePrivateGStreamer. 44 44 MediaSourcePrivate::AddStatus addSourceBuffer(RefPtr<SourceBufferPrivateGStreamer>, const ContentType&); 45 45 void durationChanged(const MediaTime&); -
trunk/Source/WebCore/platform/graphics/gstreamer/mse/MediaSourcePrivateGStreamer.cpp
r263655 r263656 34 34 35 35 #include "config.h" 36 #include "MediaSource GStreamer.h"36 #include "MediaSourcePrivateGStreamer.h" 37 37 38 38 #if ENABLE(MEDIA_SOURCE) && USE(GSTREAMER) … … 52 52 namespace WebCore { 53 53 54 void MediaSource GStreamer::open(MediaSourcePrivateClient& mediaSource, MediaPlayerPrivateGStreamerMSE& playerPrivate)54 void MediaSourcePrivateGStreamer::open(MediaSourcePrivateClient& mediaSource, MediaPlayerPrivateGStreamerMSE& playerPrivate) 55 55 { 56 mediaSource.setPrivateAndOpen(adoptRef(*new MediaSource GStreamer(mediaSource, playerPrivate)));56 mediaSource.setPrivateAndOpen(adoptRef(*new MediaSourcePrivateGStreamer(mediaSource, playerPrivate))); 57 57 } 58 58 59 MediaSource GStreamer::MediaSourceGStreamer(MediaSourcePrivateClient& mediaSource, MediaPlayerPrivateGStreamerMSE& playerPrivate)59 MediaSourcePrivateGStreamer::MediaSourcePrivateGStreamer(MediaSourcePrivateClient& mediaSource, MediaPlayerPrivateGStreamerMSE& playerPrivate) 60 60 : MediaSourcePrivate() 61 61 , m_client(MediaSourceClientGStreamerMSE::create(playerPrivate)) … … 69 69 } 70 70 71 MediaSource GStreamer::~MediaSourceGStreamer()71 MediaSourcePrivateGStreamer::~MediaSourcePrivateGStreamer() 72 72 { 73 73 ALWAYS_LOG(LOGIDENTIFIER); … … 76 76 } 77 77 78 MediaSource GStreamer::AddStatus MediaSourceGStreamer::addSourceBuffer(const ContentType& contentType, RefPtr<SourceBufferPrivate>& sourceBufferPrivate)78 MediaSourcePrivateGStreamer::AddStatus MediaSourcePrivateGStreamer::addSourceBuffer(const ContentType& contentType, RefPtr<SourceBufferPrivate>& sourceBufferPrivate) 79 79 { 80 80 DEBUG_LOG(LOGIDENTIFIER, contentType); … … 85 85 } 86 86 87 void MediaSource GStreamer::removeSourceBuffer(SourceBufferPrivate* sourceBufferPrivate)87 void MediaSourcePrivateGStreamer::removeSourceBuffer(SourceBufferPrivate* sourceBufferPrivate) 88 88 { 89 89 RefPtr<SourceBufferPrivateGStreamer> sourceBufferPrivateGStreamer = static_cast<SourceBufferPrivateGStreamer*>(sourceBufferPrivate); … … 95 95 } 96 96 97 void MediaSource GStreamer::durationChanged()97 void MediaSourcePrivateGStreamer::durationChanged() 98 98 { 99 99 m_client->durationChanged(m_mediaSource->duration()); 100 100 } 101 101 102 void MediaSource GStreamer::markEndOfStream(EndOfStreamStatus status)102 void MediaSourcePrivateGStreamer::markEndOfStream(EndOfStreamStatus status) 103 103 { 104 104 m_client->markEndOfStream(status); 105 105 } 106 106 107 void MediaSource GStreamer::unmarkEndOfStream()107 void MediaSourcePrivateGStreamer::unmarkEndOfStream() 108 108 { 109 109 notImplemented(); 110 110 } 111 111 112 MediaPlayer::ReadyState MediaSource GStreamer::readyState() const112 MediaPlayer::ReadyState MediaSourcePrivateGStreamer::readyState() const 113 113 { 114 114 return m_playerPrivate.readyState(); 115 115 } 116 116 117 void MediaSource GStreamer::setReadyState(MediaPlayer::ReadyState state)117 void MediaSourcePrivateGStreamer::setReadyState(MediaPlayer::ReadyState state) 118 118 { 119 119 m_playerPrivate.setReadyState(state); 120 120 } 121 121 122 void MediaSource GStreamer::waitForSeekCompleted()122 void MediaSourcePrivateGStreamer::waitForSeekCompleted() 123 123 { 124 124 m_playerPrivate.waitForSeekCompleted(); 125 125 } 126 126 127 void MediaSource GStreamer::seekCompleted()127 void MediaSourcePrivateGStreamer::seekCompleted() 128 128 { 129 129 m_playerPrivate.seekCompleted(); 130 130 } 131 131 132 void MediaSource GStreamer::sourceBufferPrivateDidChangeActiveState(SourceBufferPrivateGStreamer* sourceBufferPrivate, bool isActive)132 void MediaSourcePrivateGStreamer::sourceBufferPrivateDidChangeActiveState(SourceBufferPrivateGStreamer* sourceBufferPrivate, bool isActive) 133 133 { 134 134 if (!isActive) … … 138 138 } 139 139 140 std::unique_ptr<PlatformTimeRanges> MediaSource GStreamer::buffered()140 std::unique_ptr<PlatformTimeRanges> MediaSourcePrivateGStreamer::buffered() 141 141 { 142 142 return m_mediaSource->buffered(); … … 144 144 145 145 #if !RELEASE_LOG_DISABLED 146 WTFLogChannel& MediaSource GStreamer::logChannel() const146 WTFLogChannel& MediaSourcePrivateGStreamer::logChannel() const 147 147 { 148 148 return LogMediaSource; -
trunk/Source/WebCore/platform/graphics/gstreamer/mse/MediaSourcePrivateGStreamer.h
r263655 r263656 51 51 class PlatformTimeRanges; 52 52 53 // FIXME: Should this be called MediaSourcePrivateGStreamer? 54 class MediaSourceGStreamer final : public MediaSourcePrivate 53 class MediaSourcePrivateGStreamer final : public MediaSourcePrivate 55 54 #if !RELEASE_LOG_DISABLED 56 55 , private LoggerHelper … … 59 58 public: 60 59 static void open(MediaSourcePrivateClient&, MediaPlayerPrivateGStreamerMSE&); 61 virtual ~MediaSource GStreamer();60 virtual ~MediaSourcePrivateGStreamer(); 62 61 63 62 MediaSourceClientGStreamerMSE& client() { return m_client.get(); } … … 89 88 90 89 private: 91 MediaSource GStreamer(MediaSourcePrivateClient&, MediaPlayerPrivateGStreamerMSE&);90 MediaSourcePrivateGStreamer(MediaSourcePrivateClient&, MediaPlayerPrivateGStreamerMSE&); 92 91 93 92 HashSet<RefPtr<SourceBufferPrivateGStreamer>> m_sourceBuffers; -
trunk/Source/WebCore/platform/graphics/gstreamer/mse/PlaybackPipeline.h
r251365 r263656 42 42 class ContentType; 43 43 class SourceBufferPrivateGStreamer; 44 class MediaSource GStreamer;44 class MediaSourcePrivateGStreamer; 45 45 46 46 class PlaybackPipeline: public RefCounted<PlaybackPipeline> { … … 62 62 void notifyDurationChanged(); 63 63 64 // From MediaSource GStreamer.64 // From MediaSourcePrivateGStreamer. 65 65 void markEndOfStream(MediaSourcePrivate::EndOfStreamStatus); 66 66 -
trunk/Source/WebCore/platform/graphics/gstreamer/mse/SourceBufferPrivateGStreamer.cpp
r258547 r263656 43 43 #include "MediaSample.h" 44 44 #include "MediaSourceClientGStreamerMSE.h" 45 #include "MediaSource GStreamer.h"45 #include "MediaSourcePrivateGStreamer.h" 46 46 #include "NotImplemented.h" 47 47 #include "WebKitMediaSourceGStreamer.h" … … 49 49 namespace WebCore { 50 50 51 Ref<SourceBufferPrivateGStreamer> SourceBufferPrivateGStreamer::create(MediaSource GStreamer* mediaSource, Ref<MediaSourceClientGStreamerMSE> client, const ContentType& contentType)51 Ref<SourceBufferPrivateGStreamer> SourceBufferPrivateGStreamer::create(MediaSourcePrivateGStreamer* mediaSource, Ref<MediaSourceClientGStreamerMSE> client, const ContentType& contentType) 52 52 { 53 53 return adoptRef(*new SourceBufferPrivateGStreamer(mediaSource, client.get(), contentType)); 54 54 } 55 55 56 SourceBufferPrivateGStreamer::SourceBufferPrivateGStreamer(MediaSource GStreamer* mediaSource, Ref<MediaSourceClientGStreamerMSE> client, const ContentType& contentType)56 SourceBufferPrivateGStreamer::SourceBufferPrivateGStreamer(MediaSourcePrivateGStreamer* mediaSource, Ref<MediaSourceClientGStreamerMSE> client, const ContentType& contentType) 57 57 : SourceBufferPrivate() 58 58 , m_mediaSource(mediaSource) -
trunk/Source/WebCore/platform/graphics/gstreamer/mse/SourceBufferPrivateGStreamer.h
r258547 r263656 46 46 namespace WebCore { 47 47 48 class MediaSource GStreamer;48 class MediaSourcePrivateGStreamer; 49 49 50 50 class SourceBufferPrivateGStreamer final : public SourceBufferPrivate … … 55 55 56 56 public: 57 static Ref<SourceBufferPrivateGStreamer> create(MediaSource GStreamer*, Ref<MediaSourceClientGStreamerMSE>, const ContentType&);57 static Ref<SourceBufferPrivateGStreamer> create(MediaSourcePrivateGStreamer*, Ref<MediaSourceClientGStreamerMSE>, const ContentType&); 58 58 virtual ~SourceBufferPrivateGStreamer() = default; 59 59 … … 95 95 96 96 private: 97 SourceBufferPrivateGStreamer(MediaSource GStreamer*, Ref<MediaSourceClientGStreamerMSE>, const ContentType&);97 SourceBufferPrivateGStreamer(MediaSourcePrivateGStreamer*, Ref<MediaSourceClientGStreamerMSE>, const ContentType&); 98 98 friend class MediaSourceClientGStreamerMSE; 99 99 100 MediaSource GStreamer* m_mediaSource;100 MediaSourcePrivateGStreamer* m_mediaSource; 101 101 ContentType m_type; 102 102 Ref<MediaSourceClientGStreamerMSE> m_client; -
trunk/Source/WebCore/platform/graphics/gstreamer/mse/WebKitMediaSourceGStreamer.cpp
r260506 r263656 34 34 #include "MediaPlayerPrivateGStreamerMSE.h" 35 35 #include "MediaSample.h" 36 #include "MediaSource GStreamer.h"36 #include "MediaSourcePrivateGStreamer.h" 37 37 #include "NotImplemented.h" 38 38 #include "SourceBufferPrivateGStreamer.h"
Note: See TracChangeset
for help on using the changeset viewer.