size = MIN (size, avail);
buffer = gst_adapter_take_buffer (self->adapter, size);
+ buffer = gst_buffer_make_writable (buffer);
/* After a reset we have to set the discont flag */
if (self->current_offset == 0)
- GST_BUFFER_FLAG_SET (buffer, GST_BUFFER_FLAG_DISCONT);
+ GST_BUFFER_FLAG_SET (buffer,
+ GST_BUFFER_FLAG_DISCONT | GST_BUFFER_FLAG_RESYNC);
+ else
+ GST_BUFFER_FLAG_UNSET (buffer,
+ GST_BUFFER_FLAG_DISCONT | GST_BUFFER_FLAG_RESYNC);
resync_time_diff =
gst_util_uint64_scale (self->current_offset, GST_SECOND, rate);