| 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 "components/bitmap_uploader/bitmap_uploader.h" | 5 #include "components/bitmap_uploader/bitmap_uploader.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "components/mus/public/cpp/window.h" | 9 #include "components/mus/public/cpp/window.h" |
| 10 #include "components/mus/public/cpp/window_surface.h" | 10 #include "components/mus/public/cpp/window_surface.h" |
| 11 #include "mojo/application/public/cpp/connect.h" | 11 #include "mojo/application/public/cpp/connect.h" |
| 12 #include "mojo/application/public/interfaces/shell.mojom.h" | 12 #include "mojo/application/public/interfaces/shell.mojom.h" |
| 13 #include "mojo/converters/geometry/geometry_type_converters.h" | 13 #include "mojo/converters/geometry/geometry_type_converters.h" |
| 14 #include "mojo/converters/surfaces/surfaces_type_converters.h" | 14 #include "mojo/converters/surfaces/surfaces_type_converters.h" |
| 15 #include "mojo/converters/surfaces/surfaces_utils.h" | 15 #include "mojo/converters/surfaces/surfaces_utils.h" |
| 16 #include "mojo/public/c/gles2/gles2.h" |
| 16 #include "mojo/services/network/public/interfaces/url_loader.mojom.h" | 17 #include "mojo/services/network/public/interfaces/url_loader.mojom.h" |
| 17 #include "third_party/mojo/src/mojo/public/c/gles2/gles2.h" | |
| 18 | 18 |
| 19 namespace bitmap_uploader { | 19 namespace bitmap_uploader { |
| 20 namespace { | 20 namespace { |
| 21 | 21 |
| 22 const uint32_t g_transparent_color = 0x00000000; | 22 const uint32_t g_transparent_color = 0x00000000; |
| 23 | 23 |
| 24 void LostContext(void*) { | 24 void LostContext(void*) { |
| 25 DCHECK(false); | 25 DCHECK(false); |
| 26 } | 26 } |
| 27 | 27 |
| (...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 248 glWaitSyncTokenCHROMIUM( | 248 glWaitSyncTokenCHROMIUM( |
| 249 resource->sync_token.To<gpu::SyncToken>().GetConstData()); | 249 resource->sync_token.To<gpu::SyncToken>().GetConstData()); |
| 250 uint32_t texture_id = resource_to_texture_id_map_[resource->id]; | 250 uint32_t texture_id = resource_to_texture_id_map_[resource->id]; |
| 251 DCHECK_NE(0u, texture_id); | 251 DCHECK_NE(0u, texture_id); |
| 252 resource_to_texture_id_map_.erase(resource->id); | 252 resource_to_texture_id_map_.erase(resource->id); |
| 253 glDeleteTextures(1, &texture_id); | 253 glDeleteTextures(1, &texture_id); |
| 254 } | 254 } |
| 255 } | 255 } |
| 256 | 256 |
| 257 } // namespace bitmap_uploader | 257 } // namespace bitmap_uploader |
| OLD | NEW |