FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions | Variables
idct_altivec.c File Reference
#include <stdlib.h>
#include <string.h>
#include "config.h"
#include "libavutil/ppc/types_altivec.h"
#include "dsputil_altivec.h"

Go to the source code of this file.

Macros

#define IDCT_HALF
 
#define IDCT
 
#define COPY(dest, src)
 
#define ADD(dest, src, perm)
 

Functions

void ff_idct_put_altivec (uint8_t *dest, int stride, int16_t *blk)
 
void ff_idct_add_altivec (uint8_t *dest, int stride, int16_t *blk)
 

Variables

static const vec_s16 constants [5]
 

Macro Definition Documentation

#define IDCT_HALF

Definition at line 47 of file idct_altivec.c.

#define IDCT

Definition at line 83 of file idct_altivec.c.

Referenced by ff_idct_add_altivec(), and ff_idct_put_altivec().

#define COPY (   dest,
  src 
)
Value:
tmp = vec_packsu (src, src); \
vec_ste ((vec_u32)tmp, 0, (unsigned int *)dest); \
vec_ste ((vec_u32)tmp, 4, (unsigned int *)dest);
#define ADD (   dest,
  src,
  perm 
)
Value:
/* *(uint64_t *)&tmp = *(uint64_t *)dest; */ \
tmp = vec_ld (0, dest); \
tmp2 = (vec_s16)vec_perm (tmp, (vec_u8)zero, perm); \
tmp3 = vec_adds (tmp2, src); \
tmp = vec_packsu (tmp3, tmp3); \
vec_ste ((vec_u32)tmp, 0, (unsigned int *)dest); \
vec_ste ((vec_u32)tmp, 4, (unsigned int *)dest);

Function Documentation

void ff_idct_put_altivec ( uint8_t dest,
int  stride,
int16_t *  blk 
)

Definition at line 160 of file idct_altivec.c.

Referenced by ff_dsputil_init_ppc().

void ff_idct_add_altivec ( uint8_t dest,
int  stride,
int16_t *  blk 
)

Definition at line 182 of file idct_altivec.c.

Referenced by ff_dsputil_init_ppc().

Variable Documentation

const vec_s16 constants[5]
static
Initial value:
= {
{23170, 13573, 6518, 21895, -23170, -21895, 32, 31},
{16384, 22725, 21407, 19266, 16384, 19266, 21407, 22725},
{22725, 31521, 29692, 26722, 22725, 26722, 29692, 31521},
{21407, 29692, 27969, 25172, 21407, 25172, 27969, 29692},
{19266, 26722, 25172, 22654, 19266, 22654, 25172, 26722}
}

Definition at line 152 of file idct_altivec.c.