Changeset 199000 in webkit


Ignore:
Timestamp:
Apr 4, 2016 3:21:35 AM (8 years ago)
Author:
commit-queue@webkit.org
Message:

Rely on PlatformLayer to choose the TextureMapperPlatformLayer impl
https://bugs.webkit.org/show_bug.cgi?id=155926

Patch by Emanuele Aina <Emanuele Aina> on 2016-04-04
Reviewed by Žan Doberšek.

Use PlatformLayer to replace a bunch of subtly different #ifdef
scattered over the codebase to choose between TextureMapperPlatformLayer
and TextureMapperPlatformLayerProxyProvider.

  • platform/graphics/GraphicsContext3DPrivate.h:
  • platform/graphics/cairo/ImageBufferDataCairo.h:
  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h: Use

PlatformLayer.h an inherit from PlatformLayer instead of choosing the
right implementation every time.

  • platform/graphics/texmap/TextureMapperPlatformLayer.h: Add

TEXTURE_MAPPER guards to make it unconditionally usable.

  • platform/graphics/texmap/TextureMapperPlatformLayerProxy.h: Add

COORDINATED_GRAPHICS_THREADED guards to make it unconditionally
usable.

Location:
trunk/Source/WebCore
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r198998 r199000  
     12016-04-04  Emanuele Aina  <emanuele.aina@collabora.com>
     2
     3        Rely on PlatformLayer to choose the TextureMapperPlatformLayer impl
     4        https://bugs.webkit.org/show_bug.cgi?id=155926
     5
     6        Reviewed by Žan Doberšek.
     7
     8        Use PlatformLayer to replace a bunch of subtly different #ifdef
     9        scattered over the codebase to choose between TextureMapperPlatformLayer
     10        and TextureMapperPlatformLayerProxyProvider.
     11
     12        * platform/graphics/GraphicsContext3DPrivate.h:
     13        * platform/graphics/cairo/ImageBufferDataCairo.h:
     14        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h: Use
     15        PlatformLayer.h an inherit from PlatformLayer instead of choosing the
     16        right implementation every time.
     17        * platform/graphics/texmap/TextureMapperPlatformLayer.h: Add
     18        TEXTURE_MAPPER guards to make it unconditionally usable.
     19        * platform/graphics/texmap/TextureMapperPlatformLayerProxy.h: Add
     20        COORDINATED_GRAPHICS_THREADED guards to make it unconditionally
     21        usable.
     22
    1232016-04-04  Frederic Wang  <fwang@igalia.com>
    224
  • trunk/Source/WebCore/platform/graphics/GraphicsContext3DPrivate.h

    r197563 r199000  
    2323#include "GLContext.h"
    2424#include "GraphicsContext3D.h"
    25 
    26 #if USE(COORDINATED_GRAPHICS_THREADED)
    27 #include "BitmapTextureGL.h"
     25#include "PlatformLayer.h"
     26#include "TextureMapperPlatformLayer.h"
    2827#include "TextureMapperPlatformLayerProxy.h"
    29 #elif USE(TEXTURE_MAPPER)
    30 #include "TextureMapperPlatformLayer.h"
    31 #endif
    3228
    3329namespace WebCore {
    3430
     31class BitmapTextureGL;
     32
    3533class GraphicsContext3DPrivate
    36 #if USE(COORDINATED_GRAPHICS_THREADED)
    37     : public TextureMapperPlatformLayerProxyProvider
    38 #elif USE(TEXTURE_MAPPER)
    39     : public TextureMapperPlatformLayer
     34#if USE(TEXTURE_MAPPER)
     35    : public PlatformLayer
    4036#endif
    4137{
  • trunk/Source/WebCore/platform/graphics/cairo/ImageBufferDataCairo.h

    r198205 r199000  
    3333
    3434#if ENABLE(ACCELERATED_2D_CANVAS)
     35#include "PlatformLayer.h"
    3536#include "TextureMapper.h"
    36 #if USE(COORDINATED_GRAPHICS_THREADED)
     37#include "TextureMapperPlatformLayer.h"
    3738#include "TextureMapperPlatformLayerProxy.h"
    38 #else
    39 #include "TextureMapperPlatformLayer.h"
    40 #endif
    4139#endif
    4240
     
    4745class ImageBufferData
    4846#if ENABLE(ACCELERATED_2D_CANVAS)
    49 #if USE(COORDINATED_GRAPHICS_THREADED)
    50     : public TextureMapperPlatformLayerProxyProvider
    51 #else
    52     : public TextureMapperPlatformLayer
    53 #endif
     47    : public PlatformLayer
    5448#endif
    5549{
  • trunk/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h

    r197563 r199000  
    2828#include "MainThreadNotifier.h"
    2929#include "MediaPlayerPrivate.h"
     30#include "PlatformLayer.h"
     31#include "TextureMapperPlatformLayer.h"
     32#include "TextureMapperPlatformLayerProxy.h"
    3033#include <glib.h>
    3134#include <wtf/Condition.h>
    3235#include <wtf/Forward.h>
    3336#include <wtf/RunLoop.h>
    34 
    35 #if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
    36 #include "TextureMapperPlatformLayer.h"
    37 #endif
    38 #if USE(COORDINATED_GRAPHICS_THREADED)
    39 #include "TextureMapperPlatformLayerProxy.h"
    40 #endif
    4137
    4238typedef struct _GstMessage GstMessage;
     
    5551
    5652class MediaPlayerPrivateGStreamerBase : public MediaPlayerPrivateInterface
    57 #if USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS)
    58     , public TextureMapperPlatformLayer
    59 #elif USE(COORDINATED_GRAPHICS_THREADED)
    60     , public TextureMapperPlatformLayerProxyProvider
     53#if USE(COORDINATED_GRAPHICS_THREADED) || (USE(TEXTURE_MAPPER_GL) && !USE(COORDINATED_GRAPHICS))
     54    , public PlatformLayer
    6155#endif
    6256{
  • trunk/Source/WebCore/platform/graphics/texmap/TextureMapperPlatformLayer.h

    r194103 r199000  
    2020#ifndef TextureMapperPlatformLayer_h
    2121#define TextureMapperPlatformLayer_h
     22
     23#if USE(TEXTURE_MAPPER)
    2224
    2325#if USE(GRAPHICS_SURFACE)
     
    6668};
    6769
     70#endif // USE(TEXTURE_MAPPER)
     71
    6872#endif // TextureMapperPlatformLayer_h
  • trunk/Source/WebCore/platform/graphics/texmap/TextureMapperPlatformLayerProxy.h

    r193836 r199000  
    2626#ifndef TextureMapperPlatformLayerProxy_h
    2727#define TextureMapperPlatformLayerProxy_h
     28
     29#if USE(COORDINATED_GRAPHICS_THREADED)
    2830
    2931#include "GraphicsTypes3D.h"
     
    104106} // namespace WebCore
    105107
     108#endif // USE(COORDINATED_GRAPHICS_THREADED)
     109
    106110#endif // TextureMapperPlatformLayerProxy_h
Note: See TracChangeset for help on using the changeset viewer.