chromium/third_party/skia/src/codec/SkJpegConstants.h

/*
 * Copyright 2023 Google LLC
 *
 * Use of this source code is governed by a BSD-style license that can be
 * found in the LICENSE file.
 */

#ifndef SkJpegConstants_codec_DEFINED
#define SkJpegConstants_codec_DEFINED

#include <cstddef>
#include <cstdint>

// The first marker of all JPEG files is StartOfImage.
static constexpr uint8_t kJpegMarkerStartOfImage =;

// The last marker of all JPEG files (excluding auxiliary data, e.g, MPF images) is EndOfImage.
static constexpr uint8_t kJpegMarkerEndOfImage =;

// The header of a JPEG file is the data in all segments before the first StartOfScan.
static constexpr uint8_t kJpegMarkerStartOfScan =;

// Metadata and auxiliary images are stored in the APP1 through APP15 markers.
static constexpr uint8_t kJpegMarkerAPP0 =;

// The number of bytes in a marker code is two. The first byte is all marker codes is 0xFF.
static constexpr size_t kJpegMarkerCodeSize =;

// The number of bytes used to specify the length of a segment's parameters is two. This length
// value includes these two bytes.
static constexpr size_t kJpegSegmentParameterLengthSize =;

// The first three bytes of all JPEG files is a StartOfImage marker (two bytes) followed by the
// first byte of the next marker.
static constexpr uint8_t kJpegSig[] =;

// ICC profile segment marker and signature.
static constexpr uint32_t kICCMarker =;
static constexpr uint32_t kICCMarkerHeaderSize =;
static constexpr uint32_t kICCMarkerIndexSize =;
static constexpr uint8_t kICCSig[] =;

// XMP segment marker and signature.
static constexpr uint32_t kXMPMarker =;
static constexpr uint8_t kXMPStandardSig[] =;
static constexpr uint8_t kXMPExtendedSig[] =;

// EXIF segment marker and signature.
static constexpr uint32_t kExifMarker =;
constexpr uint8_t kExifSig[] =;

// MPF segment marker and signature.
static constexpr uint32_t kMpfMarker =;
static constexpr uint8_t kMpfSig[] =;

// ISO 21496-1 marker and signature.
static constexpr uint32_t kISOGainmapMarker =;
static constexpr uint8_t kISOGainmapSig[] =;

#endif