Lines Matching refs:rps
120 ShortTermRPS *rps, const HEVCSPS *sps, int is_slice_header) in ff_hevc_decode_short_term_rps() argument
129 if (rps != sps->st_rps && sps->nb_st_rps) in ff_hevc_decode_short_term_rps()
148 rps->rps_idx_num_delta_pocs = rps_ridx->num_delta_pocs; in ff_hevc_decode_short_term_rps()
150 rps_ridx = &sps->st_rps[rps - sps->st_rps - 1]; in ff_hevc_decode_short_term_rps()
162 int used = rps->used[k] = get_bits1(gb); in ff_hevc_decode_short_term_rps()
172 rps->delta_poc[k] = delta_poc; in ff_hevc_decode_short_term_rps()
181 if (k >= FF_ARRAY_ELEMS(rps->used)) { in ff_hevc_decode_short_term_rps()
187 rps->num_delta_pocs = k; in ff_hevc_decode_short_term_rps()
188 rps->num_negative_pics = k0; in ff_hevc_decode_short_term_rps()
190 if (rps->num_delta_pocs != 0) { in ff_hevc_decode_short_term_rps()
192 for (i = 1; i < rps->num_delta_pocs; i++) { in ff_hevc_decode_short_term_rps()
193 delta_poc = rps->delta_poc[i]; in ff_hevc_decode_short_term_rps()
194 used = rps->used[i]; in ff_hevc_decode_short_term_rps()
196 tmp = rps->delta_poc[k]; in ff_hevc_decode_short_term_rps()
198 rps->delta_poc[k + 1] = tmp; in ff_hevc_decode_short_term_rps()
199 rps->used[k + 1] = rps->used[k]; in ff_hevc_decode_short_term_rps()
200 rps->delta_poc[k] = delta_poc; in ff_hevc_decode_short_term_rps()
201 rps->used[k] = used; in ff_hevc_decode_short_term_rps()
206 if ((rps->num_negative_pics >> 1) != 0) { in ff_hevc_decode_short_term_rps()
208 k = rps->num_negative_pics - 1; in ff_hevc_decode_short_term_rps()
210 for (i = 0; i < rps->num_negative_pics >> 1; i++) { in ff_hevc_decode_short_term_rps()
211 delta_poc = rps->delta_poc[i]; in ff_hevc_decode_short_term_rps()
212 used = rps->used[i]; in ff_hevc_decode_short_term_rps()
213 rps->delta_poc[i] = rps->delta_poc[k]; in ff_hevc_decode_short_term_rps()
214 rps->used[i] = rps->used[k]; in ff_hevc_decode_short_term_rps()
215 rps->delta_poc[k] = delta_poc; in ff_hevc_decode_short_term_rps()
216 rps->used[k] = used; in ff_hevc_decode_short_term_rps()
222 rps->num_negative_pics = get_ue_golomb_long(gb); in ff_hevc_decode_short_term_rps()
225 if (rps->num_negative_pics >= HEVC_MAX_REFS || in ff_hevc_decode_short_term_rps()
231 rps->num_delta_pocs = rps->num_negative_pics + nb_positive_pics; in ff_hevc_decode_short_term_rps()
232 if (rps->num_delta_pocs) { in ff_hevc_decode_short_term_rps()
234 for (i = 0; i < rps->num_negative_pics; i++) { in ff_hevc_decode_short_term_rps()
243 rps->delta_poc[i] = prev; in ff_hevc_decode_short_term_rps()
244 rps->used[i] = get_bits1(gb); in ff_hevc_decode_short_term_rps()
256 rps->delta_poc[rps->num_negative_pics + i] = prev; in ff_hevc_decode_short_term_rps()
257 rps->used[rps->num_negative_pics + i] = get_bits1(gb); in ff_hevc_decode_short_term_rps()