mirror of
http://www.pogo.org.uk/~mark/trx.git
synced 2024-11-21 18:05:06 +01:00
Help message
This commit is contained in:
parent
b5ce1fcc9d
commit
44f8e51c10
2
notice.h
2
notice.h
@ -1,6 +1,6 @@
|
||||
#ifndef NOTICE_H
|
||||
#define NOTICE_H
|
||||
|
||||
#define COPYRIGHT "(C) Copyright 2012 Mark Hills <mark@xwax.org>"
|
||||
#define COPYRIGHT "trx (C) Copyright 2012 Mark Hills <mark@xwax.org>"
|
||||
|
||||
#endif
|
||||
|
12
rx.c
12
rx.c
@ -105,12 +105,13 @@ static int run_rx(RtpSession *session,
|
||||
|
||||
static void usage(FILE *fd)
|
||||
{
|
||||
fprintf(fd, "Usage: rx [<parameters>]\n");
|
||||
fprintf(fd, "Usage: rx [<parameters>]\n"
|
||||
"Real-time audio receiver over IP\n");
|
||||
|
||||
fprintf(fd, "\nAudio device (ALSA) parameters:\n");
|
||||
fprintf(fd, " -d <dev> Device name (default '%s')\n",
|
||||
DEFAULT_DEVICE);
|
||||
fprintf(fd, " -m <ms> Buffer time (milliseconds, default %d)\n",
|
||||
fprintf(fd, " -m <ms> Buffer time (default %d milliseconds)\n",
|
||||
DEFAULT_BUFFER);
|
||||
|
||||
fprintf(fd, "\nNetwork parameters:\n");
|
||||
@ -118,11 +119,11 @@ static void usage(FILE *fd)
|
||||
DEFAULT_ADDR);
|
||||
fprintf(fd, " -p <port> UDP port number (default %d)\n",
|
||||
DEFAULT_PORT);
|
||||
fprintf(fd, " -j <ms> Jitter buffer (milliseconds, default %d)\n",
|
||||
fprintf(fd, " -j <ms> Jitter buffer (default %d milliseconds)\n",
|
||||
DEFAULT_JITTER);
|
||||
|
||||
fprintf(fd, "\nEncoding parameters (must match sender):\n");
|
||||
fprintf(fd, " -r <rate> Sample rate (default %d)\n",
|
||||
fprintf(fd, " -r <rate> Sample rate (default %dHz)\n",
|
||||
DEFAULT_RATE);
|
||||
fprintf(fd, " -c <n> Number of channels (default %d)\n",
|
||||
DEFAULT_CHANNELS);
|
||||
@ -148,7 +149,7 @@ int main(int argc, char *argv[])
|
||||
channels = DEFAULT_CHANNELS,
|
||||
port = DEFAULT_PORT;
|
||||
|
||||
fputs("rx " COPYRIGHT "\n", stderr);
|
||||
fputs(COPYRIGHT "\n", stderr);
|
||||
|
||||
for (;;) {
|
||||
int c;
|
||||
@ -156,7 +157,6 @@ int main(int argc, char *argv[])
|
||||
c = getopt(argc, argv, "c:d:h:j:m:p:v:");
|
||||
if (c == -1)
|
||||
break;
|
||||
|
||||
switch (c) {
|
||||
case 'c':
|
||||
channels = atoi(optarg);
|
||||
|
14
tx.c
14
tx.c
@ -92,12 +92,13 @@ static int run_tx(snd_pcm_t *snd,
|
||||
|
||||
static void usage(FILE *fd)
|
||||
{
|
||||
fprintf(fd, "Usage: tx [<parameters>]\n");
|
||||
fprintf(fd, "Usage: tx [<parameters>]\n"
|
||||
"Real-time audio transmitter over IP\n");
|
||||
|
||||
fprintf(fd, "\nAudio device (ALSA) parameters:\n");
|
||||
fprintf(fd, " -d <dev> Device name (default '%s')\n",
|
||||
DEFAULT_DEVICE);
|
||||
fprintf(fd, " -m <ms> Buffer time (milliseconds, default %d)\n",
|
||||
fprintf(fd, " -m <ms> Buffer time (default %d milliseconds)\n",
|
||||
DEFAULT_BUFFER);
|
||||
|
||||
fprintf(fd, "\nNetwork parameters:\n");
|
||||
@ -107,11 +108,11 @@ static void usage(FILE *fd)
|
||||
DEFAULT_PORT);
|
||||
|
||||
fprintf(fd, "\nEncoding parameters:\n");
|
||||
fprintf(fd, " -r <rate> Sample rate (default %d)\n",
|
||||
fprintf(fd, " -r <rate> Sample rate (default %dHz)\n",
|
||||
DEFAULT_RATE);
|
||||
fprintf(fd, " -c <n> Number of channels (default %d)\n",
|
||||
DEFAULT_CHANNELS);
|
||||
fprintf(fd, " -f <bytes> Frame size (default %d)\n",
|
||||
fprintf(fd, " -f <n> Frame size (default %d samples, see below)\n",
|
||||
DEFAULT_FRAME);
|
||||
fprintf(fd, " -b <kbps> Bitrate (approx., default %d)\n",
|
||||
DEFAULT_BITRATE);
|
||||
@ -119,6 +120,9 @@ static void usage(FILE *fd)
|
||||
fprintf(fd, "\nDisplay parameters:\n");
|
||||
fprintf(fd, " -v <n> Verbosity level (default %d)\n",
|
||||
DEFAULT_VERBOSE);
|
||||
|
||||
fprintf(fd, "\nAllowed frame sizes (-f) are defined by the Opus codec. For example,\n"
|
||||
"at 48000Hz the permitted values are 120, 240, 480 or 960.\n");
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
@ -139,7 +143,7 @@ int main(int argc, char *argv[])
|
||||
kbps = DEFAULT_BITRATE,
|
||||
port = DEFAULT_PORT;
|
||||
|
||||
fputs("tx " COPYRIGHT "\n", stderr);
|
||||
fputs(COPYRIGHT "\n", stderr);
|
||||
|
||||
for (;;) {
|
||||
int c;
|
||||
|
Loading…
Reference in New Issue
Block a user