if (start == -1)
start = 0;
break;
- case GST_SEEK_TYPE_CUR:
- {
- gint64 sstart = (gint64) start;
- /* add start to currently configured segment */
- if (sstart > 0 || segment->start > -sstart)
- start = segment->start + start;
- else
- start = 0;
- break;
- }
case GST_SEEK_TYPE_END:
if (segment->duration != -1) {
/* add start to total length */
case GST_SEEK_TYPE_SET:
/* stop holds required value */
break;
- case GST_SEEK_TYPE_CUR:
- if (segment->stop != -1) {
- gint64 sstop = (gint64) stop;
- if (sstop > 0 || segment->stop > -sstop)
- stop = segment->stop + stop;
- else
- stop = 0;
- } else
- stop = -1;
- break;
case GST_SEEK_TYPE_END:
if (segment->duration != -1) {
stop = segment->duration + stop;
/**
* GstSeekType:
* @GST_SEEK_TYPE_NONE: no change in position is required
- * @GST_SEEK_TYPE_CUR: change relative to currently configured segment. This
- * can't be used to seek relative to the current playback position - do a
- * position query, calculate the desired position and then do an absolute
- * position seek instead if that's what you want to do.
* @GST_SEEK_TYPE_SET: absolute position is requested
* @GST_SEEK_TYPE_END: relative position to duration is requested
*
typedef enum {
/* one of these */
GST_SEEK_TYPE_NONE = 0,
- GST_SEEK_TYPE_CUR = 1,
- GST_SEEK_TYPE_SET = 2,
- GST_SEEK_TYPE_END = 3
+ GST_SEEK_TYPE_SET = 1,
+ GST_SEEK_TYPE_END = 2
} GstSeekType;
/**