Applied patch from vishnu to remove can_seek.

Original commit message from CVS:
Applied patch from vishnu to remove can_seek.
This commit is contained in:
David Schleef 2003-07-17 08:32:06 +00:00
parent f97a52c4ed
commit dc18488304

View file

@ -64,7 +64,6 @@ struct _GstMad {
/* info */ /* info */
struct mad_header header; struct mad_header header;
gboolean new_header; gboolean new_header;
gboolean can_seek;
guint framecount; guint framecount;
gint vbr_average; /* average bitrate */ gint vbr_average; /* average bitrate */
guint64 vbr_rate; /* average * framecount */ guint64 vbr_rate; /* average * framecount */
@ -711,10 +710,6 @@ gst_mad_src_event (GstPad *pad, GstEvent *event)
break; break;
/* the all-formats seek logic */ /* the all-formats seek logic */
case GST_EVENT_SEEK: case GST_EVENT_SEEK:
if (!mad->can_seek) {
g_warning ("MAD: can't seek now, seek ignored");
break;
}
if (mad->index) if (mad->index)
res = index_seek (mad, pad, event); res = index_seek (mad, pad, event);
else else
@ -1221,9 +1216,6 @@ gst_mad_chain (GstPad *pad, GstBuffer *buffer)
rate = mad->frame.header.samplerate; rate = mad->frame.header.samplerate;
#endif #endif
/* at this point we can accept seek events */
mad->can_seek = TRUE;
gst_mad_update_info (mad); gst_mad_update_info (mad);
if (mad->channels != nchannels || mad->rate != rate) { if (mad->channels != nchannels || mad->rate != rate) {
@ -1369,7 +1361,6 @@ gst_mad_change_state (GstElement *element)
mad_frame_init (&mad->frame); mad_frame_init (&mad->frame);
mad_synth_init (&mad->synth); mad_synth_init (&mad->synth);
mad->tempsize = 0; mad->tempsize = 0;
mad->can_seek = FALSE;
mad->total_samples = 0; mad->total_samples = 0;
mad->rate = 0; mad->rate = 0;
mad->channels = 0; mad->channels = 0;