Supported Browsers Home   
MGL_fopen Previous   
MGL_freeRegion Next   
External Functions Up   

MGL_fread

Reads data from a stream.

Declaration

size_t MGLAPI MGL_fread(
    void *ptr,
    size_t size,
    size_t n,
    FILE *f)

Prototype In

mgraph.h

Parameters

ptr

Pointer to block in stream at which to begin read

size

Size of items to be read from stream

n

Number of items to be read from stream

f

Stream to be read

 

Return Value

Number of items read in, or a short count (possibly 0).

Description

This function is identical to the C library fread function, but goes via the MGL's internal file handling function pointers, which by default simply points to the standard C library functions. These functions are intended to allow the application programmer to override all the MGL file I/O functions with MGL_setFileIO, for custom I/O handling.

See Also

MGL_fopen, MGL_fclose, MGL_fseek, MGL_ftell, MGL_fwrite, MGL_setFileIO

Copyright © 2002 SciTech Software, Inc. Visit our web site at http://www.scitechsoft.com