After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 343627 - Add QoS to mpeg2dec
Add QoS to mpeg2dec
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-ugly
git master
Other Linux
: Normal enhancement
: 0.10.4
Assigned To: Wim Taymans
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2006-06-01 20:40 UTC by Edgard Lima
Modified: 2006-06-07 16:16 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
gstmpeg2dec.[ch] (4.98 KB, patch)
2006-06-01 20:41 UTC, Edgard Lima
reviewed Details | Review

Description Edgard Lima 2006-06-01 20:40:42 UTC
I ve added a patch to mpeg2dec that adds QoS to it.

Ive already tested it without receiving QoS events and works fine.

Please I would like one to have a look in it and tell me if is OK. Also to give ideias how to test it to get QoS events.
Comment 1 Edgard Lima 2006-06-01 20:41:51 UTC
Created attachment 66622 [details] [review]
gstmpeg2dec.[ch]
Comment 2 Wim Taymans 2006-06-07 09:03:08 UTC
Some remarks:

To convert a QoS timestamp t running time, use:

qostime = gst_segment_to_running_time (&dec->segment, GST_FORMAT_TIME,
        outtime);

Also, mpeg2 normally has B and P frames that can be skipped. 

I'm working on an alternative patch that fixes some other issues with mpeg2dec (like crashing and leaking memory).
Comment 3 Wim Taymans 2006-06-07 16:16:35 UTC
        * ext/mpeg2dec/gstmpeg2dec.c: (gst_mpeg2dec_base_init),
        (gst_mpeg2dec_class_init), (gst_mpeg2dec_init),
        (gst_mpeg2dec_finalize), (gst_mpeg2dec_reset),
        (gst_mpeg2dec_qos_reset), (gst_mpeg2dec_alloc_buffer),
        (gst_mpeg2dec_negotiate_format), (init_dummybuf),
        (handle_sequence), (handle_picture), (handle_slice),
        (gst_mpeg2dec_chain), (gst_mpeg2dec_sink_event),
        (gst_mpeg2dec_src_event), (gst_mpeg2dec_change_state):
        * ext/mpeg2dec/gstmpeg2dec.h:
        Fix padtemplate as we can now do fractional framerates.
        Small cleanups.
        Use GstSegment.
        Add simple frame dropping QoS.
        Precalc buffer output sizes and UV offsets.
        Always give libmpeg2 a valid fbuf when it wants one.
        don't trust libmpeg to discard our buffers but manage it
        ourselves.
        Fixes #343627, #327350, #335288