7#include "core/fxge/dib/cfx_bitmapstorer.h"
13#include "core/fxcrt/span_util.h"
14#include "core/fxge/dib/cfx_dibitmap.h"
15#include "third_party/base/check_op.h"
22 return std::move(m_pBitmap);
26 m_pBitmap = std::move(pBitmap);
30 pdfium::span<
const uint8_t> scanline) {
31 pdfium::span<uint8_t> dest_buf = m_pBitmap->GetWritableScanline(line);
32 if (!dest_buf.empty())
33 fxcrt::spancpy(dest_buf, scanline);
39 DataVector<uint32_t> src_palette) {
42 auto pBitmap = pdfium::MakeRetain<CFX_DIBitmap>();
43 if (!pBitmap->Create(width, height, src_format))
46 if (!src_palette.empty()) {
47 pBitmap->TakePalette(
std::move(src_palette));
50 m_pBitmap = std::move(pBitmap);
void ComposeScanline(int line, pdfium::span< const uint8_t > scanline) override
~CFX_BitmapStorer() override
void Replace(RetainPtr< CFX_DIBitmap > &&pBitmap)
RetainPtr< CFX_DIBitmap > Detach()
bool SetInfo(int width, int height, FXDIB_Format src_format, DataVector< uint32_t > src_palette) override