#include "libavutil/intreadwrite.h"
#include "internal.h"
#include "dsputil.h"
#include "avcodec.h"
#include "mpegvideo.h"
#include "h264.h"
#include "mathops.h"
#include "rectangle.h"
#include <assert.h>
Go to the source code of this file.
Defines | |
#define | FILTER(hv, dir, edge) |
Functions | |
static void av_always_inline | filter_mb_edgev (uint8_t *pix, int stride, int16_t bS[4], unsigned int qp, H264Context *h) |
static void av_always_inline | filter_mb_edgecv (uint8_t *pix, int stride, int16_t bS[4], unsigned int qp, H264Context *h) |
static void | filter_mb_mbaff_edgev (H264Context *h, uint8_t *pix, int stride, int16_t bS[4], int bsi, int qp) |
static void | filter_mb_mbaff_edgecv (H264Context *h, uint8_t *pix, int stride, int16_t bS[4], int bsi, int qp) |
static void av_always_inline | filter_mb_edgeh (uint8_t *pix, int stride, int16_t bS[4], unsigned int qp, H264Context *h) |
static void av_always_inline | filter_mb_edgech (uint8_t *pix, int stride, int16_t bS[4], unsigned int qp, H264Context *h) |
void | ff_h264_filter_mb_fast (H264Context *h, int mb_x, int mb_y, uint8_t *img_y, uint8_t *img_cb, uint8_t *img_cr, unsigned int linesize, unsigned int uvlinesize) |
static int | check_mv (H264Context *h, long b_idx, long bn_idx, int mvy_limit) |
static av_always_inline void | filter_mb_dir (H264Context *h, int mb_x, int mb_y, uint8_t *img_y, uint8_t *img_cb, uint8_t *img_cr, unsigned int linesize, unsigned int uvlinesize, int mb_xy, int mb_type, int mvy_limit, int first_vertical_edge_done, int dir) |
void | ff_h264_filter_mb (H264Context *h, int mb_x, int mb_y, uint8_t *img_y, uint8_t *img_cb, uint8_t *img_cr, unsigned int linesize, unsigned int uvlinesize) |
Variables | |
static const uint8_t | alpha_table [52 *3] |
static const uint8_t | beta_table [52 *3] |
static const uint8_t | tc0_table [52 *3][4] |
Definition in file h264_loopfilter.c.
#define FILTER | ( | hv, | |||
dir, | |||||
edge | ) |
Value:
if(AV_RN64A(bS[dir][edge])) { \ filter_mb_edge##hv( &img_y[4*edge*(dir?linesize:1)], linesize, bS[dir][edge], edge ? qp : qp##dir, h );\ if(!(edge&1)) {\ filter_mb_edgec##hv( &img_cb[2*edge*(dir?uvlinesize:1)], uvlinesize, bS[dir][edge], edge ? qpc : qpc##dir, h );\ filter_mb_edgec##hv( &img_cr[2*edge*(dir?uvlinesize:1)], uvlinesize, bS[dir][edge], edge ? qpc : qpc##dir, h );\ }\ }
Referenced by ff_h264_filter_mb_fast(), and ff_iir_filter().
static int check_mv | ( | H264Context * | h, | |
long | b_idx, | |||
long | bn_idx, | |||
int | mvy_limit | |||
) | [static] |
void ff_h264_filter_mb | ( | H264Context * | h, | |
int | mb_x, | |||
int | mb_y, | |||
uint8_t * | img_y, | |||
uint8_t * | img_cb, | |||
uint8_t * | img_cr, | |||
unsigned int | linesize, | |||
unsigned int | uvlinesize | |||
) |
Definition at line 656 of file h264_loopfilter.c.
Referenced by ff_h264_filter_mb_fast(), and loop_filter().
void ff_h264_filter_mb_fast | ( | H264Context * | h, | |
int | mb_x, | |||
int | mb_y, | |||
uint8_t * | img_y, | |||
uint8_t * | img_cb, | |||
uint8_t * | img_cr, | |||
unsigned int | linesize, | |||
unsigned int | uvlinesize | |||
) |
static av_always_inline void filter_mb_dir | ( | H264Context * | h, | |
int | mb_x, | |||
int | mb_y, | |||
uint8_t * | img_y, | |||
uint8_t * | img_cb, | |||
uint8_t * | img_cr, | |||
unsigned int | linesize, | |||
unsigned int | uvlinesize, | |||
int | mb_xy, | |||
int | mb_type, | |||
int | mvy_limit, | |||
int | first_vertical_edge_done, | |||
int | dir | |||
) | [static] |
static void av_always_inline filter_mb_edgech | ( | uint8_t * | pix, | |
int | stride, | |||
int16_t | bS[4], | |||
unsigned int | qp, | |||
H264Context * | h | |||
) | [static] |
Definition at line 291 of file h264_loopfilter.c.
Referenced by ff_h264_filter_mb_fast(), and filter_mb_dir().
static void av_always_inline filter_mb_edgecv | ( | uint8_t * | pix, | |
int | stride, | |||
int16_t | bS[4], | |||
unsigned int | qp, | |||
H264Context * | h | |||
) | [static] |
Definition at line 120 of file h264_loopfilter.c.
Referenced by ff_h264_filter_mb_fast(), and filter_mb_dir().
static void av_always_inline filter_mb_edgeh | ( | uint8_t * | pix, | |
int | stride, | |||
int16_t | bS[4], | |||
unsigned int | qp, | |||
H264Context * | h | |||
) | [static] |
Definition at line 273 of file h264_loopfilter.c.
Referenced by ff_h264_filter_mb_fast(), and filter_mb_dir().
static void av_always_inline filter_mb_edgev | ( | uint8_t * | pix, | |
int | stride, | |||
int16_t | bS[4], | |||
unsigned int | qp, | |||
H264Context * | h | |||
) | [static] |
Definition at line 103 of file h264_loopfilter.c.
Referenced by ff_h264_filter_mb_fast(), and filter_mb_dir().
static void filter_mb_mbaff_edgecv | ( | H264Context * | h, | |
uint8_t * | pix, | |||
int | stride, | |||
int16_t | bS[4], | |||
int | bsi, | |||
int | qp | |||
) | [static] |
static void filter_mb_mbaff_edgev | ( | H264Context * | h, | |
uint8_t * | pix, | |||
int | stride, | |||
int16_t | bS[4], | |||
int | bsi, | |||
int | qp | |||
) | [static] |
const uint8_t alpha_table[52 *3] [static] |
Initial value:
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 5, 6, 7, 8, 9, 10, 12, 13, 15, 17, 20, 22, 25, 28, 32, 36, 40, 45, 50, 56, 63, 71, 80, 90,101,113,127,144,162,182,203,226, 255,255, 255,255,255,255,255,255,255,255,255,255,255,255,255, 255,255,255,255,255,255,255,255,255,255,255,255,255, 255,255,255,255,255,255,255,255,255,255,255,255,255, 255,255,255,255,255,255,255,255,255,255,255,255,255, }
Definition at line 41 of file h264_loopfilter.c.
Referenced by filter_mb_edgech(), filter_mb_edgecv(), filter_mb_edgeh(), filter_mb_edgev(), filter_mb_mbaff_edgecv(), and filter_mb_mbaff_edgev().
const uint8_t beta_table[52 *3] [static] |
Initial value:
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 14, 14, 15, 15, 16, 16, 17, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, }
Definition at line 57 of file h264_loopfilter.c.
Referenced by filter_mb_edgech(), filter_mb_edgecv(), filter_mb_edgeh(), filter_mb_edgev(), filter_mb_mbaff_edgecv(), and filter_mb_mbaff_edgev().
const uint8_t tc0_table[52 *3][4] [static] |
Initial value:
{ {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-1, 0, 0, 0 }, {-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, 4, 6 }, {-1, 3, 4, 6 }, {-1, 4, 5, 7 }, {-1, 4, 5, 8 }, {-1, 4, 6, 9 }, {-1, 5, 7,10 }, {-1, 6, 8,11 }, {-1, 6, 8,13 }, {-1, 7,10,14 }, {-1, 8,11,16 }, {-1, 9,12,18 }, {-1,10,13,20 }, {-1,11,15,23 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, {-1,13,17,25 }, }
Definition at line 73 of file h264_loopfilter.c.
Referenced by filter_mb_edgech(), filter_mb_edgecv(), filter_mb_edgeh(), filter_mb_edgev(), filter_mb_mbaff_edgecv(), and filter_mb_mbaff_edgev().