FFmpeg
Macros | Functions | Variables
hevc_pel.c File Reference
#include <string.h>
#include "checkasm.h"
#include "libavcodec/hevcdsp.h"
#include "libavutil/common.h"
#include "libavutil/internal.h"
#include "libavutil/intreadwrite.h"

Go to the source code of this file.

Macros

#define SIZEOF_PIXEL   ((bit_depth + 7) / 8)
 
#define BUF_SIZE   (2 * MAX_PB_SIZE * (2 * 4 + MAX_PB_SIZE))
 
#define randomize_buffers()
 
#define randomize_buffers_ref()
 
#define src0   (buf0 + 2 * 4 * MAX_PB_SIZE) /* hevc qpel functions read data from negative src pointer offsets */
 
#define src1   (buf1 + 2 * 4 * MAX_PB_SIZE)
 
#define SRC_EXTRA   8
 
#define SRC_EXTRA   0
 

Functions

static void checkasm_check_hevc_qpel (void)
 
static void checkasm_check_hevc_qpel_uni (void)
 
static void checkasm_check_hevc_qpel_uni_w (void)
 
static void checkasm_check_hevc_qpel_bi (void)
 
static void checkasm_check_hevc_qpel_bi_w (void)
 
static void checkasm_check_hevc_epel (void)
 
static void checkasm_check_hevc_epel_uni (void)
 
static void checkasm_check_hevc_epel_uni_w (void)
 
static void checkasm_check_hevc_epel_bi (void)
 
static void checkasm_check_hevc_epel_bi_w (void)
 
void checkasm_check_hevc_pel (void)
 

Variables

static const uint32_t pixel_mask [] = { 0xffffffff, 0x01ff01ff, 0x03ff03ff, 0x07ff07ff, 0x0fff0fff }
 
static const uint32_t pixel_mask16 [] = { 0x00ff00ff, 0x01ff01ff, 0x03ff03ff, 0x07ff07ff, 0x0fff0fff }
 
static const int sizes [] = { -1, 4, 6, 8, 12, 16, 24, 32, 48, 64 }
 
static const int weights [] = { 0, 128, 255, -1 }
 
static const int denoms [] = {0, 7, 12, -1 }
 
static const int offsets [] = {0, 255, -1 }
 

Macro Definition Documentation

◆ SIZEOF_PIXEL

#define SIZEOF_PIXEL   ((bit_depth + 7) / 8)

Definition at line 36 of file hevc_pel.c.

◆ BUF_SIZE

#define BUF_SIZE   (2 * MAX_PB_SIZE * (2 * 4 + MAX_PB_SIZE))

Definition at line 37 of file hevc_pel.c.

◆ randomize_buffers

#define randomize_buffers ( )
Value:
do { \
uint32_t mask = pixel_mask[bit_depth - 8]; \
int k; \
for (k = 0; k < BUF_SIZE + SRC_EXTRA; k += 4) { \
uint32_t r = rnd() & mask; \
AV_WN32A(buf0 + k, r); \
AV_WN32A(buf1 + k, r); \
if (k >= BUF_SIZE) \
continue; \
r = rnd(); \
AV_WN32A(dst0 + k, r); \
AV_WN32A(dst1 + k, r); \
} \
} while (0)

Definition at line 39 of file hevc_pel.c.

◆ randomize_buffers_ref

#define randomize_buffers_ref ( )
Value:
do { \
uint32_t mask = pixel_mask16[bit_depth - 8]; \
int k; \
for (k = 0; k < BUF_SIZE; k += 2) { \
uint32_t r = rnd() & mask; \
AV_WN32A(ref0 + k, r); \
AV_WN32A(ref1 + k, r); \
} \
} while (0)

Definition at line 55 of file hevc_pel.c.

◆ src0

#define src0   (buf0 + 2 * 4 * MAX_PB_SIZE) /* hevc qpel functions read data from negative src pointer offsets */

Definition at line 67 of file hevc_pel.c.

◆ src1

#define src1   (buf1 + 2 * 4 * MAX_PB_SIZE)

Definition at line 68 of file hevc_pel.c.

◆ SRC_EXTRA [1/2]

#define SRC_EXTRA   8

Definition at line 303 of file hevc_pel.c.

◆ SRC_EXTRA [2/2]

#define SRC_EXTRA   0

Definition at line 303 of file hevc_pel.c.

Function Documentation

◆ checkasm_check_hevc_qpel()

static void checkasm_check_hevc_qpel ( void  )
static

Definition at line 73 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_qpel_uni()

static void checkasm_check_hevc_qpel_uni ( void  )
static

Definition at line 117 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_qpel_uni_w()

static void checkasm_check_hevc_qpel_uni_w ( void  )
static

Definition at line 158 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_qpel_bi()

static void checkasm_check_hevc_qpel_bi ( void  )
static

Definition at line 206 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_qpel_bi_w()

static void checkasm_check_hevc_qpel_bi_w ( void  )
static

Definition at line 250 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_epel()

static void checkasm_check_hevc_epel ( void  )
static

Definition at line 305 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_epel_uni()

static void checkasm_check_hevc_epel_uni ( void  )
static

Definition at line 349 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_epel_uni_w()

static void checkasm_check_hevc_epel_uni_w ( void  )
static

Definition at line 390 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_epel_bi()

static void checkasm_check_hevc_epel_bi ( void  )
static

Definition at line 438 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_epel_bi_w()

static void checkasm_check_hevc_epel_bi_w ( void  )
static

Definition at line 482 of file hevc_pel.c.

Referenced by checkasm_check_hevc_pel().

◆ checkasm_check_hevc_pel()

void checkasm_check_hevc_pel ( void  )

Definition at line 534 of file hevc_pel.c.

Variable Documentation

◆ pixel_mask

const uint32_t pixel_mask[] = { 0xffffffff, 0x01ff01ff, 0x03ff03ff, 0x07ff07ff, 0x0fff0fff }
static

Definition at line 29 of file hevc_pel.c.

◆ pixel_mask16

const uint32_t pixel_mask16[] = { 0x00ff00ff, 0x01ff01ff, 0x03ff03ff, 0x07ff07ff, 0x0fff0fff }
static

Definition at line 30 of file hevc_pel.c.

◆ sizes

const int sizes[] = { -1, 4, 6, 8, 12, 16, 24, 32, 48, 64 }
static

◆ weights

const int weights[] = { 0, 128, 255, -1 }
static

◆ denoms

const int denoms[] = {0, 7, 12, -1 }
static

◆ offsets

const int offsets[] = {0, 255, -1 }
static
bit_depth
static void bit_depth(AudioStatsContext *s, uint64_t mask, uint64_t imask, AVRational *depth)
Definition: af_astats.c:226
r
const char * r
Definition: vf_curves.c:116
pixel_mask16
static const uint32_t pixel_mask16[]
Definition: hevc_pel.c:30
SRC_EXTRA
#define SRC_EXTRA
Definition: hevc_pel.c:303
rnd
#define rnd()
Definition: checkasm.h:115
mask
static const uint16_t mask[17]
Definition: lzw.c:38
pixel_mask
static const uint32_t pixel_mask[]
Definition: hevc_pel.c:29
BUF_SIZE
#define BUF_SIZE
Definition: hevc_pel.c:37
randomize_buffers
#define randomize_buffers()
Definition: hevc_pel.c:39