QuakeForge  0.7.2.210-815cf
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages

Representation of sound loaded that is streamed in as needed. More...

Collaboration diagram for sfxstream_s:
[legend]

Data Fields

sfxbuffer_t buffer
 
int error
 an error occured while reading More...
 
void * file
 handle for "file" representing the stream More...
 
long(* ll_read )(void *cb_data, float **data)
 Read data from the stream. More...
 
int(* ll_seek )(sfxstream_t *stream, int pos)
 Seek to an absolute position within the stream (low level). More...
 
unsigned pos
 position of next frame full stream More...
 
int(* read )(sfxstream_t *stream, float *data, int frames)
 Read data from the stream. More...
 
int(* seek )(sfxstream_t *stream, int pos)
 Seek to an absolute position within the stream. More...
 
sfx_tsfx
 owning sfx_t instance More...
 
void * state
 resampler state information More...
 
wavinfo_t wavinfo
 description of sound data More...
 

Detailed Description

Representation of sound loaded that is streamed in as needed.

Field Documentation

sfxbuffer_t buffer
int error

an error occured while reading

void* file

handle for "file" representing the stream

long(* ll_read)(void *cb_data, float **data)

Read data from the stream.

This is a low-level function used by sfxstream_t::read. The read samples will be at the sample rate of the underlying stream.

Parameters
cb_datastream relevant infomation (actually sfxstream_t ("this"), but this signature is used for compatibility with libsamplerate
dataaddress of pointer to be set to point to the buffer holding the samples
int(* ll_seek)(sfxstream_t *stream, int pos)

Seek to an absolute position within the stream (low level).

Parameters
stream"this"
posframe position with the stream
unsigned pos

position of next frame full stream

int(* read)(sfxstream_t *stream, float *data, int frames)

Read data from the stream.

This is a high-level function for use in the mixer. The read samples will always at be the correct sample rate for the mixer, reguardless of the sample rate in the underlying stream.

Parameters
stream"this"
datadestination of read data
framesmaximum number of frames to read from stream
Returns
number of frames read from stream
int(* seek)(sfxstream_t *stream, int pos)

Seek to an absolute position within the stream.

Parameters
stream"this"
posframe position with the stream
sfx_t* sfx

owning sfx_t instance

void* state

resampler state information

wavinfo_t wavinfo

description of sound data


The documentation for this struct was generated from the following file: