| 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 #include "content/renderer/pepper/ppb_image_data_impl.h" | 5 #include "content/renderer/pepper/ppb_image_data_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <limits> | 8 #include <limits> |
| 9 #include <memory> | 9 #include <memory> |
| 10 | 10 |
| 11 #include "base/logging.h" | 11 #include "base/logging.h" |
| 12 #include "base/memory/ptr_util.h" |
| 12 #include "content/common/pepper_file_util.h" | 13 #include "content/common/pepper_file_util.h" |
| 13 #include "content/common/view_messages.h" | 14 #include "content/common/view_messages.h" |
| 14 #include "content/renderer/render_thread_impl.h" | 15 #include "content/renderer/render_thread_impl.h" |
| 15 #include "ppapi/c/pp_errors.h" | 16 #include "ppapi/c/pp_errors.h" |
| 16 #include "ppapi/c/pp_instance.h" | 17 #include "ppapi/c/pp_instance.h" |
| 17 #include "ppapi/c/pp_resource.h" | 18 #include "ppapi/c/pp_resource.h" |
| 18 #include "ppapi/c/ppb_image_data.h" | 19 #include "ppapi/c/ppb_image_data.h" |
| 19 #include "ppapi/thunk/thunk.h" | 20 #include "ppapi/thunk/thunk.h" |
| 20 #include "skia/ext/platform_canvas.h" | 21 #include "skia/ext/platform_canvas.h" |
| 21 #include "third_party/skia/include/core/SkCanvas.h" | 22 #include "third_party/skia/include/core/SkCanvas.h" |
| (...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 277 return skia_canvas_.get(); | 278 return skia_canvas_.get(); |
| 278 } | 279 } |
| 279 | 280 |
| 280 SkBitmap ImageDataSimpleBackend::GetMappedBitmap() const { | 281 SkBitmap ImageDataSimpleBackend::GetMappedBitmap() const { |
| 281 if (!IsMapped()) | 282 if (!IsMapped()) |
| 282 return SkBitmap(); | 283 return SkBitmap(); |
| 283 return skia_bitmap_; | 284 return skia_bitmap_; |
| 284 } | 285 } |
| 285 | 286 |
| 286 } // namespace content | 287 } // namespace content |
| OLD | NEW |