| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ui/ozone/platform/cast/surface_factory_cast.h" | 5 #include "ui/ozone/platform/cast/surface_factory_cast.h" |
| 6 | 6 |
| 7 #include "base/callback_helpers.h" | 7 #include "base/callback_helpers.h" |
| 8 #include "chromecast/public/cast_egl_platform.h" | 8 #include "chromecast/public/cast_egl_platform.h" |
| 9 #include "chromecast/public/graphics_types.h" | 9 #include "chromecast/public/graphics_types.h" |
| 10 #include "ui/gfx/geometry/quad_f.h" | 10 #include "ui/gfx/geometry/quad_f.h" |
| (...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 181 } | 181 } |
| 182 | 182 |
| 183 const int32* SurfaceFactoryCast::GetEGLSurfaceProperties( | 183 const int32* SurfaceFactoryCast::GetEGLSurfaceProperties( |
| 184 const int32* desired_list) { | 184 const int32* desired_list) { |
| 185 return egl_platform_->GetEGLSurfaceProperties(desired_list); | 185 return egl_platform_->GetEGLSurfaceProperties(desired_list); |
| 186 } | 186 } |
| 187 | 187 |
| 188 scoped_refptr<NativePixmap> SurfaceFactoryCast::CreateNativePixmap( | 188 scoped_refptr<NativePixmap> SurfaceFactoryCast::CreateNativePixmap( |
| 189 gfx::AcceleratedWidget w, | 189 gfx::AcceleratedWidget w, |
| 190 gfx::Size size, | 190 gfx::Size size, |
| 191 BufferFormat format, | 191 gfx::BufferFormat format, |
| 192 BufferUsage usage) { | 192 gfx::BufferUsage usage) { |
| 193 class CastPixmap : public NativePixmap { | 193 class CastPixmap : public NativePixmap { |
| 194 public: | 194 public: |
| 195 CastPixmap() {} | 195 CastPixmap() {} |
| 196 | 196 |
| 197 void* GetEGLClientBuffer() override { | 197 void* GetEGLClientBuffer() override { |
| 198 // TODO(halliwell): try to implement this through CastEglPlatform. | 198 // TODO(halliwell): try to implement this through CastEglPlatform. |
| 199 return nullptr; | 199 return nullptr; |
| 200 } | 200 } |
| 201 int GetDmaBufFd() override { return 0; } | 201 int GetDmaBufFd() override { return 0; } |
| 202 int GetDmaBufPitch() override { return 0; } | 202 int GetDmaBufPitch() override { return 0; } |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 237 return false; | 237 return false; |
| 238 } | 238 } |
| 239 | 239 |
| 240 set_gl_get_proc_address.Run(gl_proc); | 240 set_gl_get_proc_address.Run(gl_proc); |
| 241 add_gl_library.Run(lib_egl); | 241 add_gl_library.Run(lib_egl); |
| 242 add_gl_library.Run(lib_gles2); | 242 add_gl_library.Run(lib_gles2); |
| 243 return true; | 243 return true; |
| 244 } | 244 } |
| 245 | 245 |
| 246 } // namespace ui | 246 } // namespace ui |
| OLD | NEW |