Skip to content
Permalink
Browse files
[GTK] Fix build with GSTREAMER_GL enabled and ACCELERATED_2D_CANVAS d…
…isabled

https://bugs.webkit.org/show_bug.cgi?id=163008

Patch by Miguel Gomez <magomez@igalia.com> on 2016-10-06
Reviewed by Carlos Garcia Campos.

Put functions using cairo-gl behind appropriate guards.

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::MediaPlayerPrivateGStreamerBase::paintToCairoSurface): Deleted.
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:

Canonical link: https://commits.webkit.org/180916@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@206863 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
magomez authored and webkit-commit-queue committed Oct 6, 2016
1 parent 2c522fb commit 83c94a766ac13f30a59625cba88e4e966440c9e9
@@ -1,3 +1,16 @@
2016-10-06 Miguel Gomez <magomez@igalia.com>

[GTK] Fix build with GSTREAMER_GL enabled and ACCELERATED_2D_CANVAS disabled
https://bugs.webkit.org/show_bug.cgi?id=163008

Reviewed by Carlos Garcia Campos.

Put functions using cairo-gl behind appropriate guards.

* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
(WebCore::MediaPlayerPrivateGStreamerBase::paintToCairoSurface): Deleted.
* platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:

2016-10-06 Miguel Gomez <magomez@igalia.com>

[GTK] Copying video textures to webgl should not depend on cairo-gl
@@ -713,6 +713,7 @@ void MediaPlayerPrivateGStreamerBase::paintToTextureMapper(TextureMapper& textur
#endif

#if USE(GSTREAMER_GL)
#if USE(CAIRO) && ENABLE(ACCELERATED_2D_CANVAS)
// This should be called with the sample mutex locked.
GLContext* MediaPlayerPrivateGStreamerBase::prepareContextForCairoPaint(GstVideoInfo& videoInfo, IntSize& size, IntSize& rotatedSize)
{
@@ -779,6 +780,7 @@ bool MediaPlayerPrivateGStreamerBase::paintToCairoSurface(cairo_surface_t* outpu

return true;
}
#endif // USE(CAIRO) && ENABLE(ACCELERATED_2D_CANVAS)

bool MediaPlayerPrivateGStreamerBase::copyVideoTextureToPlatformTexture(GraphicsContext3D* context, Platform3DObject outputTexture, GC3Denum outputTarget, GC3Dint level, GC3Denum internalFormat, GC3Denum format, GC3Denum type, bool premultiplyAlpha, bool flipY)
{
@@ -133,8 +133,10 @@ class MediaPlayerPrivateGStreamerBase : public MediaPlayerPrivateInterface
static GstFlowReturn newPrerollCallback(GstElement*, MediaPlayerPrivateGStreamerBase*);
GstElement* createGLAppSink();
GstElement* createVideoSinkGL();
#if USE(CAIRO) && ENABLE(ACCELERATED_2D_CANVAS)
GLContext* prepareContextForCairoPaint(GstVideoInfo&, IntSize&, IntSize&);
bool paintToCairoSurface(cairo_surface_t*, cairo_device_t*, GstVideoInfo&, const IntSize&, const IntSize&, bool);
#endif
#endif

void setStreamVolumeElement(GstStreamVolume*);

0 comments on commit 83c94a7

Please sign in to comment.