mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-07-17 11:58:23 +00:00
a52dec: Use a debug category, Output timestamps correctly
Original commit message from CVS: a52dec: Use a debug category, Output timestamps correctly Emit tag info, Handle events, tell liba52dec about cpu capabilities so it can use MMX etc. dvdec: Fix a crasher accessing invalid memory dvdnavsrc:Some support for byte-format seeking. Small fixes for still frames and menu button overlays mpeg2dec: Use a debug category. Adjust the report level of several items to LOG. Call mpeg2_custom_fbuf to mark our buffers as 'custom buffers' so it doesn't lose the GstBuffer pointer navseek: Add the navseek debug element for seeking back and forth in a video stream using arrow keys. mpeg2subt:Pretty much a complete rewrite. Now a loopbased element. May still require work to properly synchronise subtitle buffers. mpegdemux: dvddemux: Don't attempt to create subbuffers of size 0 Reduce a couple of error outputs to warnings. y4mencode:Output the y4m frame header correctly
This commit is contained in:
parent
23fb6b5cae
commit
bc4cb91fab
57
ChangeLog
57
ChangeLog
|
@ -1,3 +1,60 @@
|
|||
2004-04-01 Jan Schmidt <thaytan@mad.scientist.com>
|
||||
|
||||
* ext/a52dec/gsta52dec.c: (gst_a52dec_get_type), (gst_a52dec_init),
|
||||
(gst_a52dec_push), (gst_a52dec_handle_event),
|
||||
(gst_a52dec_update_streaminfo), (gst_a52dec_loop),
|
||||
(gst_a52dec_change_state):
|
||||
* ext/a52dec/gsta52dec.h:
|
||||
Use a debug category, Output timestamps correctly
|
||||
Emit tag info, Handle events, tell liba52dec about cpu
|
||||
capabilities so it can use MMX etc.
|
||||
* ext/dv/gstdvdec.c: (gst_dvdec_loop), (gst_dvdec_change_state):
|
||||
Fix a crasher accessing invalid memory
|
||||
* ext/dvdnav/dvdnavsrc.c: (dvdnavsrc_init),
|
||||
(dvdnavsrc_update_highlight), (dvdnavsrc_loop),
|
||||
(dvdnavsrc_get_event_mask), (dvdnav_handle_navigation_event),
|
||||
(dvdnavsrc_event), (dvdnavsrc_get_formats), (dvdnavsrc_convert),
|
||||
(dvdnavsrc_query):
|
||||
Some support for byte-format seeking.
|
||||
Small fixes for still frames and menu button overlays
|
||||
* ext/mpeg2dec/gstmpeg2dec.c: (gst_mpeg2dec_get_type),
|
||||
(gst_mpeg2dec_alloc_buffer):
|
||||
Use a debug category. Adjust the report level of several items to
|
||||
LOG. Call mpeg2_custom_fbuf to mark our buffers as 'custom buffers'
|
||||
so it doesn't lose the GstBuffer pointer
|
||||
* gst/debug/Makefile.am:
|
||||
* gst/debug/gstdebug.c: (plugin_init):
|
||||
* gst/debug/gstnavseek.c: (gst_navseek_get_type),
|
||||
(gst_navseek_base_init), (gst_navseek_class_init),
|
||||
(gst_navseek_init), (gst_navseek_seek),
|
||||
(gst_navseek_handle_src_event), (gst_navseek_set_property),
|
||||
(gst_navseek_get_property), (gst_navseek_chain),
|
||||
(gst_navseek_plugin_init):
|
||||
* gst/debug/gstnavseek.h:
|
||||
Add the navseek debug element for seeking back and forth in a
|
||||
video stream using arrow keys.
|
||||
* gst/mpeg2sub/gstmpeg2subt.c: (gst_mpeg2subt_get_type),
|
||||
(gst_mpeg2subt_base_init), (gst_mpeg2subt_class_init),
|
||||
(gst_mpeg2subt_init), (gst_mpeg2subt_finalize),
|
||||
(gst_mpeg2subt_getcaps_video), (gst_mpeg2subt_link_video),
|
||||
(gst_mpeg2subt_handle_video), (gst_mpeg2subt_src_event),
|
||||
(gst_mpeg2subt_parse_header), (gst_get_nibble),
|
||||
(gst_setup_palette), (gst_get_rle_code), (gst_draw_rle_line),
|
||||
(gst_merge_uv_data), (gst_mpeg2subt_merge_title),
|
||||
(gst_update_still_frame), (gst_mpeg2subt_handle_subtitle),
|
||||
(gst_mpeg2subt_handle_dvd_event), (gst_mpeg2subt_loop):
|
||||
* gst/mpeg2sub/gstmpeg2subt.h:
|
||||
Pretty much a complete rewrite. Now a loopbased element. May still
|
||||
require work to properly synchronise subtitle buffers.
|
||||
* gst/mpegstream/gstdvddemux.c: (gst_dvd_demux_process_private),
|
||||
(gst_dvd_demux_send_subbuffer):
|
||||
* gst/mpegstream/gstmpegdemux.c: (gst_mpeg_demux_send_subbuffer):
|
||||
Don't attempt to create subbuffers of size 0
|
||||
Reduce a couple of error outputs to warnings.
|
||||
* gst/y4m/gsty4mencode.c: (gst_y4mencode_sinkconnect),
|
||||
(gst_y4mencode_chain):
|
||||
Output the y4m frame header correctly.
|
||||
|
||||
2004-04-01 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||
|
||||
* gst/adder/gstadder.c: (gst_adder_get_type), (gst_adder_loop):
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -44,26 +44,59 @@ extern "C" {
|
|||
typedef struct _GstMpeg2Subt GstMpeg2Subt;
|
||||
typedef struct _GstMpeg2SubtClass GstMpeg2SubtClass;
|
||||
|
||||
/* Hold premultimplied colour values */
|
||||
typedef struct YUVA_val {
|
||||
guint16 Y;
|
||||
guint16 U;
|
||||
guint16 V;
|
||||
guint16 A;
|
||||
} YUVA_val;
|
||||
|
||||
struct _GstMpeg2Subt {
|
||||
GstElement element;
|
||||
|
||||
GstPad *videopad,*subtitlepad,*srcpad;
|
||||
|
||||
GstBuffer *partialbuf; /* previous buffer (if carryover) */
|
||||
|
||||
gboolean have_title;
|
||||
GstBuffer *partialbuf; /* Collect together subtitle buffers until we have a full control sequence */
|
||||
GstBuffer *hold_frame; /* Hold back one frame of video */
|
||||
GstBuffer *still_frame;
|
||||
|
||||
guint16 packet_size;
|
||||
guint16 data_size;
|
||||
|
||||
gint offset[2];
|
||||
guchar color[5];
|
||||
guchar trans[4];
|
||||
|
||||
guint duration;
|
||||
YUVA_val palette_cache[4];
|
||||
|
||||
gint width, height;
|
||||
/*
|
||||
* Store 1 line width of U, V and A respectively.
|
||||
* Y is composited direct onto the frame.
|
||||
*/
|
||||
guint16 *out_buffers[3];
|
||||
guchar subtitle_index[4];
|
||||
guchar menu_index[4];
|
||||
guchar subtitle_alpha[4];
|
||||
guchar menu_alpha[4];
|
||||
|
||||
guint32 current_clut[16];
|
||||
|
||||
gboolean have_title;
|
||||
gboolean forced_display;
|
||||
|
||||
GstClockTime start_display_time;
|
||||
GstClockTime end_display_time;
|
||||
gint left, top,
|
||||
right, bottom;
|
||||
gint clip_left, clip_top,
|
||||
clip_right, clip_bottom;
|
||||
|
||||
gint in_width, in_height;
|
||||
gint current_button;
|
||||
|
||||
GstData *pending_video_buffer;
|
||||
GstClockTime next_video_time;
|
||||
GstData *pending_subtitle_buffer;
|
||||
GstClockTime next_subtitle_time;
|
||||
};
|
||||
|
||||
struct _GstMpeg2SubtClass {
|
||||
|
|
|
@ -148,21 +148,19 @@ gst_y4mencode_sinkconnect (GstPad * pad, const GstCaps * caps)
|
|||
|
||||
structure = gst_caps_get_structure (caps, 0);
|
||||
|
||||
gst_structure_get_int (structure, "width", &filter->width);
|
||||
gst_structure_get_int (structure, "height", &filter->height);
|
||||
gst_structure_get_double (structure, "framerate", &fps);
|
||||
if (!gst_structure_get_int (structure, "width", &filter->width) ||
|
||||
!gst_structure_get_int (structure, "height", &filter->height) ||
|
||||
!gst_structure_get_double (structure, "framerate", &fps))
|
||||
return GST_PAD_LINK_REFUSED;
|
||||
|
||||
/* find fps idx */
|
||||
idx = 0;
|
||||
for (i = 1; i < 9; i++) {
|
||||
if (idx == -1) {
|
||||
idx = i;
|
||||
} else {
|
||||
gdouble old_diff = fabs (framerates[idx] - fps),
|
||||
new_diff = fabs (framerates[i] - fps);
|
||||
gdouble old_diff = fabs (framerates[idx] - fps),
|
||||
new_diff = fabs (framerates[i] - fps);
|
||||
|
||||
if (new_diff < old_diff) {
|
||||
idx = i;
|
||||
}
|
||||
if (new_diff < old_diff) {
|
||||
idx = i;
|
||||
}
|
||||
}
|
||||
filter->fps_idx = idx;
|
||||
|
@ -209,7 +207,7 @@ gst_y4mencode_chain (GstPad * pad, GstData * _data)
|
|||
GST_BUFFER_DATA (outbuf) = g_malloc (GST_BUFFER_SIZE (buf) + 256);
|
||||
|
||||
if (filter->init) {
|
||||
header = "YUV4MPEG %d %d %d\nFRAME\n";
|
||||
header = "YUV4MPEG W%d H%d I? %d\nFRAME\n";
|
||||
filter->init = FALSE;
|
||||
} else {
|
||||
header = "FRAME\n";
|
||||
|
|
Loading…
Reference in a new issue