| OLD | NEW |
| (Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "cc/resources/etc1_pixel_ref.h" |
| 6 |
| 7 #include "base/memory/scoped_ptr.h" |
| 8 #include "third_party/skia/include/core/SkPixelRef.h" |
| 9 |
| 10 namespace cc { |
| 11 |
| 12 // Takes ownership of pixels. |
| 13 ETC1PixelRef::ETC1PixelRef(scoped_ptr<uint8_t[]> pixels) |
| 14 : pixels_(pixels.Pass()) { |
| 15 setImmutable(); |
| 16 } |
| 17 |
| 18 void* ETC1PixelRef::onLockPixels(SkColorTable** color_table) SK_OVERRIDE { |
| 19 *color_table = NULL; |
| 20 return static_cast<void*>(pixels_.get()); |
| 21 } |
| 22 |
| 23 } // namespace cc |
| OLD | NEW |