Specifications

10-6 Programmer’s Guide Sega
Psy-Q Development System
The PClseek Function
Description
This function seeks the file pointer to the specified position in the file.
Prototype
int
PClseek
(int fd, int offset, int mode)
passed: file-handle
seek offset
seek mode
(mode
0
=rel to start, mode
1
=rel to current fp,
mode
2
=rel to end)
return: absolute value of new file pointer position
Remarks
To find the length of a file which is to be read into memory, perform:
Len = PClseek( fd, 0, 2);
This will set Len
to the length of the file and can then be passed to PCread().