FFmpeg
Macros | Functions
dsp_init.c File Reference
#include "config.h"
#include "libavutil/attributes.h"
#include "libavutil/cpu.h"
#include "libavutil/riscv/cpu.h"
#include "libavcodec/vvc/dsp.h"
#include "libavcodec/vvc/dec.h"
#include "libavcodec/riscv/h26x/h2656dsp.h"

Go to the source code of this file.

Macros

#define bf(fn, bd, opt)   fn##_##bd##_##opt
 
#define AVG_PROTOTYPES(bd, opt)
 
#define DMVR_PROTOTYPES(bd, opt)
 
#define DMVR_INIT(bd, opt)
 
#define PUT_PIXELS_PROTOTYPES2(bd, opt)
 
#define PEL_FUNC(dst, C, idx1, idx2, a)
 
#define FUNCS(C, opt)   PEL_FUNC(put, C, 0, 0, ff_vvc_put_pixels_8_##opt); \
 

Functions

int ff_vvc_sad_rvv_128 (const int16_t *src0, const int16_t *src1, int dx, int dy, int block_w, int block_h)
 
int ff_vvc_sad_rvv_256 (const int16_t *src0, const int16_t *src1, int dx, int dy, int block_w, int block_h)
 
void ff_vvc_dsp_init_riscv (VVCDSPContext *const c, const int bd)
 

Macro Definition Documentation

◆ bf

#define bf (   fn,
  bd,
  opt 
)    fn##_##bd##_##opt

Definition at line 30 of file dsp_init.c.

◆ AVG_PROTOTYPES

#define AVG_PROTOTYPES (   bd,
  opt 
)
Value:
void bf(ff_vvc_avg, bd, opt)(uint8_t *dst, ptrdiff_t dst_stride, \
const int16_t *src0, const int16_t *src1, int width, int height); \
void bf(ff_vvc_w_avg, bd, opt)(uint8_t *dst, ptrdiff_t dst_stride, \
const int16_t *src0, const int16_t *src1, int width, int height, \
int denom, int w0, int w1, int o0, int o1);

Definition at line 32 of file dsp_init.c.

◆ DMVR_PROTOTYPES

#define DMVR_PROTOTYPES (   bd,
  opt 
)
Value:
void ff_vvc_dmvr_##bd##_##opt(int16_t *dst, const uint8_t *src, ptrdiff_t src_stride, \
int height, intptr_t mx, intptr_t my, int width); \
void ff_vvc_dmvr_h_##bd##_##opt(int16_t *dst, const uint8_t *src, ptrdiff_t src_stride, \
int height, intptr_t mx, intptr_t my, int width); \
void ff_vvc_dmvr_v_##bd##_##opt(int16_t *dst, const uint8_t *src, ptrdiff_t src_stride, \
int height, intptr_t mx, intptr_t my, int width); \
void ff_vvc_dmvr_hv_##bd##_##opt(int16_t *dst, const uint8_t *src, ptrdiff_t src_stride, \
int height, intptr_t mx, intptr_t my, int width); \

Definition at line 42 of file dsp_init.c.

◆ DMVR_INIT

#define DMVR_INIT (   bd,
  opt 
)
Value:
do { \
c->inter.dmvr[0][0] = ff_vvc_dmvr_##bd##_##opt; \
c->inter.dmvr[0][1] = ff_vvc_dmvr_h_##bd##_##opt; \
c->inter.dmvr[1][0] = ff_vvc_dmvr_v_##bd##_##opt; \
c->inter.dmvr[1][1] = ff_vvc_dmvr_hv_##bd##_##opt; \
} while (0)

Definition at line 55 of file dsp_init.c.

◆ PUT_PIXELS_PROTOTYPES2

#define PUT_PIXELS_PROTOTYPES2 (   bd,
  opt 
)
Value:
void bf(ff_vvc_put_pixels, bd, opt)(int16_t *dst, \
const uint8_t *_src, const ptrdiff_t _src_stride, \
const int height, const int8_t *hf, const int8_t *vf, const int width);

Definition at line 65 of file dsp_init.c.

◆ PEL_FUNC

#define PEL_FUNC (   dst,
  C,
  idx1,
  idx2,
  a 
)
Value:
do { \
for (int w = 1; w < 7; w++) \
c->inter.dst[C][w][idx1][idx2] = a; \
} while (0) \

Definition at line 73 of file dsp_init.c.

◆ FUNCS

#define FUNCS (   C,
  opt 
)    PEL_FUNC(put, C, 0, 0, ff_vvc_put_pixels_8_##opt); \

Definition at line 79 of file dsp_init.c.

Function Documentation

◆ ff_vvc_sad_rvv_128()

int ff_vvc_sad_rvv_128 ( const int16_t *  src0,
const int16_t *  src1,
int  dx,
int  dy,
int  block_w,
int  block_h 
)

Referenced by ff_vvc_dsp_init_riscv().

◆ ff_vvc_sad_rvv_256()

int ff_vvc_sad_rvv_256 ( const int16_t *  src0,
const int16_t *  src1,
int  dx,
int  dy,
int  block_w,
int  block_h 
)

Referenced by ff_vvc_dsp_init_riscv().

◆ ff_vvc_dsp_init_riscv()

void ff_vvc_dsp_init_riscv ( VVCDSPContext *const  c,
const int  bd 
)

Definition at line 82 of file dsp_init.c.

Referenced by ff_vvc_dsp_init().

src1
const pixel * src1
Definition: h264pred_template.c:421
w
uint8_t w
Definition: llviddspenc.c:38
_src
uint8_t ptrdiff_t const uint8_t * _src
Definition: dsp.h:52
mx
uint8_t ptrdiff_t const uint8_t ptrdiff_t int intptr_t mx
Definition: dsp.h:53
bf
#define bf(fn, bd, opt)
Definition: dsp_init.c:30
C
s EdgeDetect Foobar g libavfilter vf_edgedetect c libavfilter vf_foobar c edit libavfilter and add an entry for foobar following the pattern of the other filters edit libavfilter allfilters and add an entry for foobar following the pattern of the other filters configure make j< whatever > ffmpeg ffmpeg i you should get a foobar png with Lena edge detected That s your new playground is ready Some little details about what s going which in turn will define variables for the build system and the C
Definition: writing_filters.txt:58
my
uint8_t ptrdiff_t const uint8_t ptrdiff_t int intptr_t intptr_t my
Definition: dsp.h:53
c
Undefined Behavior In the C some operations are like signed integer dereferencing freed accessing outside allocated Undefined Behavior must not occur in a C it is not safe even if the output of undefined operations is unused The unsafety may seem nit picking but Optimizing compilers have in fact optimized code on the assumption that no undefined Behavior occurs Optimizing code based on wrong assumptions can and has in some cases lead to effects beyond the output of computations The signed integer overflow problem in speed critical code Code which is highly optimized and works with signed integers sometimes has the problem that often the output of the computation does not c
Definition: undefined.txt:32
height
#define height
Definition: dsp.h:85
dst
uint8_t ptrdiff_t const uint8_t ptrdiff_t int intptr_t intptr_t int int16_t * dst
Definition: dsp.h:83
a
The reader does not expect b to be semantically here and if the code is changed by maybe adding a a division or other the signedness will almost certainly be mistaken To avoid this confusion a new type was SUINT is the C unsigned type but it holds a signed int to use the same example SUINT a
Definition: undefined.txt:41
hf
uint8_t ptrdiff_t const uint8_t ptrdiff_t int const int8_t * hf
Definition: dsp.h:249
src0
const pixel *const src0
Definition: h264pred_template.c:420
_
#define _
width
#define width
Definition: dsp.h:85
vf
uint8_t ptrdiff_t const uint8_t ptrdiff_t int const int8_t const int8_t * vf
Definition: dsp.h:249
src
#define src
Definition: vp8dsp.c:248