GstVaapiDecoderUnit: GStreamer VA-API Plugins 1.6 Library Reference Manual

## GstVaapiDecoderUnit GstVaapiDecoderUnit — Decoder unit |

## Functions

void | gst_vaapi_decoder_unit_init ()
void | gst_vaapi_decoder_unit_clear ()
GstVaapiDecoderUnit * | gst_vaapi_decoder_unit_new ()
void | gst_vaapi_decoder_unit_set_parsed_info ()

## Types and Values

enum | GstVaapiDecoderUnitFlags
struct | GstVaapiDecoderUnit

## Description

## Functions

### gst_vaapi_decoder_unit_init ()

    void
    gst_vaapi_decoder_unit_init (GstVaapiDecoderUnit *unit);

Initializes internal resources bound to the supplied decoder `unit` .

`note` This is an internal function used to implement lightweight sub-classes.

#### Parameters

unit | a GstVaapiDecoderUnit |

### gst_vaapi_decoder_unit_clear ()

    void
    gst_vaapi_decoder_unit_clear (GstVaapiDecoderUnit *unit);

Deallocates any internal resources bound to the supplied decoder `unit` .

`note` This is an internal function used to implement lightweight sub-classes.

#### Parameters

unit | a GstVaapiDecoderUnit |

### gst_vaapi_decoder_unit_new ()

    GstVaapiDecoderUnit *
    gst_vaapi_decoder_unit_new (void);

### gst_vaapi_decoder_unit_set_parsed_info ()

    void
    gst_vaapi_decoder_unit_set_parsed_info
                                   (GstVaapiDecoderUnit *unit,
                                    gpointer parsed_info,
                                    GDestroyNotify destroy_notify);

Sets `parsed_info` on the object and the GDestroyNotify that will be called when the data is freed.

If some `parsed_info` was previously set, then the former `destroy_notify` function will be called before the `parsed_info` is replaced.

#### Parameters

unit | a GstVaapiDecoderUnit |
parsed_info | parser info |
destroy_notify | a GDestroyNotify. | [closure parsed_info]

## Types and Values

### enum GstVaapiDecoderUnitFlags

Flags for GstVaapiDecoderUnit.

#### Members

GST_VAAPI_DECODER_UNIT_FLAG_FRAME_START | marks the start of a frame. |
GST_VAAPI_DECODER_UNIT_FLAG_FRAME_END | marks the end of a frame. |
GST_VAAPI_DECODER_UNIT_FLAG_STREAM_END | marks the end of a stream. |
GST_VAAPI_DECODER_UNIT_FLAG_SLICE | the unit contains slice data. |
GST_VAAPI_DECODER_UNIT_FLAG_SKIP | marks the unit as unused/skipped. |
GST_VAAPI_DECODER_UNIT_FLAG_LAST |  |

### struct GstVaapiDecoderUnit

    struct GstVaapiDecoderUnit {
        guint               flags;
        guint               size;
        guint               offset;
        gpointer            parsed_info;
        GDestroyNotify      parsed_info_destroy_notify;
    };

A chunk of bitstream data that was parsed.

#### Members

guint `flags`; |  |
guint `size`; | size in bytes of this bitstream unit |
guint `offset`; | relative offset in bytes to bitstream unit within the associated GstVideoCodecFrame input_buffer |
gpointer `parsed_info`; | parser-specific data (this is codec specific) |
GDestroyNotify `parsed_info_destroy_notify`; | function used to release `parsed_info` data |