Skip to content

Commit

Permalink
avcodec: use the renamed av_zero_extend
Browse files Browse the repository at this point in the history
Signed-off-by: James Almer <[email protected]>
  • Loading branch information
jamrial committed Jun 13, 2024
1 parent 4b57ea8 commit 1b9af30
Show file tree
Hide file tree
Showing 33 changed files with 76 additions and 76 deletions.
2 changes: 1 addition & 1 deletion libavcodec/adpcm.c
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,7 @@ static inline int16_t adpcm_ima_wav_expand_nibble(ADPCMChannelStatus *c, GetBitC
step_index = av_clip(step_index, 0, 88);

sign = nibble & (1 << shift);
delta = av_mod_uintp2(nibble, shift);
delta = av_zero_extend(nibble, shift);
diff = ((2 * delta + 1) * step) >> shift;
predictor = c->predictor;
if (sign) predictor -= diff;
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/amrwbdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ static void decode_pitch_vector(AMRWBContext *ctx,
}

/** Get x bits in the index interval [lsb,lsb+len-1] inclusive */
#define BIT_STR(x,lsb,len) av_mod_uintp2((x) >> (lsb), (len))
#define BIT_STR(x,lsb,len) av_zero_extend((x) >> (lsb), (len))

/** Get the bit at specified position */
#define BIT_POS(x, p) (((x) >> (p)) & 1)
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/atrac3plus.c
Original file line number Diff line number Diff line change
Expand Up @@ -734,7 +734,7 @@ static void decode_qu_spectra(GetBitContext *gb, const Atrac3pSpecCodeTab *tab,
val = get_vlc2(gb, vlc_tab->table, vlc_tab->bits, 1);

for (i = 0; i < num_coeffs; i++) {
cf = av_mod_uintp2(val, bits);
cf = av_zero_extend(val, bits);
if (is_signed)
cf = sign_extend(cf, bits);
else if (cf && get_bits1(gb))
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/dnxhdenc.c
Original file line number Diff line number Diff line change
Expand Up @@ -567,7 +567,7 @@ static av_always_inline void dnxhd_encode_dc(PutBitContext *pb, DNXHDEncContext
}
put_bits(pb, ctx->cid_table->dc_bits[nbits] + nbits,
(ctx->cid_table->dc_codes[nbits] << nbits) +
av_mod_uintp2(diff, nbits));
av_zero_extend(diff, nbits));
}

static av_always_inline
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/dvenc.c
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ static av_always_inline PutBitContext *dv_encode_ac(EncBlockInfo *bi,
if (bits_left) {
size -= bits_left;
put_bits(pb, bits_left, vlc >> size);
vlc = av_mod_uintp2(vlc, size);
vlc = av_zero_extend(vlc, size);
}
if (pb + 1 >= pb_end) {
bi->partial_bit_count = size;
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/ffv1dec_template.c
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ static av_always_inline int RENAME(decode_line)(FFV1Context *s, int w,
if (sign)
diff = -(unsigned)diff;

sample[1][x] = av_mod_uintp2(RENAME(predict)(sample[1] + x, sample[0] + x) + (SUINT)diff, bits);
sample[1][x] = av_zero_extend(RENAME(predict)(sample[1] + x, sample[0] + x) + (SUINT)diff, bits);
}
s->run_index = run_index;
return 0;
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/g726.c
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ static int16_t g726_encode(G726Context* c, int16_t sig)
{
uint8_t i;

i = av_mod_uintp2(quant(c, sig/4 - c->se), c->code_size);
i = av_zero_extend(quant(c, sig/4 - c->se), c->code_size);
g726_decode(c, i);
return i;
}
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/g729dec.c
Original file line number Diff line number Diff line change
Expand Up @@ -536,7 +536,7 @@ static int decode_frame(AVCodecContext *avctx, AVFrame *frame,

if (frame_erasure) {
ctx->rand_value = g729_prng(ctx->rand_value);
fc_indexes = av_mod_uintp2(ctx->rand_value, format->fc_indexes_bits);
fc_indexes = av_zero_extend(ctx->rand_value, format->fc_indexes_bits);

ctx->rand_value = g729_prng(ctx->rand_value);
pulses_signs = ctx->rand_value;
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/h264_refs.c
Original file line number Diff line number Diff line change
Expand Up @@ -791,7 +791,7 @@ int ff_h264_execute_ref_pic_marking(H264Context *h)
for (int i = 0; i < h->short_ref_count; i++) {
H264Picture *pic = h->short_ref[i];
if (pic->invalid_gap) {
int d = av_mod_uintp2(h->cur_pic_ptr->frame_num - pic->frame_num, h->ps.sps->log2_max_frame_num);
int d = av_zero_extend(h->cur_pic_ptr->frame_num - pic->frame_num, h->ps.sps->log2_max_frame_num);
if (d > h->ps.sps->ref_frame_count)
remove_short(h, pic->frame_num, 0);
}
Expand Down
4 changes: 2 additions & 2 deletions libavcodec/h264_slice.c
Original file line number Diff line number Diff line change
Expand Up @@ -1637,8 +1637,8 @@ static int h264_field_start(H264Context *h, const H264SliceContext *sl,
h->valid_recovery_point = 1;

if ( h->recovery_frame < 0
|| av_mod_uintp2(h->recovery_frame - h->poc.frame_num, h->ps.sps->log2_max_frame_num) > sei_recovery_frame_cnt) {
h->recovery_frame = av_mod_uintp2(h->poc.frame_num + sei_recovery_frame_cnt, h->ps.sps->log2_max_frame_num);
|| av_zero_extend(h->recovery_frame - h->poc.frame_num, h->ps.sps->log2_max_frame_num) > sei_recovery_frame_cnt) {
h->recovery_frame = av_zero_extend(h->poc.frame_num + sei_recovery_frame_cnt, h->ps.sps->log2_max_frame_num);

if (!h->valid_recovery_point)
h->recovery_frame = h->poc.frame_num;
Expand Down
4 changes: 2 additions & 2 deletions libavcodec/hevc/cabac.c
Original file line number Diff line number Diff line change
Expand Up @@ -642,8 +642,8 @@ int ff_hevc_split_coding_unit_flag_decode(HEVCLocalContext *lc, const HEVCSPS *s
{
const HEVCContext *const s = lc->parent;
int inc = 0, depth_left = 0, depth_top = 0;
int x0b = av_mod_uintp2(x0, sps->log2_ctb_size);
int y0b = av_mod_uintp2(y0, sps->log2_ctb_size);
int x0b = av_zero_extend(x0, sps->log2_ctb_size);
int y0b = av_zero_extend(y0, sps->log2_ctb_size);
int x_cb = x0 >> sps->log2_min_cb_size;
int y_cb = y0 >> sps->log2_min_cb_size;

Expand Down
20 changes: 10 additions & 10 deletions libavcodec/hevc/hevcdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -1679,8 +1679,8 @@ static void chroma_mc_uni(HEVCLocalContext *lc,
int idx = hevc_pel_weight[block_w];
int hshift = sps->hshift[1];
int vshift = sps->vshift[1];
intptr_t mx = av_mod_uintp2(mv->x, 2 + hshift);
intptr_t my = av_mod_uintp2(mv->y, 2 + vshift);
intptr_t mx = av_zero_extend(mv->x, 2 + hshift);
intptr_t my = av_zero_extend(mv->y, 2 + vshift);
intptr_t _mx = mx << (1 - hshift);
intptr_t _my = my << (1 - vshift);
int emu = src0 == s->cur_frame->f->data[1] || src0 == s->cur_frame->f->data[2];
Expand Down Expand Up @@ -1753,10 +1753,10 @@ static void chroma_mc_bi(HEVCLocalContext *lc,
int hshift = sps->hshift[1];
int vshift = sps->vshift[1];

intptr_t mx0 = av_mod_uintp2(mv0->x, 2 + hshift);
intptr_t my0 = av_mod_uintp2(mv0->y, 2 + vshift);
intptr_t mx1 = av_mod_uintp2(mv1->x, 2 + hshift);
intptr_t my1 = av_mod_uintp2(mv1->y, 2 + vshift);
intptr_t mx0 = av_zero_extend(mv0->x, 2 + hshift);
intptr_t my0 = av_zero_extend(mv0->y, 2 + vshift);
intptr_t mx1 = av_zero_extend(mv1->x, 2 + hshift);
intptr_t my1 = av_zero_extend(mv1->y, 2 + vshift);
intptr_t _mx0 = mx0 << (1 - hshift);
intptr_t _my0 = my0 << (1 - vshift);
intptr_t _mx1 = mx1 << (1 - hshift);
Expand Down Expand Up @@ -2020,8 +2020,8 @@ static int luma_intra_pred_mode(HEVCLocalContext *lc, const HEVCSPS *sps,
int y_pu = y0 >> sps->log2_min_pu_size;
int min_pu_width = sps->min_pu_width;
int size_in_pus = pu_size >> sps->log2_min_pu_size;
int x0b = av_mod_uintp2(x0, sps->log2_ctb_size);
int y0b = av_mod_uintp2(y0, sps->log2_ctb_size);
int x0b = av_zero_extend(x0, sps->log2_ctb_size);
int y0b = av_zero_extend(y0, sps->log2_ctb_size);

int cand_up = (lc->ctb_up_flag || y0b) ?
s->tab_ipm[(y_pu - 1) * min_pu_width + x_pu] : INTRA_DC;
Expand Down Expand Up @@ -2233,8 +2233,8 @@ static int hls_coding_unit(HEVCLocalContext *lc, const HEVCContext *s,
lc->cu.cu_transquant_bypass_flag = 0;

if (s->sh.slice_type != HEVC_SLICE_I) {
const int x0b = av_mod_uintp2(x0, sps->log2_ctb_size);
const int y0b = av_mod_uintp2(y0, sps->log2_ctb_size);
const int x0b = av_zero_extend(x0, sps->log2_ctb_size);
const int y0b = av_zero_extend(y0, sps->log2_ctb_size);
uint8_t skip_flag = ff_hevc_skip_flag_decode(lc, x0b, y0b, x_cb, y_cb,
min_cb_width);

Expand Down
4 changes: 2 additions & 2 deletions libavcodec/hevc/mvs.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ static const uint8_t l0_l1_cand_idx[12][2] = {
void ff_hevc_set_neighbour_available(HEVCLocalContext *lc, int x0, int y0,
int nPbW, int nPbH, int log2_ctb_size)
{
int x0b = av_mod_uintp2(x0, log2_ctb_size);
int y0b = av_mod_uintp2(y0, log2_ctb_size);
int x0b = av_zero_extend(x0, log2_ctb_size);
int y0b = av_zero_extend(y0, log2_ctb_size);

lc->na.cand_up = (lc->ctb_up_flag || y0b);
lc->na.cand_left = (lc->ctb_left_flag || x0b);
Expand Down
4 changes: 2 additions & 2 deletions libavcodec/hevc/pred_template.c
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,8 @@ do { \
if (pps->constrained_intra_pred_flag == 1) {
int size_in_luma_pu_v = PU(size_in_luma_v);
int size_in_luma_pu_h = PU(size_in_luma_h);
int on_pu_edge_x = !av_mod_uintp2(x0, sps->log2_min_pu_size);
int on_pu_edge_y = !av_mod_uintp2(y0, sps->log2_min_pu_size);
int on_pu_edge_x = !av_zero_extend(x0, sps->log2_min_pu_size);
int on_pu_edge_y = !av_zero_extend(y0, sps->log2_min_pu_size);
if (!size_in_luma_pu_h)
size_in_luma_pu_h++;
if (cand_bottom_left == 1 && on_pu_edge_x) {
Expand Down
4 changes: 2 additions & 2 deletions libavcodec/hevc/ps.c
Original file line number Diff line number Diff line change
Expand Up @@ -1258,8 +1258,8 @@ int ff_hevc_parse_sps(HEVCSPS *sps, GetBitContext *gb, unsigned int *sps_id,

sps->qp_bd_offset = 6 * (sps->bit_depth - 8);

if (av_mod_uintp2(sps->width, sps->log2_min_cb_size) ||
av_mod_uintp2(sps->height, sps->log2_min_cb_size)) {
if (av_zero_extend(sps->width, sps->log2_min_cb_size) ||
av_zero_extend(sps->height, sps->log2_min_cb_size)) {
av_log(avctx, AV_LOG_ERROR, "Invalid coded frame dimensions.\n");
return AVERROR_INVALIDDATA;
}
Expand Down
8 changes: 4 additions & 4 deletions libavcodec/mpeg12enc.c
Original file line number Diff line number Diff line change
Expand Up @@ -692,12 +692,12 @@ static inline void encode_dc(MpegEncContext *s, int diff, int component)
put_bits(&s->pb,
ff_mpeg12_vlc_dc_lum_bits[index] + index,
(ff_mpeg12_vlc_dc_lum_code[index] << index) +
av_mod_uintp2(diff, index));
av_zero_extend(diff, index));
else
put_bits(&s->pb,
ff_mpeg12_vlc_dc_chroma_bits[index] + index,
(ff_mpeg12_vlc_dc_chroma_code[index] << index) +
av_mod_uintp2(diff, index));
av_zero_extend(diff, index));
} else {
if (component == 0)
put_bits(&s->pb,
Expand Down Expand Up @@ -1098,12 +1098,12 @@ static av_cold void mpeg12_encode_init_static(void)

bits = ff_mpeg12_vlc_dc_lum_bits[index] + index;
code = (ff_mpeg12_vlc_dc_lum_code[index] << index) +
av_mod_uintp2(diff, index);
av_zero_extend(diff, index);
mpeg1_lum_dc_uni[i + 255] = bits + (code << 8);

bits = ff_mpeg12_vlc_dc_chroma_bits[index] + index;
code = (ff_mpeg12_vlc_dc_chroma_code[index] << index) +
av_mod_uintp2(diff, index);
av_zero_extend(diff, index);
mpeg1_chr_dc_uni[i + 255] = bits + (code << 8);
}

Expand Down
4 changes: 2 additions & 2 deletions libavcodec/opus_pvq.c
Original file line number Diff line number Diff line change
Expand Up @@ -663,7 +663,7 @@ static av_always_inline uint32_t quant_band_template(CeltPVQ *pvq, CeltFrame *f,
if (itheta == 0) {
imid = 32767;
iside = 0;
fill = av_mod_uintp2(fill, blocks);
fill = av_zero_extend(fill, blocks);
delta = -16384;
} else if (itheta == 16384) {
imid = 0;
Expand Down Expand Up @@ -878,7 +878,7 @@ static av_always_inline uint32_t quant_band_template(CeltPVQ *pvq, CeltFrame *f,
for (i = 0; i < N0; i++)
lowband_out[i] = n * X[i];
}
cm = av_mod_uintp2(cm, blocks);
cm = av_zero_extend(cm, blocks);
}

return cm;
Expand Down
6 changes: 3 additions & 3 deletions libavcodec/opus_rc.c
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ uint32_t ff_opus_rc_get_raw(OpusRangeCoder *rc, uint32_t count)
rc->rb.bytes--;
}

value = av_mod_uintp2(rc->rb.cacheval, count);
value = av_zero_extend(rc->rb.cacheval, count);
rc->rb.cacheval >>= count;
rc->rb.cachelen -= count;
rc->total_bits += count;
Expand All @@ -163,15 +163,15 @@ void ff_opus_rc_put_raw(OpusRangeCoder *rc, uint32_t val, uint32_t count)
const int to_write = FFMIN(32 - rc->rb.cachelen, count);

rc->total_bits += count;
rc->rb.cacheval |= av_mod_uintp2(val, to_write) << rc->rb.cachelen;
rc->rb.cacheval |= av_zero_extend(val, to_write) << rc->rb.cachelen;
rc->rb.cachelen = (rc->rb.cachelen + to_write) % 32;

if (!rc->rb.cachelen && count) {
AV_WB32((uint8_t *)rc->rb.position, rc->rb.cacheval);
rc->rb.bytes += 4;
rc->rb.position -= 4;
rc->rb.cachelen = count - to_write;
rc->rb.cacheval = av_mod_uintp2(val >> to_write, rc->rb.cachelen);
rc->rb.cacheval = av_zero_extend(val >> to_write, rc->rb.cachelen);
av_assert0(rc->rng_cur < rc->rb.position);
}
}
Expand Down
4 changes: 2 additions & 2 deletions libavcodec/pixlet.c
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ static int read_low_coeffs(AVCodecContext *avctx, int16_t *dst, int size,
continue;

nbits = ((state + 8) >> 5) + (state ? ff_clz(state) : 32) - 24;
escape = av_mod_uintp2(16383, nbits);
escape = av_zero_extend(16383, nbits);
cnt1 = get_unary(bc, 0, 8);
if (cnt1 > 7) {
rlen = get_bits(bc, 16);
Expand Down Expand Up @@ -269,7 +269,7 @@ static int read_high_coeffs(AVCodecContext *avctx, const uint8_t *src, int16_t *
continue;

pfx = ((state + 8) >> 5) + (state ? ff_clz(state) : 32) - 24;
escape = av_mod_uintp2(16383, pfx);
escape = av_zero_extend(16383, pfx);
cnt1 = get_unary(bc, 0, 8);
if (cnt1 < 8) {
if (pfx < 1 || pfx > 25)
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/pngdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -1018,7 +1018,7 @@ static int decode_trns_chunk(AVCodecContext *avctx, PNGDecContext *s,

for (i = 0; i < length / 2; i++) {
/* only use the least significant bits */
v = av_mod_uintp2(bytestream2_get_be16(gb), s->bit_depth);
v = av_zero_extend(bytestream2_get_be16(gb), s->bit_depth);

if (s->bit_depth > 8)
AV_WB16(&s->transparent_color_be[2 * i], v);
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/proresenc_anatoliy.c
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ static void put_alpha_diff(PutBitContext *pb, int cur, int prev)
const int dsize = 1 << dbits - 1;
int diff = cur - prev;

diff = av_mod_uintp2(diff, abits);
diff = av_zero_extend(diff, abits);
if (diff >= (1 << abits) - dsize)
diff -= 1 << abits;
if (diff < -dsize || diff > dsize || !diff) {
Expand Down
4 changes: 2 additions & 2 deletions libavcodec/proresenc_kostya.c
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ static void put_alpha_diff(PutBitContext *pb, int cur, int prev, int abits)
const int dsize = 1 << dbits - 1;
int diff = cur - prev;

diff = av_mod_uintp2(diff, abits);
diff = av_zero_extend(diff, abits);
if (diff >= (1 << abits) - dsize)
diff -= 1 << abits;
if (diff < -dsize || diff > dsize || !diff) {
Expand Down Expand Up @@ -721,7 +721,7 @@ static int est_alpha_diff(int cur, int prev, int abits)
const int dsize = 1 << dbits - 1;
int diff = cur - prev;

diff = av_mod_uintp2(diff, abits);
diff = av_zero_extend(diff, abits);
if (diff >= (1 << abits) - dsize)
diff -= 1 << abits;
if (diff < -dsize || diff > dsize || !diff)
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/put_bits.h
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ static inline void put_sbits(PutBitContext *pb, int n, int32_t value)
{
av_assert2(n >= 0 && n <= 31);

put_bits(pb, n, av_mod_uintp2(value, n));
put_bits(pb, n, av_zero_extend(value, n));
}

/**
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/put_golomb.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ static inline void set_ur_golomb(PutBitContext *pb, int i, int k, int limit,

e = i >> k;
if (e < limit)
put_bits(pb, e + k + 1, (1 << k) + av_mod_uintp2(i, k));
put_bits(pb, e + k + 1, (1 << k) + av_zero_extend(i, k));
else
put_bits(pb, limit + esc_len, i - limit + 1);
}
Expand Down
8 changes: 4 additions & 4 deletions libavcodec/speedhqenc.c
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,12 @@ static av_cold void speedhq_init_static_data(void)

bits = ff_mpeg12_vlc_dc_lum_bits[index] + index;
code = mpeg12_vlc_dc_lum_code_reversed[index] +
(av_mod_uintp2(diff, index) << ff_mpeg12_vlc_dc_lum_bits[index]);
(av_zero_extend(diff, index) << ff_mpeg12_vlc_dc_lum_bits[index]);
speedhq_lum_dc_uni[i + 255] = bits + (code << 8);

bits = ff_mpeg12_vlc_dc_chroma_bits[index] + index;
code = mpeg12_vlc_dc_chroma_code_reversed[index] +
(av_mod_uintp2(diff, index) << ff_mpeg12_vlc_dc_chroma_bits[index]);
(av_zero_extend(diff, index) << ff_mpeg12_vlc_dc_chroma_bits[index]);
speedhq_chr_dc_uni[i + 255] = bits + (code << 8);
}

Expand Down Expand Up @@ -182,12 +182,12 @@ static inline void encode_dc(PutBitContext *pb, int diff, int component)
put_bits_le(pb,
ff_mpeg12_vlc_dc_lum_bits[index] + index,
mpeg12_vlc_dc_lum_code_reversed[index] +
(av_mod_uintp2(diff, index) << ff_mpeg12_vlc_dc_lum_bits[index]));
(av_zero_extend(diff, index) << ff_mpeg12_vlc_dc_lum_bits[index]));
else
put_bits_le(pb,
ff_mpeg12_vlc_dc_chroma_bits[index] + index,
mpeg12_vlc_dc_chroma_code_reversed[index] +
(av_mod_uintp2(diff, index) << ff_mpeg12_vlc_dc_chroma_bits[index]));
(av_zero_extend(diff, index) << ff_mpeg12_vlc_dc_chroma_bits[index]));
} else {
if (component == 0)
put_bits_le(pb,
Expand Down
2 changes: 1 addition & 1 deletion libavcodec/vulkan_hevc.c
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ static void set_sps(const HEVCSPS *sps, int sps_idx,
/* NOTE: This is the predicted, and *reordered* version.
* Probably incorrect, but the spec doesn't say which version to use. */
str[i].used_by_curr_pic_flag = st_rps->used;
str[i].used_by_curr_pic_s0_flag = av_mod_uintp2(st_rps->used, str[i].num_negative_pics);
str[i].used_by_curr_pic_s0_flag = av_zero_extend(st_rps->used, str[i].num_negative_pics);
str[i].used_by_curr_pic_s1_flag = st_rps->used >> str[i].num_negative_pics;

for (int j = 0; j < str[i].num_negative_pics; j++)
Expand Down
8 changes: 4 additions & 4 deletions libavcodec/vvc/cabac.c
Original file line number Diff line number Diff line change
Expand Up @@ -954,8 +954,8 @@ void get_left_top(const VVCLocalContext *lc, uint8_t *left, uint8_t *top,
const VVCFrameContext *fc = lc->fc;
const VVCSPS *sps = fc->ps.sps;
const int min_cb_width = fc->ps.pps->min_cb_width;
const int x0b = av_mod_uintp2(x0, sps->ctb_log2_size_y);
const int y0b = av_mod_uintp2(y0, sps->ctb_log2_size_y);
const int x0b = av_zero_extend(x0, sps->ctb_log2_size_y);
const int y0b = av_zero_extend(y0, sps->ctb_log2_size_y);
const int x_cb = x0 >> sps->min_cb_log2_size_y;
const int y_cb = y0 >> sps->min_cb_log2_size_y;

Expand Down Expand Up @@ -1132,8 +1132,8 @@ static int mtt_split_cu_vertical_flag_decode(VVCLocalContext *lc, const int x0,
const VVCFrameContext *fc = lc->fc;
const VVCSPS *sps = fc->ps.sps;
const int min_cb_width = fc->ps.pps->min_cb_width;
const int x0b = av_mod_uintp2(x0, sps->ctb_log2_size_y);
const int y0b = av_mod_uintp2(y0, sps->ctb_log2_size_y);
const int x0b = av_zero_extend(x0, sps->ctb_log2_size_y);
const int y0b = av_zero_extend(y0, sps->ctb_log2_size_y);
const int x_cb = x0 >> sps->min_cb_log2_size_y;
const int y_cb = y0 >> sps->min_cb_log2_size_y;
const int available_a = lc->ctb_up_flag || y0b;
Expand Down
Loading

0 comments on commit 1b9af30

Please sign in to comment.