#include <assert.h>
#include <stdlib.h>
#include "src/dsp/dsp.h"
#include "src/enc/vp8i_enc.h"
static WEBP_INLINE uint8_t clip_8b(int v) { … }
#if !WEBP_NEON_OMIT_C_CODE
static WEBP_INLINE int clip_max(int v, int max) { … }
#endif
const int VP8DspScan[16 + 4 + 4] = …;
void VP8SetHistogramData(const int distribution[MAX_COEFF_THRESH + 1],
VP8Histogram* const histo) { … }
#if !WEBP_NEON_OMIT_C_CODE
static void CollectHistogram_C(const uint8_t* ref, const uint8_t* pred,
int start_block, int end_block,
VP8Histogram* const histo) { … }
#endif
static uint8_t clip1[255 + 510 + 1];
static volatile int tables_ok = …;
static WEBP_TSAN_IGNORE_FUNCTION void InitTables(void) { … }
#if !WEBP_NEON_OMIT_C_CODE
#define STORE …
static WEBP_INLINE void ITransformOne(const uint8_t* ref, const int16_t* in,
uint8_t* dst) { … }
static void ITransform_C(const uint8_t* ref, const int16_t* in, uint8_t* dst,
int do_two) { … }
static void FTransform_C(const uint8_t* src, const uint8_t* ref, int16_t* out) { … }
#endif
static void FTransform2_C(const uint8_t* src, const uint8_t* ref,
int16_t* out) { … }
#if !WEBP_NEON_OMIT_C_CODE
static void FTransformWHT_C(const int16_t* in, int16_t* out) { … }
#endif
#undef STORE
static WEBP_INLINE void Fill(uint8_t* dst, int value, int size) { … }
static WEBP_INLINE void VerticalPred(uint8_t* dst,
const uint8_t* top, int size) { … }
static WEBP_INLINE void HorizontalPred(uint8_t* dst,
const uint8_t* left, int size) { … }
static WEBP_INLINE void TrueMotion(uint8_t* dst, const uint8_t* left,
const uint8_t* top, int size) { … }
static WEBP_INLINE void DCMode(uint8_t* dst, const uint8_t* left,
const uint8_t* top,
int size, int round, int shift) { … }
static void IntraChromaPreds_C(uint8_t* dst, const uint8_t* left,
const uint8_t* top) { … }
static void Intra16Preds_C(uint8_t* dst,
const uint8_t* left, const uint8_t* top) { … }
#define DST …
#define AVG3 …
#define AVG2 …
static void VE4(uint8_t* dst, const uint8_t* top) { … }
static void HE4(uint8_t* dst, const uint8_t* top) { … }
static void DC4(uint8_t* dst, const uint8_t* top) { … }
static void RD4(uint8_t* dst, const uint8_t* top) { … }
static void LD4(uint8_t* dst, const uint8_t* top) { … }
static void VR4(uint8_t* dst, const uint8_t* top) { … }
static void VL4(uint8_t* dst, const uint8_t* top) { … }
static void HU4(uint8_t* dst, const uint8_t* top) { … }
static void HD4(uint8_t* dst, const uint8_t* top) { … }
static void TM4(uint8_t* dst, const uint8_t* top) { … }
#undef DST
#undef AVG3
#undef AVG2
static void Intra4Preds_C(uint8_t* dst, const uint8_t* top) { … }
#if !WEBP_NEON_OMIT_C_CODE
static WEBP_INLINE int GetSSE(const uint8_t* a, const uint8_t* b,
int w, int h) { … }
static int SSE16x16_C(const uint8_t* a, const uint8_t* b) { … }
static int SSE16x8_C(const uint8_t* a, const uint8_t* b) { … }
static int SSE8x8_C(const uint8_t* a, const uint8_t* b) { … }
static int SSE4x4_C(const uint8_t* a, const uint8_t* b) { … }
#endif
static void Mean16x4_C(const uint8_t* ref, uint32_t dc[4]) { … }
#if !WEBP_NEON_OMIT_C_CODE
static int TTransform(const uint8_t* in, const uint16_t* w) { … }
static int Disto4x4_C(const uint8_t* const a, const uint8_t* const b,
const uint16_t* const w) { … }
static int Disto16x16_C(const uint8_t* const a, const uint8_t* const b,
const uint16_t* const w) { … }
#endif
static const uint8_t kZigzag[16] = …;
static int QuantizeBlock_C(int16_t in[16], int16_t out[16],
const VP8Matrix* const mtx) { … }
#if !WEBP_NEON_OMIT_C_CODE || WEBP_NEON_WORK_AROUND_GCC
static int Quantize2Blocks_C(int16_t in[32], int16_t out[32],
const VP8Matrix* const mtx) { … }
#endif
static WEBP_INLINE void Copy(const uint8_t* src, uint8_t* dst, int w, int h) { … }
static void Copy4x4_C(const uint8_t* src, uint8_t* dst) { … }
static void Copy16x8_C(const uint8_t* src, uint8_t* dst) { … }
VP8CHisto VP8CollectHistogram;
VP8Idct VP8ITransform;
VP8Fdct VP8FTransform;
VP8Fdct VP8FTransform2;
VP8WHT VP8FTransformWHT;
VP8Intra4Preds VP8EncPredLuma4;
VP8IntraPreds VP8EncPredLuma16;
VP8IntraPreds VP8EncPredChroma8;
VP8Metric VP8SSE16x16;
VP8Metric VP8SSE8x8;
VP8Metric VP8SSE16x8;
VP8Metric VP8SSE4x4;
VP8WMetric VP8TDisto4x4;
VP8WMetric VP8TDisto16x16;
VP8MeanMetric VP8Mean16x4;
VP8QuantizeBlock VP8EncQuantizeBlock;
VP8Quantize2Blocks VP8EncQuantize2Blocks;
VP8QuantizeBlockWHT VP8EncQuantizeBlockWHT;
VP8BlockCopy VP8Copy4x4;
VP8BlockCopy VP8Copy16x8;
extern VP8CPUInfo VP8GetCPUInfo;
extern void VP8EncDspInitSSE2(void);
extern void VP8EncDspInitSSE41(void);
extern void VP8EncDspInitNEON(void);
extern void VP8EncDspInitMIPS32(void);
extern void VP8EncDspInitMIPSdspR2(void);
extern void VP8EncDspInitMSA(void);
WEBP_DSP_INIT_FUNC(VP8EncDspInit) { … }