Commit de8049d2 authored by Michael Niedermayer's avatar Michael Niedermayer

h264: add an argument to CHROMA for consistency

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 881050d2
...@@ -87,7 +87,7 @@ ...@@ -87,7 +87,7 @@
#define CABAC(h) h->pps.cabac #define CABAC(h) h->pps.cabac
#endif #endif
#define CHROMA (h->sps.chroma_format_idc) #define CHROMA(h) (h->sps.chroma_format_idc)
#define CHROMA422(h) (h->sps.chroma_format_idc == 2) #define CHROMA422(h) (h->sps.chroma_format_idc == 2)
#define CHROMA444(h) (h->sps.chroma_format_idc == 3) #define CHROMA444(h) (h->sps.chroma_format_idc == 3)
......
...@@ -241,7 +241,7 @@ static av_always_inline void h264_filter_mb_fast_internal(H264Context *h, ...@@ -241,7 +241,7 @@ static av_always_inline void h264_filter_mb_fast_internal(H264Context *h,
unsigned int uvlinesize, unsigned int uvlinesize,
int pixel_shift) int pixel_shift)
{ {
int chroma = CHROMA && !(CONFIG_GRAY && (h->flags&CODEC_FLAG_GRAY)); int chroma = CHROMA(h) && !(CONFIG_GRAY && (h->flags&CODEC_FLAG_GRAY));
int chroma444 = CHROMA444(h); int chroma444 = CHROMA444(h);
int chroma422 = CHROMA422(h); int chroma422 = CHROMA422(h);
...@@ -707,7 +707,7 @@ void ff_h264_filter_mb( H264Context *h, int mb_x, int mb_y, uint8_t *img_y, uint ...@@ -707,7 +707,7 @@ void ff_h264_filter_mb( H264Context *h, int mb_x, int mb_y, uint8_t *img_y, uint
const int mvy_limit = IS_INTERLACED(mb_type) ? 2 : 4; const int mvy_limit = IS_INTERLACED(mb_type) ? 2 : 4;
int first_vertical_edge_done = 0; int first_vertical_edge_done = 0;
av_unused int dir; av_unused int dir;
int chroma = CHROMA && !(CONFIG_GRAY && (h->flags&CODEC_FLAG_GRAY)); int chroma = CHROMA(h) && !(CONFIG_GRAY && (h->flags&CODEC_FLAG_GRAY));
int qp_bd_offset = 6 * (h->sps.bit_depth_luma - 8); int qp_bd_offset = 6 * (h->sps.bit_depth_luma - 8);
int a = h->slice_alpha_c0_offset - qp_bd_offset; int a = h->slice_alpha_c0_offset - qp_bd_offset;
int b = h->slice_beta_offset - qp_bd_offset; int b = h->slice_beta_offset - qp_bd_offset;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment