Upstream version 9.38.198.0
[platform/framework/web/crosswalk.git] / src / ui / ozone / platform / dri / gbm_surface_factory.h
index da624bf..b1ed46e 100644 (file)
@@ -13,11 +13,13 @@ namespace ui {
 
 class GbmSurfaceFactory : public DriSurfaceFactory {
  public:
-  GbmSurfaceFactory(DriWrapper* dri,
-                    gbm_device* device,
-                    ScreenManager* screen_manager);
+  GbmSurfaceFactory(bool allow_surfaceless);
   virtual ~GbmSurfaceFactory();
 
+  void InitializeGpu(DriWrapper* dri,
+                     gbm_device* device,
+                     ScreenManager* screen_manager);
+
   // DriSurfaceFactory:
   virtual intptr_t GetNativeDisplay() OVERRIDE;
   virtual const int32_t* GetEGLSurfaceProperties(
@@ -27,12 +29,20 @@ class GbmSurfaceFactory : public DriSurfaceFactory {
       SetGLGetProcAddressProcCallback set_gl_get_proc_address) OVERRIDE;
   virtual scoped_ptr<ui::SurfaceOzoneEGL> CreateEGLSurfaceForWidget(
       gfx::AcceleratedWidget w) OVERRIDE;
-  virtual gfx::NativeBufferOzone CreateNativeBuffer(
+  virtual scoped_refptr<ui::NativePixmap> CreateNativePixmap(
       gfx::Size size,
       BufferFormat format) OVERRIDE;
+  virtual bool ScheduleOverlayPlane(gfx::AcceleratedWidget widget,
+                                    int plane_z_order,
+                                    gfx::OverlayTransform plane_transform,
+                                    scoped_refptr<NativePixmap> buffer,
+                                    const gfx::Rect& display_bounds,
+                                    const gfx::RectF& crop_rect) OVERRIDE;
+  virtual bool CanShowPrimaryPlaneAsOverlay() OVERRIDE;
 
  private:
   gbm_device* device_;  // Not owned.
+  bool allow_surfaceless_;
 
   DISALLOW_COPY_AND_ASSIGN(GbmSurfaceFactory);
 };