ref: 219c645fe7cd8398f84a031862808ea9e0040bf0
parent: 411fec76ff605c8ac00cee05635ef7b3665b221e
author: qwx <qwx@sciops.net>
date: Wed Jan 25 22:24:18 EST 2023
promote stereo option to runtime toggle
--- a/pplay.c
+++ b/pplay.c
@@ -79,7 +79,7 @@
static void
usage(void)
{
- fprint(2, "usage: %s [-Dbcs] [pcm]\n", argv0);
+ fprint(2, "usage: %s [-Dbc] [pcm]\n", argv0);
threadexits("usage");
}
@@ -96,7 +96,6 @@
case 'D': debug = 1; debugdraw = 1; break;
case 'b': notriob = 1; break;
case 'c': cat = 1; break;
- case 's': stereo = 1; break;
default: usage();
}ARGEND
if((fd = *argv != nil ? open(*argv, OREAD) : 0) < 0)
@@ -147,6 +146,7 @@
case Kdel:
case 'q': threadexitsall(nil);
case 'D': debug ^= 1; debugdraw ^= 1; break;
+ case 'S': stereo ^= 1; redraw(1); break;
case ' ': toggleplay(); break;
case 'b': setjump(dot.from); break;
case Kesc: setrange(0, totalsz); update(); break;