/** Flags specified as arguments to the grab command. */
enum grab_flags {
- /** Grab the filter input instead of its output. */
- GF_INPUT_GRAB = 1,
/** Stop grabbing if audio file changes. */
- GF_ONE_SHOT = 2,
+ GF_ONE_SHOT = 1,
};
-/**
- * Describes one active grab client.
- *
- * \sa filter_callback, filter_node::callbacks.
- */
+/** Describes one active grab client. */
struct grab_client {
+ /* The value of the -p option. */
+ char *parent;
/** The file descriptor to send the grabbed stream to. */
int fd;
- /** Non-zero if the write() to \a fd failed. */
- int error;
/** See \ref grab_mode. */
enum grab_mode mode;
- /** Point of filter chain to grab. */
- int32_t filter_num;
- /** The number of the desired audio format. */
- int audio_format_num;
/** Flags given at the command line. */
enum grab_flags flags;
- /** The callback data which gets attached to a suitable filter_node. */
- struct filter_callback fcb;
+ /** The point of the grab client's node in the buffer tree. */
+ struct btr_node *btrn;
+ /* The task of this grab client. */
+ struct task task;
/** All grab clients belong either to a filter node or to the inactive list. */
struct list_head node;
};
int grab_client_new(int fd, int argc, char **argv);
-void activate_inactive_grab_clients(int audio_format_num,
- struct filter_chain *fc);
-void activate_grab_client(struct grab_client *gc, struct filter_node *fn);
+void activate_grab_clients(void);
void init_grabbing(void);