[GStreamer][GL] crash within triggerRepaint
authorphiln@webkit.org <philn@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 11 Jul 2016 14:35:54 +0000 (14:35 +0000)
committerphiln@webkit.org <philn@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 11 Jul 2016 14:35:54 +0000 (14:35 +0000)
commit8f6571bf97cd0adeabd1b670b1ec7b2fb4617017
tree8cacbfc29b0cd0a65f3ad5a71b0983d9e6e8c6ed
parent089aa16ab405e1db8d6f9bae8df25c03878d218b
[GStreamer][GL] crash within triggerRepaint
https://bugs.webkit.org/show_bug.cgi?id=159552

Reviewed by Xabier Rodriguez-Calvar.

Ensure the sizeChanged notification is emitted from the main
thread. When GStreamer-GL rendering is enabled the appsink draw
callbacks are fired in a non-main thread.

The WeakPtr support was moved to the player base class so that it
can be used there as well as in the MediaPlayerPrivateGStreamer
sub-class.

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):
(WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer): Deleted.
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h:
(WebCore::MediaPlayerPrivateGStreamer::createWeakPtr): Deleted.
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::MediaPlayerPrivateGStreamerBase::MediaPlayerPrivateGStreamerBase):
(WebCore::MediaPlayerPrivateGStreamerBase::triggerRepaint):
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:
(WebCore::MediaPlayerPrivateGStreamerBase::createWeakPtr):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@203056 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp
Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h