mpegvideoparser: GStreamer Bad Plugins 1.0 Library Reference Manual

## mpegvideoparser mpegvideoparser |

## Functions

gboolean | gst_mpeg_video_parse ()
gboolean | gst_mpeg_video_parse_sequence_header ()
gboolean | gst_mpeg_video_parse_picture_header ()
gboolean | gst_mpeg_video_parse_picture_extension ()
gboolean | gst_mpeg_video_parse_gop ()
gboolean | gst_mpeg_video_parse_sequence_extension ()
gboolean | gst_mpeg_video_parse_sequence_display_extension ()
gboolean | gst_mpeg_video_parse_quant_matrix_extension ()
gboolean | gst_mpeg_video_finalise_mpeg2_sequence_header ()
void | gst_mpeg_video_quant_matrix_get_raster_from_zigzag ()
void | gst_mpeg_video_quant_matrix_get_zigzag_from_raster ()

## Types and Values

enum | GstMpegVideoPacketTypeCode
enum | GstMpegVideoPacketExtensionCode
enum | GstMpegVideoLevel
enum | GstMpegVideoProfile
enum | GstMpegVideoPictureType
enum | GstMpegVideoPictureStructure
struct | GstMpegVideoSequenceHdr
struct | GstMpegVideoSequenceExt
struct | GstMpegVideoPictureHdr
struct | GstMpegVideoGop
struct | GstMpegVideoPictureExt
struct | GstMpegVideoQuantMatrixExt

## Includes

    #include <gst/codecparsers/gstmpegvideoparser.h>

## Description

## Functions

### gst_mpeg_video_parse ()

    gboolean
    gst_mpeg_video_parse (GstMpegVideoPacket *packet,
                          const guint8 *data,
                          gsize size,
                          guint offset);

### gst_mpeg_video_parse_sequence_header ()

    gboolean
    gst_mpeg_video_parse_sequence_header (GstMpegVideoSequenceHdr *seqhdr,
                                          const guint8 *data,
                                          gsize size,
                                          guint offset);

`gst_mpeg_video_parse_sequence_header` is deprecated and should not be used in newly-written code.

### gst_mpeg_video_parse_picture_header ()

    gboolean
    gst_mpeg_video_parse_picture_header (GstMpegVideoPictureHdr *hdr,
                                         const guint8 *data,
                                         gsize size,
                                         guint offset);

`gst_mpeg_video_parse_picture_header` is deprecated and should not be used in newly-written code.

### gst_mpeg_video_parse_picture_extension ()

    gboolean
    gst_mpeg_video_parse_picture_extension
                                   (GstMpegVideoPictureExt *ext,
                                    const guint8 *data,
                                    gsize size,
                                    guint offset);

`gst_mpeg_video_parse_picture_extension` is deprecated and should not be used in newly-written code.

### gst_mpeg_video_parse_gop ()

    gboolean
    gst_mpeg_video_parse_gop (GstMpegVideoGop *gop,
                              const guint8 *data,
                              gsize size,
                              guint offset);

`gst_mpeg_video_parse_gop` is deprecated and should not be used in newly-written code.

### gst_mpeg_video_parse_sequence_extension ()

    gboolean
    gst_mpeg_video_parse_sequence_extension
                                   (GstMpegVideoSequenceExt *seqext,
                                    const guint8 *data,
                                    gsize size,
                                    guint offset);

`gst_mpeg_video_parse_sequence_extension` is deprecated and should not be used in newly-written code.

### gst_mpeg_video_parse_sequence_display_extension ()

    gboolean
    gst_mpeg_video_parse_sequence_display_extension
                                   (GstMpegVideoSequenceDisplayExt *seqdisplayext,
                                    const guint8 *data,
                                    gsize size,
                                    guint offset);

`gst_mpeg_video_parse_sequence_display_extension` is deprecated and should not be used in newly-written code.

### gst_mpeg_video_parse_quant_matrix_extension ()

    gboolean
    gst_mpeg_video_parse_quant_matrix_extension
                                   (GstMpegVideoQuantMatrixExt *quant,
                                    const guint8 *data,
                                    gsize size,
                                    guint offset);

`gst_mpeg_video_parse_quant_matrix_extension` is deprecated and should not be used in newly-written code.

### gst_mpeg_video_finalise_mpeg2_sequence_header ()

    gboolean
    gst_mpeg_video_finalise_mpeg2_sequence_header
                                   (GstMpegVideoSequenceHdr *hdr,
                                    GstMpegVideoSequenceExt *seqext,
                                    GstMpegVideoSequenceDisplayExt *displayext);

### gst_mpeg_video_quant_matrix_get_raster_from_zigzag ()

    void
    gst_mpeg_video_quant_matrix_get_raster_from_zigzag
                                   (guint8 out_quant[64],
                                    const guint8 quant[64]);

### gst_mpeg_video_quant_matrix_get_zigzag_from_raster ()

    void
    gst_mpeg_video_quant_matrix_get_zigzag_from_raster
                                   (guint8 out_quant[64],
                                    const guint8 quant[64]);

## Types and Values

### enum GstMpegVideoPacketTypeCode

#### Members

GST_MPEG_VIDEO_PACKET_PICTURE |  |
GST_MPEG_VIDEO_PACKET_SLICE_MIN |  |
GST_MPEG_VIDEO_PACKET_SLICE_MAX |  |
GST_MPEG_VIDEO_PACKET_USER_DATA |  |
GST_MPEG_VIDEO_PACKET_SEQUENCE |  |
GST_MPEG_VIDEO_PACKET_EXTENSION |  |
GST_MPEG_VIDEO_PACKET_SEQUENCE_END |  |
GST_MPEG_VIDEO_PACKET_GOP |  |
GST_MPEG_VIDEO_PACKET_NONE |  |

### enum GstMpegVideoPacketExtensionCode

#### Members

GST_MPEG_VIDEO_PACKET_EXT_SEQUENCE |  |
GST_MPEG_VIDEO_PACKET_EXT_SEQUENCE_DISPLAY |  |
GST_MPEG_VIDEO_PACKET_EXT_QUANT_MATRIX |  |
GST_MPEG_VIDEO_PACKET_EXT_SEQUENCE_SCALABLE |  |
GST_MPEG_VIDEO_PACKET_EXT_PICTURE |  |

### enum GstMpegVideoLevel

#### Members

GST_MPEG_VIDEO_LEVEL_HIGH |  |
GST_MPEG_VIDEO_LEVEL_HIGH_1440 |  |
GST_MPEG_VIDEO_LEVEL_MAIN |  |
GST_MPEG_VIDEO_LEVEL_LOW |  |

### enum GstMpegVideoProfile

#### Members

GST_MPEG_VIDEO_PROFILE_422 |  |
GST_MPEG_VIDEO_PROFILE_HIGH |  |
GST_MPEG_VIDEO_PROFILE_SPATIALLY_SCALABLE |  |
GST_MPEG_VIDEO_PROFILE_SNR_SCALABLE |  |
GST_MPEG_VIDEO_PROFILE_MAIN |  |
GST_MPEG_VIDEO_PROFILE_SIMPLE |  |

### enum GstMpegVideoPictureType

#### Members

GST_MPEG_VIDEO_PICTURE_TYPE_I |  |
GST_MPEG_VIDEO_PICTURE_TYPE_P |  |
GST_MPEG_VIDEO_PICTURE_TYPE_B |  |
GST_MPEG_VIDEO_PICTURE_TYPE_D |  |

### enum GstMpegVideoPictureStructure

#### Members

GST_MPEG_VIDEO_PICTURE_STRUCTURE_TOP_FIELD |  |
GST_MPEG_VIDEO_PICTURE_STRUCTURE_BOTTOM_FIELD |  |
GST_MPEG_VIDEO_PICTURE_STRUCTURE_FRAME |  |

### struct GstMpegVideoSequenceHdr

    struct GstMpegVideoSequenceHdr {
      guint16 width, height;
      guint8  aspect_ratio_info;
      guint8  frame_rate_code;
      guint32 bitrate_value;
      guint16 vbv_buffer_size_value;

      guint8  constrained_parameters_flag;

      guint8  load_intra_quantiser_matrix;
      guint8  intra_quantizer_matrix[64];
      guint8  load_non_intra_quantiser_matrix;
      guint8  non_intra_quantizer_matrix[64];

      /* Calculated values */
      guint   par_w, par_h;
      guint   fps_n, fps_d;
      guint   bitrate;
    };

### struct GstMpegVideoSequenceExt

    struct GstMpegVideoSequenceExt {
      /* mpeg2 decoder profile */
      guint8 profile;
      /* mpeg2 decoder level */
      guint8 level;

      guint8 progressive;
      guint8 chroma_format;

      guint8 horiz_size_ext, vert_size_ext;

      guint16 bitrate_ext;
      guint8 vbv_buffer_size_extension;
      guint8 low_delay;
      guint8 fps_n_ext, fps_d_ext;

      /* Additional information */
      guint8 profile_level_escape_bit;
    };

### struct GstMpegVideoPictureHdr

    struct GstMpegVideoPictureHdr {
      guint16 tsn;
      guint8 pic_type;
      guint16 vbv_delay;

      guint8 full_pel_forward_vector, full_pel_backward_vector;

      guint8 f_code[2][2];
    };

### struct GstMpegVideoGop

    struct GstMpegVideoGop {
      guint8 drop_frame_flag;

      guint8 hour, minute, second, frame;

      guint8 closed_gop;
      guint8 broken_link;
    };

### struct GstMpegVideoPictureExt

    struct GstMpegVideoPictureExt {
      guint8 f_code[2][2];

      guint8 intra_dc_precision;
      guint8 picture_structure;
      guint8 top_field_first;
      guint8 frame_pred_frame_dct;
      guint8 concealment_motion_vectors;
      guint8 q_scale_type;
      guint8 intra_vlc_format;
      guint8 alternate_scan;
      guint8 repeat_first_field;
      guint8 chroma_420_type;
      guint8 progressive_frame;
      guint8 composite_display;
      guint8 v_axis;
      guint8 field_sequence;
      guint8 sub_carrier;
      guint8 burst_amplitude;
      guint8 sub_carrier_phase;
    };

### struct GstMpegVideoQuantMatrixExt

    struct GstMpegVideoQuantMatrixExt {
     guint8 load_intra_quantiser_matrix;
     guint8 intra_quantiser_matrix[64];
     guint8 load_non_intra_quantiser_matrix;
     guint8 non_intra_quantiser_matrix[64];
     guint8 load_chroma_intra_quantiser_matrix;
     guint8 chroma_intra_quantiser_matrix[64];
     guint8 load_chroma_non_intra_quantiser_matrix;
     guint8 chroma_non_intra_quantiser_matrix[64];
    };