MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / idct4row

Function idct4row

libavcodec/simple_idct.c:520–537  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

518#define R3 R_FIX(0.5)
519#define R_SHIFT 11
520static inline void idct4row(DCTELEM *row)
521{
522 int c0, c1, c2, c3, a0, a1, a2, a3;
523 //const uint8_t *cm = ff_cropTbl + MAX_NEG_CROP;
524
525 a0 = row[0];
526 a1 = row[1];
527 a2 = row[2];
528 a3 = row[3];
529 c0 = (a0 + a2)*R3 + (1 << (R_SHIFT - 1));
530 c2 = (a0 - a2)*R3 + (1 << (R_SHIFT - 1));
531 c1 = a1 * R1 + a3 * R2;
532 c3 = a1 * R2 - a3 * R1;
533 row[0]= (c0 + c1) >> R_SHIFT;
534 row[1]= (c2 + c3) >> R_SHIFT;
535 row[2]= (c2 - c3) >> R_SHIFT;
536 row[3]= (c0 - c1) >> R_SHIFT;
537}
538
539void ff_simple_idct84_add(uint8_t *dest, int line_size, DCTELEM *block)
540{

Callers 2

ff_simple_idct48_addFunction · 0.85
ff_simple_idct44_addFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected