X-Git-Url: http://git.tuebingen.mpg.de/?a=blobdiff_plain;f=play.c;h=055293a905807a7641e382de7e7ff6cd9f8f15a7;hb=7c988892fc0bcde45f2afc7480717335bea5bbc4;hp=262f69ee4dc3d57686904fafb5597e1d955a189d;hpb=15e3068cd0b95a7ae37f8edc2eceea3b2a3a49a9;p=paraslash.git diff --git a/play.c b/play.c index 262f69ee..055293a9 100644 --- a/play.c +++ b/play.c @@ -24,16 +24,6 @@ #include "write.h" #include "fd.h" -/** - * Besides playback tasks which correspond to the receiver/filter/writer nodes, - * para_play creates two further tasks: The play task and the i9e task. It is - * important whether a function can be called in the context of para_play or - * i9e or both. As a rule, all command handlers are called only in i9e context via - * the line handler (input mode) or the key handler (command mode) below. - * - * Playlist handling is done exclusively in play context. - */ - /** Array of error strings. */ DEFINE_PARA_ERRLIST; @@ -1246,10 +1236,25 @@ out: /** * The main function of para_play. * - * \param argc Standard. - * \param argv Standard. + * \param argc See man page. + * \param argv See man page. + * + * para_play distributes its work by submitting various tasks to the paraslash + * scheduler. The receiver, filter and writer tasks, which are used to play an + * audio file, require one task each to maintain their underlying buffer tree + * node. These tasks only exist when an audio file is playing. + * + * The i9 task, which is submitted and maintained by the i9e subsystem, reads + * an input line and calls the corresponding command handler such as com_stop() + * which is implemented in this file. The command handlers typically write a + * request to the global play_task structure, whose contents are read and acted + * upon by another task, the play task. + * + * As a rule, playlist handling is performed exclusively in play context, i.e. + * in the post-monitor step of the play task, while command handlers are only + * called in i9e context. * - * \return \p EXIT_FAILURE or \p EXIT_SUCCESS. + * \return EXIT_FAILURE or EXIT_SUCCESS. */ int main(int argc, char *argv[]) {