| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/output/copy_output_result.h" | 5 #include "cc/output/copy_output_result.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "cc/resources/single_release_callback.h" | |
| 9 #include "cc/resources/texture_mailbox.h" | 8 #include "cc/resources/texture_mailbox.h" |
| 10 #include "third_party/skia/include/core/SkBitmap.h" | 9 #include "third_party/skia/include/core/SkBitmap.h" |
| 11 | 10 |
| 12 namespace cc { | 11 namespace cc { |
| 13 | 12 |
| 14 CopyOutputResult::CopyOutputResult() {} | 13 CopyOutputResult::CopyOutputResult() {} |
| 15 | 14 |
| 16 CopyOutputResult::CopyOutputResult(scoped_ptr<SkBitmap> bitmap) | 15 CopyOutputResult::CopyOutputResult(scoped_ptr<SkBitmap> bitmap) |
| 17 : size_(bitmap->width(), bitmap->height()), | 16 : size_(bitmap->width(), bitmap->height()), |
| 18 bitmap_(bitmap.Pass()) { | 17 bitmap_(bitmap.Pass()) { |
| (...skipping 22 matching lines...) Expand all Loading... |
| 41 void CopyOutputResult::TakeTexture( | 40 void CopyOutputResult::TakeTexture( |
| 42 TextureMailbox* texture_mailbox, | 41 TextureMailbox* texture_mailbox, |
| 43 scoped_ptr<SingleReleaseCallback>* release_callback) { | 42 scoped_ptr<SingleReleaseCallback>* release_callback) { |
| 44 *texture_mailbox = texture_mailbox_; | 43 *texture_mailbox = texture_mailbox_; |
| 45 *release_callback = release_callback_.Pass(); | 44 *release_callback = release_callback_.Pass(); |
| 46 | 45 |
| 47 texture_mailbox_ = TextureMailbox(); | 46 texture_mailbox_ = TextureMailbox(); |
| 48 } | 47 } |
| 49 | 48 |
| 50 } // namespace cc | 49 } // namespace cc |
| OLD | NEW |