[Mesa-dev] [PATCH 4/5] st/omx/dec/h265: set the default reference picture set

Leo Liu leo.liu at amd.com
Fri Sep 23 16:32:56 UTC 2016


Should not be null for default

Signed-off-by: Leo Liu <leo.liu at amd.com>
---
 src/gallium/state_trackers/omx/vid_dec_h265.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/gallium/state_trackers/omx/vid_dec_h265.c b/src/gallium/state_trackers/omx/vid_dec_h265.c
index fc8bf3d..9125eb1 100644
--- a/src/gallium/state_trackers/omx/vid_dec_h265.c
+++ b/src/gallium/state_trackers/omx/vid_dec_h265.c
@@ -772,7 +772,7 @@ static void slice_header(vid_dec_PrivateType *priv, struct vl_rbsp *rbsp,
    struct pipe_h265_sps *sps;
    bool first_slice_segment_in_pic_flag;
    bool dependent_slice_segment_flag = false;
-   struct ref_pic_set *rps = NULL;
+   struct ref_pic_set *rps;
    unsigned poc_lsb, poc_msb, slice_prev_poc;
    unsigned max_poc_lsb, prev_poc_lsb, prev_poc_msb;
    unsigned num_st_rps;
@@ -905,7 +905,9 @@ static void slice_header(vid_dec_PrivateType *priv, struct vl_rbsp *rbsp,
 
       rps = (struct ref_pic_set *)
          priv->codec_data.h265.ref_pic_set_list + idx;
-   }
+   } else
+      rps = (struct ref_pic_set *)
+         priv->codec_data.h265.ref_pic_set_list;
 
    if (is_bla_picture(nal_unit_type)) {
       rps->num_neg_pics = 0;
-- 
2.7.4



More information about the mesa-dev mailing list