OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "gpu/ipc/service/gpu_memory_buffer_factory_ozone_native_pixmap.h" | 5 #include "gpu/ipc/service/gpu_memory_buffer_factory_ozone_native_pixmap.h" |
6 | 6 |
7 #include "ui/gl/gl_image_ozone_native_pixmap.h" | 7 #include "ui/gl/gl_image_ozone_native_pixmap.h" |
8 #include "ui/ozone/public/client_native_pixmap.h" | 8 #include "ui/ozone/public/client_native_pixmap.h" |
9 #include "ui/ozone/public/client_native_pixmap_factory.h" | 9 #include "ui/ozone/public/client_native_pixmap_factory.h" |
10 #include "ui/ozone/public/ozone_platform.h" | 10 #include "ui/ozone/public/ozone_platform.h" |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
109 { | 109 { |
110 base::AutoLock lock(native_pixmaps_lock_); | 110 base::AutoLock lock(native_pixmaps_lock_); |
111 NativePixmapMap::iterator it = | 111 NativePixmapMap::iterator it = |
112 native_pixmaps_.find(NativePixmapMapKey(handle.id.id, client_id)); | 112 native_pixmaps_.find(NativePixmapMapKey(handle.id.id, client_id)); |
113 if (it == native_pixmaps_.end()) { | 113 if (it == native_pixmaps_.end()) { |
114 return nullptr; | 114 return nullptr; |
115 } | 115 } |
116 pixmap = it->second; | 116 pixmap = it->second; |
117 } | 117 } |
118 | 118 |
119 scoped_refptr<gfx::GLImageOzoneNativePixmap> image( | 119 scoped_refptr<gl::GLImageOzoneNativePixmap> image( |
120 new gfx::GLImageOzoneNativePixmap(size, internalformat)); | 120 new gl::GLImageOzoneNativePixmap(size, internalformat)); |
121 if (!image->Initialize(pixmap.get(), format)) { | 121 if (!image->Initialize(pixmap.get(), format)) { |
122 LOG(ERROR) << "Failed to create GLImage"; | 122 LOG(ERROR) << "Failed to create GLImage"; |
123 return nullptr; | 123 return nullptr; |
124 } | 124 } |
125 return image; | 125 return image; |
126 } | 126 } |
127 | 127 |
128 } // namespace gpu | 128 } // namespace gpu |
OLD | NEW |