Chromium Code Reviews| Index: tools/codec/SkBRDAllocator.h |
| diff --git a/tools/codec/SkBRDAllocator.h b/tools/codec/SkBRDAllocator.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..253e62d9702f6cff79a2691e9c50ed6395675d10 |
| --- /dev/null |
| +++ b/tools/codec/SkBRDAllocator.h |
| @@ -0,0 +1,25 @@ |
| +/* |
| + * Copyright 2015 Google Inc. |
| + * |
| + * Use of this source code is governed by a BSD-style license that can be |
| + * found in the LICENSE file. |
| + */ |
| + |
| +#include "SkBitmap.h" |
| +#include "SkCodec.h" |
| + |
| +/** |
| + * Abstract subclass of SkBitmap's allocator. |
| + * Allows the allocator to indicate if the memory it allocates |
| + * is zero initialized. |
| + */ |
| +class SkBRDAllocator : public SkBitmap::Allocator { |
| +public: |
| + virtual bool allocPixelRef(SkBitmap*, SkColorTable*) = 0; |
|
scroggo
2015/11/10 22:31:52
This does not change anything from the superclass.
msarett
2015/11/10 22:45:24
Good point. Removing.
|
| + |
| + /** |
| + * Indicates if the memory allocated by this allocator is |
| + * zero initialized. |
| + */ |
| + virtual SkCodec::ZeroInitialized zeroInit() const = 0; |
| +}; |