| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #ifndef CONTENT_RENDERER_PEPPER_PEPPER_GRAPHICS_2D_HOST_H_ | 5 #ifndef CONTENT_RENDERER_PEPPER_PEPPER_GRAPHICS_2D_HOST_H_ |
| 6 #define CONTENT_RENDERER_PEPPER_PEPPER_GRAPHICS_2D_HOST_H_ | 6 #define CONTENT_RENDERER_PEPPER_PEPPER_GRAPHICS_2D_HOST_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 131 | 131 |
| 132 // If |old_image_data| is not NULL, a previous used ImageData object will be | 132 // If |old_image_data| is not NULL, a previous used ImageData object will be |
| 133 // reused. This is used by ReplaceContents. | 133 // reused. This is used by ReplaceContents. |
| 134 int32_t Flush(PP_Resource* old_image_data); | 134 int32_t Flush(PP_Resource* old_image_data); |
| 135 | 135 |
| 136 // Called internally to execute the different queued commands. The | 136 // Called internally to execute the different queued commands. The |
| 137 // parameters to these functions will have already been validated. The last | 137 // parameters to these functions will have already been validated. The last |
| 138 // rect argument will be filled by each function with the area affected by | 138 // rect argument will be filled by each function with the area affected by |
| 139 // the update that requires invalidation. If there were no pixels changed, | 139 // the update that requires invalidation. If there were no pixels changed, |
| 140 // this rect can be untouched. | 140 // this rect can be untouched. |
| 141 void ExecuteTransform(const float& scale, const gfx::PointF& translate); | 141 void ExecuteTransform(const float& scale, |
| 142 const gfx::PointF& translate, |
| 143 gfx::Rect* invalidated_rect); |
| 142 void ExecutePaintImageData(PPB_ImageData_Impl* image, | 144 void ExecutePaintImageData(PPB_ImageData_Impl* image, |
| 143 int x, | 145 int x, |
| 144 int y, | 146 int y, |
| 145 const gfx::Rect& src_rect, | 147 const gfx::Rect& src_rect, |
| 146 gfx::Rect* invalidated_rect); | 148 gfx::Rect* invalidated_rect); |
| 147 void ExecuteScroll(const gfx::Rect& clip, | 149 void ExecuteScroll(const gfx::Rect& clip, |
| 148 int dx, | 150 int dx, |
| 149 int dy, | 151 int dy, |
| 150 gfx::Rect* invalidated_rect); | 152 gfx::Rect* invalidated_rect); |
| 151 void ExecuteReplaceContents(PPB_ImageData_Impl* image, | 153 void ExecuteReplaceContents(PPB_ImageData_Impl* image, |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 221 std::unique_ptr<cc::SharedBitmap> cached_bitmap_; | 223 std::unique_ptr<cc::SharedBitmap> cached_bitmap_; |
| 222 gfx::Size cached_bitmap_size_; | 224 gfx::Size cached_bitmap_size_; |
| 223 | 225 |
| 224 friend class PepperGraphics2DHostTest; | 226 friend class PepperGraphics2DHostTest; |
| 225 DISALLOW_COPY_AND_ASSIGN(PepperGraphics2DHost); | 227 DISALLOW_COPY_AND_ASSIGN(PepperGraphics2DHost); |
| 226 }; | 228 }; |
| 227 | 229 |
| 228 } // namespace content | 230 } // namespace content |
| 229 | 231 |
| 230 #endif // CONTENT_RENDERER_PEPPER_PEPPER_GRAPHICS_2D_HOST_H_ | 232 #endif // CONTENT_RENDERER_PEPPER_PEPPER_GRAPHICS_2D_HOST_H_ |
| OLD | NEW |