libmsx
C library for MSX
Loading...
Searching...
No Matches
Read from the current position of the stream.

Read from the current position of the stream. More...

+ Collaboration diagram for Read from the current position of the stream.:

Functions

uint8_t mfread_u8 (MemFile *mf)
 Read the next byte from stream pointed by mf.
 
size_t mfread (MemFile *mf, void *ptr, size_t size)
 Read some bytes from stream pointed by mf.
 
uint16_t mfread_u16 (MemFile *mf)
 Read the next 16-bit of little-endian value from stream pointed by mf.
 
uint32_t mfread_u32 (MemFile *mf)
 Read the next 32-bit of little-endian value from stream pointed by mf.
 

Detailed Description

Read from the current position of the stream.

Function Documentation

◆ mfread_u8()

uint8_t mfread_u8 ( MemFile mf)

Read the next byte from stream pointed by mf.

Parameters
mfPointer to opened stream pointer.
Returns
The byte read.

◆ mfread()

size_t mfread ( MemFile mf,
void *  ptr,
size_t  size 
)

Read some bytes from stream pointed by mf.

Parameters
mfPointer to opened stream pointer.
ptrPointer to buffer into which bytes are read.
sizeExpected number of bytes.
Returns
Actual number of bytes read.

◆ mfread_u16()

uint16_t mfread_u16 ( MemFile mf)
inline

Read the next 16-bit of little-endian value from stream pointed by mf.

Parameters
mfPointer to opened stream pointer.
Returns
The 16-bit value read.

Definition at line 158 of file memfile.h.

◆ mfread_u32()

uint32_t mfread_u32 ( MemFile mf)
inline

Read the next 32-bit of little-endian value from stream pointed by mf.

Parameters
mfPointer to opened stream pointer.
Returns
The 32-bit value read.

Definition at line 171 of file memfile.h.