| 1 |
/* |
| 2 |
* Copyright 2017 Google Inc. |
| 3 |
* |
| 4 |
* Use of this source code is governed by a BSD-style license that can be |
| 5 |
* found in the LICENSE file. |
| 6 |
*/ |
| 7 |
#include "src/codec/SkBmpBaseCodec.h" |
| 8 |
|
| 9 |
#include "include/core/SkStream.h" |
| 10 |
#include "include/private/SkEncodedInfo.h" |
| 11 |
#include "include/private/base/SkMalloc.h" |
| 12 |
|
| 13 |
#include <utility> |
| 14 |
|
| 15 |
SkBmpBaseCodec::~SkBmpBaseCodec() {} |
| 16 |
|
| 17 |
SkBmpBaseCodec::SkBmpBaseCodec(SkEncodedInfo&& info, std::unique_ptr<SkStream> stream, |
| 18 |
uint16_t bitsPerPixel, SkCodec::SkScanlineOrder rowOrder) |
| 19 |
: INHERITED(std::move(info), std::move(stream), bitsPerPixel, rowOrder) |
| 20 |
, fSrcBuffer(sk_malloc_canfail(this->srcRowBytes())) |
| 21 |
{} |