[][src]Type Definition flac_sys::FLAC__StreamEncoderProgressCallback

type FLAC__StreamEncoderProgressCallback = Option<unsafe extern "C" fn(encoder: *const FLAC__StreamEncoder, bytes_written: FLAC__uint64, samples_written: FLAC__uint64, frames_written: c_uint, total_frames_estimate: c_uint, client_data: *mut c_void)>;

Signature for the progress callback.

A function pointer matching this signature may be passed to FLAC__stream_encoder_init*_file() or FLAC__stream_encoder_init*_FILE(). The supplied function will be called when the encoder has finished writing a frame. The \c total_frames_estimate argument to the callback will be based on the value from FLAC__stream_encoder_set_total_samples_estimate().

\note In general, FLAC__StreamEncoder functions which change the state should not be called on the \a encoder while in the callback.

\param encoder The encoder instance calling the callback. \param bytes_written Bytes written so far. \param samples_written Samples written so far. \param frames_written Frames written so far. \param total_frames_estimate The estimate of the total number of frames to be written. \param client_data The callee's client data set through FLAC__stream_encoder_init_*().