mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-30 11:08:34 +00:00
h265decoder: Remove unused pts variable
We can know timestamp from associated GstVideoCodecFrame Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1937>
This commit is contained in:
parent
bd39ad4519
commit
9494509ee0
3 changed files with 5 additions and 12 deletions
|
@ -631,8 +631,7 @@ gst_h265_decoder_preprocess_slice (GstH265Decoder * self, GstH265Slice * slice)
|
||||||
}
|
}
|
||||||
|
|
||||||
static GstFlowReturn
|
static GstFlowReturn
|
||||||
gst_h265_decoder_parse_slice (GstH265Decoder * self, GstH265NalUnit * nalu,
|
gst_h265_decoder_parse_slice (GstH265Decoder * self, GstH265NalUnit * nalu)
|
||||||
GstClockTime pts)
|
|
||||||
{
|
{
|
||||||
GstH265DecoderPrivate *priv = self->priv;
|
GstH265DecoderPrivate *priv = self->priv;
|
||||||
GstH265ParserResult pres = GST_H265_PARSER_OK;
|
GstH265ParserResult pres = GST_H265_PARSER_OK;
|
||||||
|
@ -685,7 +684,6 @@ gst_h265_decoder_parse_slice (GstH265Decoder * self, GstH265NalUnit * nalu,
|
||||||
g_assert (priv->current_frame);
|
g_assert (priv->current_frame);
|
||||||
|
|
||||||
picture = gst_h265_picture_new ();
|
picture = gst_h265_picture_new ();
|
||||||
picture->pts = pts;
|
|
||||||
/* This allows accessing the frame from the picture. */
|
/* This allows accessing the frame from the picture. */
|
||||||
picture->system_frame_number = priv->current_frame->system_frame_number;
|
picture->system_frame_number = priv->current_frame->system_frame_number;
|
||||||
|
|
||||||
|
@ -716,8 +714,7 @@ gst_h265_decoder_parse_slice (GstH265Decoder * self, GstH265NalUnit * nalu,
|
||||||
}
|
}
|
||||||
|
|
||||||
static GstFlowReturn
|
static GstFlowReturn
|
||||||
gst_h265_decoder_decode_nal (GstH265Decoder * self, GstH265NalUnit * nalu,
|
gst_h265_decoder_decode_nal (GstH265Decoder * self, GstH265NalUnit * nalu)
|
||||||
GstClockTime pts)
|
|
||||||
{
|
{
|
||||||
GstH265DecoderPrivate *priv = self->priv;
|
GstH265DecoderPrivate *priv = self->priv;
|
||||||
GstFlowReturn ret = GST_FLOW_OK;
|
GstFlowReturn ret = GST_FLOW_OK;
|
||||||
|
@ -755,7 +752,7 @@ gst_h265_decoder_decode_nal (GstH265Decoder * self, GstH265NalUnit * nalu,
|
||||||
case GST_H265_NAL_SLICE_IDR_W_RADL:
|
case GST_H265_NAL_SLICE_IDR_W_RADL:
|
||||||
case GST_H265_NAL_SLICE_IDR_N_LP:
|
case GST_H265_NAL_SLICE_IDR_N_LP:
|
||||||
case GST_H265_NAL_SLICE_CRA_NUT:
|
case GST_H265_NAL_SLICE_CRA_NUT:
|
||||||
ret = gst_h265_decoder_parse_slice (self, nalu, pts);
|
ret = gst_h265_decoder_parse_slice (self, nalu);
|
||||||
priv->new_bitstream = FALSE;
|
priv->new_bitstream = FALSE;
|
||||||
priv->prev_nal_is_eos = FALSE;
|
priv->prev_nal_is_eos = FALSE;
|
||||||
break;
|
break;
|
||||||
|
@ -1780,8 +1777,7 @@ gst_h265_decoder_handle_frame (GstVideoDecoder * decoder,
|
||||||
map.data, 0, map.size, priv->nal_length_size, &nalu);
|
map.data, 0, map.size, priv->nal_length_size, &nalu);
|
||||||
|
|
||||||
while (pres == GST_H265_PARSER_OK && decode_ret == GST_FLOW_OK) {
|
while (pres == GST_H265_PARSER_OK && decode_ret == GST_FLOW_OK) {
|
||||||
decode_ret = gst_h265_decoder_decode_nal (self,
|
decode_ret = gst_h265_decoder_decode_nal (self, &nalu);
|
||||||
&nalu, GST_BUFFER_PTS (in_buf));
|
|
||||||
|
|
||||||
pres = gst_h265_parser_identify_nalu_hevc (priv->parser,
|
pres = gst_h265_parser_identify_nalu_hevc (priv->parser,
|
||||||
map.data, nalu.offset + nalu.size, map.size, priv->nal_length_size,
|
map.data, nalu.offset + nalu.size, map.size, priv->nal_length_size,
|
||||||
|
@ -1795,8 +1791,7 @@ gst_h265_decoder_handle_frame (GstVideoDecoder * decoder,
|
||||||
pres = GST_H265_PARSER_OK;
|
pres = GST_H265_PARSER_OK;
|
||||||
|
|
||||||
while (pres == GST_H265_PARSER_OK && decode_ret == GST_FLOW_OK) {
|
while (pres == GST_H265_PARSER_OK && decode_ret == GST_FLOW_OK) {
|
||||||
decode_ret = gst_h265_decoder_decode_nal (self,
|
decode_ret = gst_h265_decoder_decode_nal (self, &nalu);
|
||||||
&nalu, GST_BUFFER_PTS (in_buf));
|
|
||||||
|
|
||||||
pres = gst_h265_parser_identify_nalu (priv->parser,
|
pres = gst_h265_parser_identify_nalu (priv->parser,
|
||||||
map.data, nalu.offset + nalu.size, map.size, &nalu);
|
map.data, nalu.offset + nalu.size, map.size, &nalu);
|
||||||
|
|
|
@ -51,7 +51,6 @@ gst_h265_picture_new (void)
|
||||||
|
|
||||||
pic = g_new0 (GstH265Picture, 1);
|
pic = g_new0 (GstH265Picture, 1);
|
||||||
|
|
||||||
pic->pts = GST_CLOCK_TIME_NONE;
|
|
||||||
pic->pic_struct = GST_H265_SEI_PIC_STRUCT_FRAME;
|
pic->pic_struct = GST_H265_SEI_PIC_STRUCT_FRAME;
|
||||||
/* 0: interlaced, 1: progressive, 2: unspecified, 3: reserved, can be
|
/* 0: interlaced, 1: progressive, 2: unspecified, 3: reserved, can be
|
||||||
* interpreted as 2 */
|
* interpreted as 2 */
|
||||||
|
|
|
@ -57,7 +57,6 @@ struct _GstH265Picture
|
||||||
|
|
||||||
GstH265SliceType type;
|
GstH265SliceType type;
|
||||||
|
|
||||||
GstClockTime pts;
|
|
||||||
/* From GstVideoCodecFrame */
|
/* From GstVideoCodecFrame */
|
||||||
guint32 system_frame_number;
|
guint32 system_frame_number;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue