Defines |
| #define | MAX_COMP 4 /* ever needed maximum number of components in texel */ |
| #define | MAX_VECT 4 /* ever needed maximum number of base vectors to find */ |
| #define | N_TEXELS 32 /* number of texels in a block (always 32) */ |
| #define | LL_N_REP 50 /* number of iterations in lloyd's vq */ |
| #define | LL_RMS_D 10 /* fault tolerance (maximum delta) */ |
| #define | LL_RMS_E 255 /* fault tolerance (maximum error) */ |
| #define | ALPHA_TS 2 /* alpha threshold: (255 - ALPHA_TS) deemed opaque */ |
| #define | ISTBLACK(v) (*((dword *)(v)) == 0) |
| #define | COPY_4UBV(DST, SRC) *((dword *)(DST)) = *((dword *)(SRC)) |
| #define | CC_SEL(cc, which) (((dword *)(cc))[(which) / 32] >> ((which) & 31)) |
| #define | UP5(c) _rgb_scale_5[(c) & 31] |
| #define | UP6(c, b) _rgb_scale_6[(((c) & 31) << 1) | ((b) & 1)] |
| #define | LERP(n, t, c0, c1) (((n) - (t)) * (c0) + (t) * (c1) + (n) / 2) / (n) |
| #define | ZERO_4UBV(v) *((dword *)(v)) = 0 |
Functions |
| static int | fxt1_bestcol (float vec[][MAX_COMP], int nv, byte input[MAX_COMP], int nc) |
| static int | fxt1_worst (float vec[MAX_COMP], byte input[N_TEXELS][MAX_COMP], int nc, int n) |
| static int | fxt1_variance (double variance[MAX_COMP], byte input[N_TEXELS][MAX_COMP], int nc, int n) |
| static int | fxt1_choose (float vec[][MAX_COMP], int nv, byte input[N_TEXELS][MAX_COMP], int nc, int n) |
| static int | fxt1_lloyd (float vec[][MAX_COMP], int nv, byte input[N_TEXELS][MAX_COMP], int nc, int n) |
| static void | fxt1_quantize_CHROMA (dword *cc, byte input[N_TEXELS][MAX_COMP]) |
| static void | fxt1_quantize_ALPHA0 (dword *cc, byte input[N_TEXELS][MAX_COMP], byte reord[N_TEXELS][MAX_COMP], int n) |
| static void | fxt1_quantize_ALPHA1 (dword *cc, byte input[N_TEXELS][MAX_COMP]) |
| static void | fxt1_quantize_HI (dword *cc, byte input[N_TEXELS][MAX_COMP], byte reord[N_TEXELS][MAX_COMP], int n) |
| static void | fxt1_quantize_MIXED1 (dword *cc, byte input[N_TEXELS][MAX_COMP]) |
| static void | fxt1_quantize_MIXED0 (dword *cc, byte input[N_TEXELS][MAX_COMP]) |
| static void | fxt1_quantize (dword *cc, const byte *lines[], int comps) |
| TAPI int TAPIENTRY | fxt1_encode (int width, int height, int comps, const void *source, int srcRowStride, void *dest, int destRowStride) |
| static void | fxt1_decode_1HI (const byte *code, int t, byte *rgba) |
| static void | fxt1_decode_1CHROMA (const byte *code, int t, byte *rgba) |
| static void | fxt1_decode_1MIXED (const byte *code, int t, byte *rgba) |
| static void | fxt1_decode_1ALPHA (const byte *code, int t, byte *rgba) |
| TAPI void TAPIENTRY | fxt1_decode_1 (const void *texture, int stride, int i, int j, byte *rgba) |
Variables |
| static const byte | _rgb_scale_5 [] |
| static const byte | _rgb_scale_6 [] |