FFmpeg
Macros | Functions
scene_sad_init.c File Reference
#include "libavutil/cpu.h"
#include "libavutil/x86/cpu.h"
#include "libavfilter/scene_sad.h"

Go to the source code of this file.

Macros

#define SCENE_SAD_FUNC(FUNC_NAME, ASM_FUNC_NAME, MMSIZE)
 

Functions

ff_scene_sad_fn ff_scene_sad_get_fn_x86 (int depth)
 

Macro Definition Documentation

#define SCENE_SAD_FUNC (   FUNC_NAME,
  ASM_FUNC_NAME,
  MMSIZE 
)
Value:
void ASM_FUNC_NAME(SCENE_SAD_PARAMS); \
\
static void FUNC_NAME(SCENE_SAD_PARAMS) { \
uint64_t sad[MMSIZE / 8] = {0}; \
ptrdiff_t awidth = width & ~(MMSIZE - 1); \
*sum = 0; \
ASM_FUNC_NAME(src1, stride1, src2, stride2, awidth, height, sad); \
for (int i = 0; i < MMSIZE / 8; i++) \
*sum += sad[i]; \
ff_scene_sad_c(src1 + awidth, stride1, \
src2 + awidth, stride2, \
width - awidth, height, sad); \
*sum += sad[0]; \
}
void ff_scene_sad_c(SCENE_SAD_PARAMS)
Definition: scene_sad.c:45
#define height
#define SCENE_SAD_PARAMS
Definition: scene_sad.h:29
#define width
#define src1
Definition: h264pred.c:140
#define FUNC_NAME(rw, codec, name)
Definition: cbs_av1.c:543
for(j=16;j >0;--j)
int i
Definition: input.c:407

Definition at line 23 of file scene_sad_init.c.

Function Documentation

ff_scene_sad_fn ff_scene_sad_get_fn_x86 ( int  depth)

Definition at line 46 of file scene_sad_init.c.

Referenced by ff_scene_sad_get_fn().