#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "third_party/blink/renderer/platform/image-decoders/bmp/bmp_image_reader.h"
#include "third_party/blink/renderer/platform/image-decoders/jpeg/jpeg_image_decoder.h"
#include "third_party/blink/renderer/platform/image-decoders/png/png_image_decoder.h"
#include "third_party/skia/include/core/SkColorSpace.h"
namespace {
constexpr uint8_t nBitTo8BitlookupTable[] = …;
}
namespace blink {
BMPImageReader::BMPImageReader(ImageDecoder* parent,
wtf_size_t decoded_and_header_offset,
wtf_size_t img_data_offset,
bool is_in_ico)
: … { … }
BMPImageReader::~BMPImageReader() = default;
void BMPImageReader::SetData(scoped_refptr<SegmentReader> data) { … }
bool BMPImageReader::DecodeBMP(bool only_size) { … }
bool BMPImageReader::ReadInfoHeaderSize() { … }
bool BMPImageReader::ProcessInfoHeader() { … }
bool BMPImageReader::ReadInfoHeader() { … }
bool BMPImageReader::IsInfoHeaderValid() const { … }
bool BMPImageReader::DecodeAlternateFormat() { … }
bool BMPImageReader::ProcessEmbeddedColorProfile() { … }
bool BMPImageReader::ProcessBitmasks() { … }
bool BMPImageReader::ProcessColorTable() { … }
bool BMPImageReader::InitFrame() { … }
bool BMPImageReader::DecodePixelData(bool non_rle) { … }
BMPImageReader::ProcessingResult BMPImageReader::ProcessRLEData() { … }
BMPImageReader::ProcessingResult BMPImageReader::ProcessNonRLEData(
bool in_rle,
int num_pixels) { … }
void BMPImageReader::MoveBufferToNextRow() { … }
void BMPImageReader::ColorCorrectCurrentRow() { … }
}