#ifndef AVIF_H
#define AVIF_H

#include <cstdarg>
#include <cstddef>
#include <cstdint>
#include <cstdlib>
#include <ostream>
#include <new>

template <typename T>
using Box = T*;
namespace crabbyavif {
struct avifImage;
struct avifIO;
}


namespace crabbyavif {

constexpr static const size_t CRABBY_AVIF_MAX_AV1_LAYER_COUNT = 4;

constexpr static const uint32_t CRABBY_AVIF_DEFAULT_IMAGE_SIZE_LIMIT = (16384 * 16384);

constexpr static const uint32_t CRABBY_AVIF_DEFAULT_IMAGE_DIMENSION_LIMIT = 32768;

constexpr static const uint32_t CRABBY_AVIF_DEFAULT_IMAGE_COUNT_LIMIT = ((12 * 3600) * 60);

constexpr static const int CRABBY_AVIF_TRUE = 1;

constexpr static const int CRABBY_AVIF_FALSE = 0;

constexpr static const uint32_t AVIF_STRICT_DISABLED = 0;

constexpr static const uint32_t AVIF_STRICT_PIXI_REQUIRED = (1 << 0);

constexpr static const uint32_t AVIF_STRICT_CLAP_VALID = (1 << 1);

constexpr static const uint32_t AVIF_STRICT_ALPHA_ISPE_REQUIRED = (1 << 2);

constexpr static const uint32_t AVIF_STRICT_ENABLED = ((AVIF_STRICT_PIXI_REQUIRED | AVIF_STRICT_CLAP_VALID) | AVIF_STRICT_ALPHA_ISPE_REQUIRED);

constexpr static const uint32_t AVIF_IMAGE_CONTENT_NONE = 0;

constexpr static const uint32_t AVIF_IMAGE_CONTENT_COLOR_AND_ALPHA = ((1 << 0) | (1 << 1));

constexpr static const uint32_t AVIF_IMAGE_CONTENT_GAIN_MAP = (1 << 2);

constexpr static const uint32_t AVIF_IMAGE_CONTENT_ALL = (AVIF_IMAGE_CONTENT_COLOR_AND_ALPHA | AVIF_IMAGE_CONTENT_GAIN_MAP);

constexpr static const size_t CRABBY_AVIF_DIAGNOSTICS_ERROR_BUFFER_SIZE = 256;

constexpr static const size_t CRABBY_AVIF_PLANE_COUNT_YUV = 3;

constexpr static const int32_t CRABBY_AVIF_REPETITION_COUNT_INFINITE = -1;

constexpr static const int32_t CRABBY_AVIF_REPETITION_COUNT_UNKNOWN = -2;

constexpr static const uint32_t AVIF_TRANSFORM_NONE = 0;

constexpr static const uint32_t AVIF_TRANSFORM_PASP = (1 << 0);

constexpr static const uint32_t AVIF_TRANSFORM_CLAP = (1 << 1);

constexpr static const uint32_t AVIF_TRANSFORM_IROT = (1 << 2);

constexpr static const uint32_t AVIF_TRANSFORM_IMIR = (1 << 3);

constexpr static const uint32_t AVIF_COLOR_PRIMARIES_BT709 = 1;

constexpr static const uint32_t AVIF_COLOR_PRIMARIES_IEC61966_2_4 = 1;

constexpr static const uint32_t AVIF_COLOR_PRIMARIES_BT2100 = 9;

constexpr static const uint32_t AVIF_COLOR_PRIMARIES_DCI_P3 = 12;

constexpr static const uint32_t AVIF_TRANSFER_CHARACTERISTICS_SMPTE2084 = 16;

enum AndroidMediaCodecOutputColorFormat : int32_t {
    ANDROID_MEDIA_CODEC_OUTPUT_COLOR_FORMAT_YUV420_FLEXIBLE = 2135033992,
    ANDROID_MEDIA_CODEC_OUTPUT_COLOR_FORMAT_P010 = 54,
};

enum avifChromaDownsampling {
    AVIF_CHROMA_DOWNSAMPLING_AUTOMATIC,
    AVIF_CHROMA_DOWNSAMPLING_FASTEST,
    AVIF_CHROMA_DOWNSAMPLING_BEST_QUALITY,
    AVIF_CHROMA_DOWNSAMPLING_AVERAGE,
    AVIF_CHROMA_DOWNSAMPLING_SHARP_YUV,
};

enum avifChromaSamplePosition {
    AVIF_CHROMA_SAMPLE_POSITION_UNKNOWN = 0,
    AVIF_CHROMA_SAMPLE_POSITION_VERTICAL = 1,
    AVIF_CHROMA_SAMPLE_POSITION_COLOCATED = 2,
    AVIF_CHROMA_SAMPLE_POSITION_RESERVED = 3,
};

enum avifChromaUpsampling {
    AVIF_CHROMA_UPSAMPLING_AUTOMATIC,
    AVIF_CHROMA_UPSAMPLING_FASTEST,
    AVIF_CHROMA_UPSAMPLING_BEST_QUALITY,
    AVIF_CHROMA_UPSAMPLING_NEAREST,
    AVIF_CHROMA_UPSAMPLING_BILINEAR,
};

enum avifColorPrimaries : uint16_t {
    AVIF_COLOR_PRIMARIES_UNKNOWN = 0,
    AVIF_COLOR_PRIMARIES_SRGB = 1,
    AVIF_COLOR_PRIMARIES_UNSPECIFIED = 2,
    AVIF_COLOR_PRIMARIES_BT470M = 4,
    AVIF_COLOR_PRIMARIES_BT470BG = 5,
    AVIF_COLOR_PRIMARIES_BT601 = 6,
    AVIF_COLOR_PRIMARIES_SMPTE240 = 7,
    AVIF_COLOR_PRIMARIES_GENERIC_FILM = 8,
    AVIF_COLOR_PRIMARIES_BT2020 = 9,
    AVIF_COLOR_PRIMARIES_XYZ = 10,
    AVIF_COLOR_PRIMARIES_SMPTE431 = 11,
    AVIF_COLOR_PRIMARIES_SMPTE432 = 12,
    AVIF_COLOR_PRIMARIES_EBU3213 = 22,
};

enum CompressionFormat {
    COMPRESSION_FORMAT_AVIF = 0,
    COMPRESSION_FORMAT_HEIC = 1,
};

enum avifRGBFormat {
    AVIF_RGB_FORMAT_RGB,
    AVIF_RGB_FORMAT_RGBA,
    AVIF_RGB_FORMAT_ARGB,
    AVIF_RGB_FORMAT_BGR,
    AVIF_RGB_FORMAT_BGRA,
    AVIF_RGB_FORMAT_ABGR,
    AVIF_RGB_FORMAT_RGB565,
    AVIF_RGB_FORMAT_RGBA1010102,
};

enum avifMatrixCoefficients : uint16_t {
    AVIF_MATRIX_COEFFICIENTS_IDENTITY = 0,
    AVIF_MATRIX_COEFFICIENTS_BT709 = 1,
    AVIF_MATRIX_COEFFICIENTS_UNSPECIFIED = 2,
    AVIF_MATRIX_COEFFICIENTS_RESERVED = 3,
    AVIF_MATRIX_COEFFICIENTS_FCC = 4,
    AVIF_MATRIX_COEFFICIENTS_BT470BG = 5,
    AVIF_MATRIX_COEFFICIENTS_BT601 = 6,
    AVIF_MATRIX_COEFFICIENTS_SMPTE240 = 7,
    AVIF_MATRIX_COEFFICIENTS_YCGCO = 8,
    AVIF_MATRIX_COEFFICIENTS_BT2020_NCL = 9,
    AVIF_MATRIX_COEFFICIENTS_BT2020_CL = 10,
    AVIF_MATRIX_COEFFICIENTS_SMPTE2085 = 11,
    AVIF_MATRIX_COEFFICIENTS_CHROMA_DERIVED_NCL = 12,
    AVIF_MATRIX_COEFFICIENTS_CHROMA_DERIVED_CL = 13,
    AVIF_MATRIX_COEFFICIENTS_ICTCP = 14,
    AVIF_MATRIX_COEFFICIENTS_YCGCO_RE = 16,
    AVIF_MATRIX_COEFFICIENTS_YCGCO_RO = 17,
};

enum avifPixelFormat {
    AVIF_PIXEL_FORMAT_NONE = 0,
    AVIF_PIXEL_FORMAT_YUV444 = 1,
    AVIF_PIXEL_FORMAT_YUV422 = 2,
    AVIF_PIXEL_FORMAT_YUV420 = 3,
    AVIF_PIXEL_FORMAT_YUV400 = 4,
    AVIF_PIXEL_FORMAT_ANDROID_P010 = 5,
    AVIF_PIXEL_FORMAT_ANDROID_NV12 = 6,
    AVIF_PIXEL_FORMAT_ANDROID_NV21 = 7,
    AVIF_PIXEL_FORMAT_COUNT,
};

enum avifProgressiveState {
    AVIF_PROGRESSIVE_STATE_UNAVAILABLE = 0,
    AVIF_PROGRESSIVE_STATE_AVAILABLE = 1,
    AVIF_PROGRESSIVE_STATE_ACTIVE = 2,
};

enum avifDecoderSource {
    AVIF_DECODER_SOURCE_AUTO = 0,
    AVIF_DECODER_SOURCE_PRIMARY_ITEM = 1,
    AVIF_DECODER_SOURCE_TRACKS = 2,
};

enum avifTransferCharacteristics : uint16_t {
    AVIF_TRANSFER_CHARACTERISTICS_UNKNOWN = 0,
    AVIF_TRANSFER_CHARACTERISTICS_BT709 = 1,
    AVIF_TRANSFER_CHARACTERISTICS_UNSPECIFIED = 2,
    AVIF_TRANSFER_CHARACTERISTICS_RESERVED = 3,
    AVIF_TRANSFER_CHARACTERISTICS_BT470M = 4,
    AVIF_TRANSFER_CHARACTERISTICS_BT470BG = 5,
    AVIF_TRANSFER_CHARACTERISTICS_BT601 = 6,
    AVIF_TRANSFER_CHARACTERISTICS_SMPTE240 = 7,
    AVIF_TRANSFER_CHARACTERISTICS_LINEAR = 8,
    AVIF_TRANSFER_CHARACTERISTICS_LOG100 = 9,
    AVIF_TRANSFER_CHARACTERISTICS_LOG100_SQRT10 = 10,
    AVIF_TRANSFER_CHARACTERISTICS_IEC61966 = 11,
    AVIF_TRANSFER_CHARACTERISTICS_BT1361 = 12,
    AVIF_TRANSFER_CHARACTERISTICS_SRGB = 13,
    AVIF_TRANSFER_CHARACTERISTICS_BT2020_10BIT = 14,
    AVIF_TRANSFER_CHARACTERISTICS_BT2020_12BIT = 15,
    AVIF_TRANSFER_CHARACTERISTICS_PQ = 16,
    AVIF_TRANSFER_CHARACTERISTICS_SMPTE428 = 17,
    AVIF_TRANSFER_CHARACTERISTICS_HLG = 18,
};

enum avifRange {
    AVIF_RANGE_LIMITED = 0,
    AVIF_RANGE_FULL = 1,
};

enum avifChannelIndex {
    AVIF_CHAN_Y = 0,
    AVIF_CHAN_U = 1,
    AVIF_CHAN_V = 2,
    AVIF_CHAN_A = 3,
};

enum avifCodecChoice {
    AVIF_CODEC_CHOICE_AUTO = 0,
    AVIF_CODEC_CHOICE_AOM = 1,
    AVIF_CODEC_CHOICE_DAV1D = 2,
    AVIF_CODEC_CHOICE_LIBGAV1 = 3,
    AVIF_CODEC_CHOICE_RAV1E = 4,
    AVIF_CODEC_CHOICE_SVT = 5,
    AVIF_CODEC_CHOICE_AVM = 6,
};

enum avifCodecFlag {
    AVIF_CODEC_FLAG_CAN_DECODE = (1 << 0),
    AVIF_CODEC_FLAG_CAN_ENCODE = (1 << 1),
};

enum avifHeaderFormat {
    AVIF_HEADER_FULL,
    AVIF_HEADER_REDUCED,
};

enum avifPlanesFlag {
    AVIF_PLANES_YUV = (1 << 0),
    AVIF_PLANES_A = (1 << 1),
    AVIF_PLANES_ALL = 255,
};

enum avifResult {
    AVIF_RESULT_OK = 0,
    AVIF_RESULT_UNKNOWN_ERROR = 1,
    AVIF_RESULT_INVALID_FTYP = 2,
    AVIF_RESULT_NO_CONTENT = 3,
    AVIF_RESULT_NO_YUV_FORMAT_SELECTED = 4,
    AVIF_RESULT_REFORMAT_FAILED = 5,
    AVIF_RESULT_UNSUPPORTED_DEPTH = 6,
    AVIF_RESULT_ENCODE_COLOR_FAILED = 7,
    AVIF_RESULT_ENCODE_ALPHA_FAILED = 8,
    AVIF_RESULT_BMFF_PARSE_FAILED = 9,
    AVIF_RESULT_MISSING_IMAGE_ITEM = 10,
    AVIF_RESULT_DECODE_COLOR_FAILED = 11,
    AVIF_RESULT_DECODE_ALPHA_FAILED = 12,
    AVIF_RESULT_COLOR_ALPHA_SIZE_MISMATCH = 13,
    AVIF_RESULT_ISPE_SIZE_MISMATCH = 14,
    AVIF_RESULT_NO_CODEC_AVAILABLE = 15,
    AVIF_RESULT_NO_IMAGES_REMAINING = 16,
    AVIF_RESULT_INVALID_EXIF_PAYLOAD = 17,
    AVIF_RESULT_INVALID_IMAGE_GRID = 18,
    AVIF_RESULT_INVALID_CODEC_SPECIFIC_OPTION = 19,
    AVIF_RESULT_TRUNCATED_DATA = 20,
    AVIF_RESULT_IO_NOT_SET = 21,
    AVIF_RESULT_IO_ERROR = 22,
    AVIF_RESULT_WAITING_ON_IO = 23,
    AVIF_RESULT_INVALID_ARGUMENT = 24,
    AVIF_RESULT_NOT_IMPLEMENTED = 25,
    AVIF_RESULT_OUT_OF_MEMORY = 26,
    AVIF_RESULT_CANNOT_CHANGE_SETTING = 27,
    AVIF_RESULT_INCOMPATIBLE_IMAGE = 28,
    AVIF_RESULT_ENCODE_GAIN_MAP_FAILED = 29,
    AVIF_RESULT_DECODE_GAIN_MAP_FAILED = 30,
    AVIF_RESULT_INVALID_TONE_MAPPED_IMAGE = 31,
};

struct Decoder;

using avifBool = int;

using avifStrictFlags = uint32_t;

struct avifRWData {
    uint8_t *data;
    size_t size;
};

struct ContentLightLevelInformation {
    uint16_t maxCLL;
    uint16_t maxPALL;
};

using avifContentLightLevelInformationBox = ContentLightLevelInformation;

using avifTransformFlags = uint32_t;

struct PixelAspectRatio {
    uint32_t hSpacing;
    uint32_t vSpacing;
};

using avifPixelAspectRatioBox = PixelAspectRatio;

struct avifCleanApertureBox {
    uint32_t widthN;
    uint32_t widthD;
    uint32_t heightN;
    uint32_t heightD;
    uint32_t horizOffN;
    uint32_t horizOffD;
    uint32_t vertOffN;
    uint32_t vertOffD;
};

struct avifImageRotation {
    uint8_t angle;
};

struct avifImageMirror {
    uint8_t axis;
};

struct Fraction {
    int32_t n;
    uint32_t d;
};

using avifSignedFraction = Fraction;

struct UFraction {
    uint32_t n;
    uint32_t d;
};

using avifUnsignedFraction = UFraction;

struct avifGainMap {
    avifImage *image;
    avifSignedFraction gainMapMin[3];
    avifSignedFraction gainMapMax[3];
    avifUnsignedFraction gainMapGamma[3];
    avifSignedFraction baseOffset[3];
    avifSignedFraction alternateOffset[3];
    avifUnsignedFraction baseHdrHeadroom;
    avifUnsignedFraction alternateHdrHeadroom;
    avifBool useBaseColorSpace;
    avifRWData altICC;
    avifColorPrimaries altColorPrimaries;
    avifTransferCharacteristics altTransferCharacteristics;
    avifMatrixCoefficients altMatrixCoefficients;
    avifRange altYUVRange;
    uint32_t altDepth;
    uint32_t altPlaneCount;
    avifContentLightLevelInformationBox altCLLI;
};

struct avifImage {
    uint32_t width;
    uint32_t height;
    uint32_t depth;
    avifPixelFormat yuvFormat;
    avifRange yuvRange;
    avifChromaSamplePosition yuvChromaSamplePosition;
    uint8_t *yuvPlanes[CRABBY_AVIF_PLANE_COUNT_YUV];
    uint32_t yuvRowBytes[CRABBY_AVIF_PLANE_COUNT_YUV];
    avifBool imageOwnsYUVPlanes;
    uint8_t *alphaPlane;
    uint32_t alphaRowBytes;
    avifBool imageOwnsAlphaPlane;
    avifBool alphaPremultiplied;
    avifRWData icc;
    avifColorPrimaries colorPrimaries;
    avifTransferCharacteristics transferCharacteristics;
    avifMatrixCoefficients matrixCoefficients;
    avifContentLightLevelInformationBox clli;
    avifTransformFlags transformFlags;
    avifPixelAspectRatioBox pasp;
    avifCleanApertureBox clap;
    avifImageRotation irot;
    avifImageMirror imir;
    avifRWData exif;
    avifRWData xmp;
    avifGainMap *gainMap;
};

struct avifImageTiming {
    uint64_t timescale;
    double pts;
    uint64_t ptsInTimescales;
    double duration;
    uint64_t durationInTimescales;
};

struct avifIOStats {
    size_t colorOBUSize;
    size_t alphaOBUSize;
};

struct avifDiagnostics {
    char error[CRABBY_AVIF_DIAGNOSTICS_ERROR_BUFFER_SIZE];
};

struct avifDecoderData {

};

using avifImageContentTypeFlags = uint32_t;

struct avifDecoder {
    avifCodecChoice codecChoice;
    int32_t maxThreads;
    avifDecoderSource requestedSource;
    avifBool allowProgressive;
    avifBool allowIncremental;
    avifBool ignoreExif;
    avifBool ignoreXMP;
    uint32_t imageSizeLimit;
    uint32_t imageDimensionLimit;
    uint32_t imageCountLimit;
    avifStrictFlags strictFlags;
    avifImage *image;
    int32_t imageIndex;
    int32_t imageCount;
    avifProgressiveState progressiveState;
    avifImageTiming imageTiming;
    uint64_t timescale;
    double duration;
    uint64_t durationInTimescales;
    int32_t repetitionCount;
    avifBool alphaPresent;
    avifIOStats ioStats;
    avifDiagnostics diag;
    avifDecoderData *data;
    avifImageContentTypeFlags imageContentToDecode;
    avifBool imageSequenceTrackPresent;
    AndroidMediaCodecOutputColorFormat androidMediaCodecOutputColorFormat;
    CompressionFormat compressionFormat;
    Box<Decoder> rust_decoder;
    avifImage image_object;
    avifGainMap gainmap_object;
    avifImage gainmap_image_object;
};

using avifIODestroyFunc = void(*)(avifIO *io);

struct avifROData {
    const uint8_t *data;
    size_t size;
};

using avifIOReadFunc = avifResult(*)(avifIO *io,
                                     uint32_t readFlags,
                                     uint64_t offset,
                                     size_t size,
                                     avifROData *out);

using avifIOWriteFunc = avifResult(*)(avifIO *io,
                                      uint32_t writeFlags,
                                      uint64_t offset,
                                      const uint8_t *data,
                                      size_t size);

struct avifIO {
    avifIODestroyFunc destroy;
    avifIOReadFunc read;
    avifIOWriteFunc write;
    uint64_t sizeHint;
    avifBool persistent;
    void *data;
};

struct Extent {
    uint64_t offset;
    size_t size;
};

using avifExtent = Extent;

using avifPlanesFlags = uint32_t;

struct CropRect {
    uint32_t x;
    uint32_t y;
    uint32_t width;
    uint32_t height;
};

using avifCropRect = CropRect;

struct avifRGBImage {
    uint32_t width;
    uint32_t height;
    uint32_t depth;
    avifRGBFormat format;
    avifChromaUpsampling chromaUpsampling;
    avifChromaDownsampling chromaDownsampling;
    bool ignoreAlpha;
    bool alphaPremultiplied;
    bool isFloat;
    int32_t maxThreads;
    uint8_t *pixels;
    uint32_t rowBytes;
};

struct avifPixelFormatInfo {
    avifBool monochrome;
    int chromaShiftX;
    int chromaShiftY;
};

using avifCodecFlags = uint32_t;











extern "C" {

avifDecoder *crabby_avifDecoderCreate();

void crabby_avifDecoderSetIO(avifDecoder *decoder, avifIO *io);

avifResult crabby_avifDecoderSetIOFile(avifDecoder *decoder, const char *filename);

avifResult crabby_avifDecoderSetIOMemory(avifDecoder *decoder, const uint8_t *data, size_t size);

avifResult crabby_avifDecoderSetSource(avifDecoder *decoder, avifDecoderSource source);

avifResult crabby_avifDecoderParse(avifDecoder *decoder);

avifResult crabby_avifDecoderNextImage(avifDecoder *decoder);

avifResult crabby_avifDecoderNthImage(avifDecoder *decoder, uint32_t frameIndex);

avifResult crabby_avifDecoderNthImageTiming(const avifDecoder *decoder,
                                            uint32_t frameIndex,
                                            avifImageTiming *outTiming);

void crabby_avifDecoderDestroy(avifDecoder *decoder);

avifResult crabby_avifDecoderRead(avifDecoder *decoder, avifImage *image);

avifResult crabby_avifDecoderReadMemory(avifDecoder *decoder,
                                        avifImage *image,
                                        const uint8_t *data,
                                        size_t size);

avifResult crabby_avifDecoderReadFile(avifDecoder *decoder, avifImage *image, const char *filename);

avifBool crabby_avifDecoderIsKeyframe(const avifDecoder *decoder, uint32_t frameIndex);

uint32_t crabby_avifDecoderNearestKeyframe(const avifDecoder *decoder, uint32_t frameIndex);

uint32_t crabby_avifDecoderDecodedRowCount(const avifDecoder *decoder);

avifResult crabby_avifDecoderNthImageMaxExtent(const avifDecoder *decoder,
                                               uint32_t frameIndex,
                                               avifExtent *outExtent);

avifBool crabby_avifPeekCompatibleFileType(const avifROData *input);

avifImage *crabby_avifImageCreateEmpty();

avifImage *crabby_avifImageCreate(uint32_t width,
                                  uint32_t height,
                                  uint32_t depth,
                                  avifPixelFormat yuvFormat);

avifResult crabby_avifImageCopy(avifImage *dstImage,
                                const avifImage *srcImage,
                                avifPlanesFlags planes);

avifResult crabby_avifImageAllocatePlanes(avifImage *image, avifPlanesFlags planes);

void crabby_avifImageFreePlanes(avifImage *image, avifPlanesFlags planes);

void crabby_avifImageDestroy(avifImage *image);

avifBool crabby_avifImageUsesU16(const avifImage *image);

avifBool crabby_avifImageIsOpaque(const avifImage *image);

uint8_t *crabby_avifImagePlane(const avifImage *image, int channel);

uint32_t crabby_avifImagePlaneRowBytes(const avifImage *image, int channel);

uint32_t crabby_avifImagePlaneWidth(const avifImage *image, int channel);

uint32_t crabby_avifImagePlaneHeight(const avifImage *image, int channel);

avifResult crabby_avifImageSetViewRect(avifImage *dstImage,
                                       const avifImage *srcImage,
                                       const avifCropRect *rect);

avifResult crabby_avifRWDataRealloc(avifRWData *raw, size_t newSize);

avifResult crabby_avifRWDataSet(avifRWData *raw, const uint8_t *data, size_t size);

void crabby_avifRWDataFree(avifRWData *raw);

void cioDestroy(avifIO *_io);

avifResult cioRead(avifIO *io, uint32_t _readFlags, uint64_t offset, size_t size, avifROData *out);

avifResult cioWrite(avifIO *_io,
                    uint32_t _writeFlags,
                    uint64_t _offset,
                    const uint8_t *_data,
                    size_t _size);

avifIO *crabby_avifIOCreateMemoryReader(const uint8_t *data, size_t size);

avifIO *crabby_avifIOCreateFileReader(const char *filename);

void crabby_avifIODestroy(avifIO *io);

void crabby_avifRGBImageSetDefaults(avifRGBImage *rgb, const avifImage *image);

avifResult crabby_avifImageYUVToRGB(const avifImage *image, avifRGBImage *rgb);

avifResult crabby_avifImageScale(avifImage *image,
                                 uint32_t dstWidth,
                                 uint32_t dstHeight,
                                 avifDiagnostics *_diag);

const char *crabby_avifResultToString(avifResult res);

avifBool crabby_avifCropRectConvertCleanApertureBox(avifCropRect *cropRect,
                                                    const avifCleanApertureBox *clap,
                                                    uint32_t imageW,
                                                    uint32_t imageH,
                                                    avifPixelFormat yuvFormat,
                                                    avifDiagnostics *_diag);

void crabby_avifGetPixelFormatInfo(avifPixelFormat format, avifPixelFormatInfo *info);

void crabby_avifDiagnosticsClearError(avifDiagnostics *diag);

void *crabby_avifAlloc(size_t size);

void crabby_avifFree(void *p);

} // extern "C"

} // namespace crabbyavif

#endif // AVIF_H
