fdds_lseek8 - seek (8 byte precision) position within DDS binary stream


SYNOPSIS

#include <fdds.h> (fixed-format sources)
#include <f90dds.h> (free-format sources)

integer*8 function fdds_lseek8(bin, tag, offset, whence)

integer bin
integer tag
integer*8 offset
integer whence

DESCRIPTION

This function seeks to a new position in a binary stream.
Pipe media only support forward seeks.

ARGUMENTS

"bin" is a binary tag, previously obtained from fddx_in. It specifies the binary stream on which to seek.

"tag" is a field tag which specifies a type of object offset refers to. E.g. DDS_REAL should be used if offset is measured in REAL words.
When tag = 0, the nominal DDS target type (which is a trace) is used.

"offset" is a position measured relative to the whence origin. The offset should be an integer number of tag types.

whence     seek origin
SEEK_SET   beginning of the file
SEEK_CUR   current file position
SEEK_END   end of the file
    

OUTPUT

The current binary stream position may be changed. The return value is the new offset or -1 if an error occurred.

EXAMPLES

integer bin
integer*8 offset
...
c  skip next 10000000 traces
offset = 10000000
j = fdds_lseek8(bin, 0, offset, SEEK_CUR)
    

AUTHOR

R. L. Selzler, EPTG (May, 1994)