int ReadFile (char *filename, int32 size, long *buffer, long offset)
ReadFile()
uses the file system to read a file or a portion of a file into memory. It performs up to four retries on each block read if the filesystem returns an error.
ReadFile()
is useful for loading a portion of a file, optionally starting at some offset into the file. For loading an entire file starting at offset zero, the LoadFile()
function is three to four times faster.
ReadFile()
fills the buffer with size bytes, beginning at offset.
LoadFile