Home

seekoffset

Seekoffset is a term used in computing to describe the distance or position to move the read or write pointer within a data source when performing a seek operation. It is typically expressed as a numeric value representing an offset, usually in bytes, though some APIs allow other units. The precise meaning of seekoffset depends on the API, and it is often paired with an origin flag that indicates where the offset starts, such as the beginning of the data, the current position, or the end.

In POSIX and most C libraries, seeking is done with an offset and a whence or origin

In practice seekoffset enables random-access I/O, fast-forwarding or rewinding streams, resuming from a known position, and

Limitations include that not all data sources support seeking; for non-seekable streams such as certain network

See also: seek, lseek, tell, offset, SEEK_SET, SEEK_CUR, SEEK_END.

parameter.
Although
the
standard
call
uses
separate
offset
and
origin
arguments,
some
wrapper
libraries
or
documentation
refer
to
this
parameter
combination
as
seekoffset.
In
such
contexts,
the
seekoffset
parameter
indicates
the
distance
to
move
from
the
specified
origin.
implementing
features
like
seeking
within
multimedia
playback
or
large
binary
files.
For
example,
a
function
call
seek(data_source,
seekoffset,
origin)
moves
the
current
position
to
origin
+
seekoffset.
Different
environments
may
represent
the
origin
using
constants
such
as
SEEK_SET,
SEEK_CUR,
or
SEEK_END.
protocols
or
compressed
data,
a
seekoffset-based
repositioning
may
be
unsupported
or
require
re-reading
or
decoding.