int writer_num;
/** Writer-specific data. */
void *private_data;
- /** Pointer to the group this node belongs to. */
- struct writer_node_group *wng;
/** The writer-specific configuration of this node. */
void *conf;
- /** How much of the wng's buffer is already written. */
- size_t written;
struct btr_node *btrn;
struct task task;
size_t min_iqs;
btr_command_handler execute;
};
-/**
- * Describes a set of writer nodes that all write the same stream.
- */
-struct writer_node_group {
- /** Number of nodes belonging to this group. */
- unsigned num_writers;
- /** Array of pointers to the corresponding writer nodes. */
- struct writer_node *writer_nodes;
- /** Non-zero if an error or end of file was encountered by the feeding task. */
- int *input_error;
- /** Current output buffer. */
- char **bufp;
- /** Number of bytes loaded in the output buffer. */
- size_t *loaded;
- /** Number of audio channels of the current stream. */
- unsigned int *channels;
- /** Sample rate of the current stream. */
- unsigned int *samplerate;
- /** The task associated to this group. */
- struct task task;
- /** Whether the group is open, i.e. wng_open() was called. */
- int open;
- /** Max number of bytes written in the previous post_select() call. */
- int last_written;
-};
-
-/** Loop over each writer node in a writer group. */
-#define FOR_EACH_WRITER_NODE(i, wng) for (i = 0; i < (wng)->num_writers; i++)
/** Loop over each supported writer. */
#define FOR_EACH_WRITER(i) for (i = 0; i < NUM_SUPPORTED_WRITERS; i++)