| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 "cc/tile_draw_quad.h" | 5 #include "cc/tile_draw_quad.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "third_party/khronos/GLES2/gl2.h" | 8 #include "third_party/khronos/GLES2/gl2.h" |
| 9 | 9 |
| 10 namespace cc { | 10 namespace cc { |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 this->top_edge_aa = top_edge_aa; | 73 this->top_edge_aa = top_edge_aa; |
| 74 this->right_edge_aa = right_edge_aa; | 74 this->right_edge_aa = right_edge_aa; |
| 75 this->bottom_edge_aa = bottom_edge_aa; | 75 this->bottom_edge_aa = bottom_edge_aa; |
| 76 } | 76 } |
| 77 | 77 |
| 78 void TileDrawQuad::AppendResources( | 78 void TileDrawQuad::AppendResources( |
| 79 ResourceProvider::ResourceIdArray* resources) { | 79 ResourceProvider::ResourceIdArray* resources) { |
| 80 resources->push_back(resource_id); | 80 resources->push_back(resource_id); |
| 81 } | 81 } |
| 82 | 82 |
| 83 void TileDrawQuad::RemapResources( |
| 84 const ResourceRemapCallback& remap_callback) { |
| 85 resource_id = remap_callback.Run(resource_id); |
| 86 } |
| 87 |
| 83 const TileDrawQuad* TileDrawQuad::MaterialCast( | 88 const TileDrawQuad* TileDrawQuad::MaterialCast( |
| 84 const DrawQuad* quad) { | 89 const DrawQuad* quad) { |
| 85 DCHECK(quad->material == DrawQuad::TILED_CONTENT); | 90 DCHECK(quad->material == DrawQuad::TILED_CONTENT); |
| 86 return static_cast<const TileDrawQuad*>(quad); | 91 return static_cast<const TileDrawQuad*>(quad); |
| 87 } | 92 } |
| 88 | 93 |
| 89 } // namespace cc | 94 } // namespace cc |
| OLD | NEW |