XAPO_BUFFER_FLAGS Enumeration

Describes the contents of a stream buffer.

Syntax

typedef enum XAPO_BUFFER_FLAGS
{
    XAPO_BUFFER_SILENT,
    XAPO_BUFFER_VALID
} XAPO_BUFFER_FLAGS;  

Remarks

This metadata can be used to implement optimizations that require knowledge of a stream buffer’s contents. For example, XAPOs that always produce silent output from silent input can check the flag on the input stream buffer to determine if any signal processing is necessary. If silent, the XAPO can simply set the flag on the output stream buffer to silent and return, thus averting the work of processing silent data.

Likewise, XAPOs that receive valid input data, but generate silence (for any reason), may set the output stream buffer’s flag accordingly, rather than writing silent samples to the buffer.

These flags represent what should be assumed is in the respective buffer. The flags may not reflect what is actually stored in memory. For example, the XAPO_BUFFER_SILENT indicates that silent data should be assumed, however the respective memory may be uninitialized

Constants

Constant Description
XAPO_BUFFER_SILENT Stream buffer contains only silent samples.
XAPO_BUFFER_VALID Stream buffer contains audio data to be processed.

Requirements

Header: Declared in xapo.h.

Library: Use xapobase.lib.