mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 01:00:37 +00:00
h264parser: Expose SEI clear function to public
gsth265parser does it already. Although corresponding API of h265parser is gst_h265_sei_free, _clear suffix is more consistent naming for h264parser since there are gst_h264_{sps,pps}_clear().
This commit is contained in:
parent
429de2c6d8
commit
5f6884a1c0
2 changed files with 16 additions and 5 deletions
|
@ -2405,12 +2405,20 @@ gst_h264_sps_clear (GstH264SPS * sps)
|
|||
}
|
||||
}
|
||||
|
||||
static void
|
||||
h264_sei_message_clear (GstH264SEIMessage * sei_msg)
|
||||
/**
|
||||
* gst_h264_sei_clear:
|
||||
* sei: The #GstH264SEIMessage to clear
|
||||
*
|
||||
* Frees allocated data in @sei if any.
|
||||
*
|
||||
* Since: 1.18
|
||||
*/
|
||||
void
|
||||
gst_h264_sei_clear (GstH264SEIMessage * sei)
|
||||
{
|
||||
switch (sei_msg->payloadType) {
|
||||
switch (sei->payloadType) {
|
||||
case GST_H264_SEI_REGISTERED_USER_DATA:{
|
||||
GstH264RegisteredUserData *rud = &sei_msg->payload.registered_user_data;
|
||||
GstH264RegisteredUserData *rud = &sei->payload.registered_user_data;
|
||||
|
||||
g_free ((guint8 *) rud->data);
|
||||
rud->data = NULL;
|
||||
|
@ -2444,7 +2452,7 @@ gst_h264_parser_parse_sei (GstH264NalParser * nalparser, GstH264NalUnit * nalu,
|
|||
nal_reader_init (&nr, nalu->data + nalu->offset + nalu->header_bytes,
|
||||
nalu->size - nalu->header_bytes);
|
||||
*messages = g_array_new (FALSE, FALSE, sizeof (GstH264SEIMessage));
|
||||
g_array_set_clear_func (*messages, (GDestroyNotify) h264_sei_message_clear);
|
||||
g_array_set_clear_func (*messages, (GDestroyNotify) gst_h264_sei_clear);
|
||||
|
||||
do {
|
||||
res = gst_h264_parser_parse_sei_message (nalparser, &nr, &sei);
|
||||
|
|
|
@ -1200,6 +1200,9 @@ void gst_h264_sps_clear (GstH264SPS *sps);
|
|||
GST_CODEC_PARSERS_API
|
||||
void gst_h264_pps_clear (GstH264PPS *pps);
|
||||
|
||||
GST_CODEC_PARSERS_API
|
||||
void gst_h264_sei_clear (GstH264SEIMessage *sei);
|
||||
|
||||
GST_CODEC_PARSERS_API
|
||||
void gst_h264_quant_matrix_8x8_get_zigzag_from_raster (guint8 out_quant[64],
|
||||
const guint8 quant[64]);
|
||||
|
|
Loading…
Reference in a new issue