nixamp 0.7.31 → 0.7.32

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/audio.js CHANGED
@@ -160,16 +160,20 @@ export class Stream {
160
160
  this.decoder = spawn(ff, [
161
161
  ...ffRest,
162
162
  "-hide_banner", "-loglevel", "error",
163
- // Paced to real time when nothing is draining the pipe at real time.
163
+ // Always paced to real time, because playing is a real-time act.
164
164
  //
165
- // With speakers, ffplay pulls samples at the rate a person hears them
166
- // and the decoder is held back by that. Without them -- which is every
167
- // server -- nothing pushes back, ffmpeg decodes as fast as the disk
168
- // allows, and `position` runs away: a film reached its end in a couple
169
- // of minutes. That number is what a watch party is synchronised to, so a
170
- // clock that runs at nineteen times normal speed is not a small
171
- // cosmetic fault; it is the whole feature not working.
172
- ...(this.tools.play === null ? ["-re"] : []),
165
+ // Decoding is meant to keep pace with listening, and `position` is what
166
+ // a watch party synchronises to. Left unpaced it runs at whatever speed
167
+ // the disk manages -- a film reached its end in a couple of minutes, and
168
+ // every viewer was handed a position the server had already raced past.
169
+ //
170
+ // This was first written as "pace only when there is no player", which
171
+ // looked right and was not: a server has an ffplay binary sitting there
172
+ // that cannot open an audio device, so it exits at once and drains
173
+ // nothing, while its mere existence said pacing was somebody else's job.
174
+ // Whether a machine can make a sound is not a thing to infer from a file
175
+ // being on disk. Measured with that condition in place: still 13.8x.
176
+ "-re",
173
177
  ...(from > 0 ? ["-ss", String(from)] : []),
174
178
  "-i", track.path,
175
179
  "-f", "f32le", "-ac", String(CHANNELS), "-ar", String(RATE), "-",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nixamp",
3
- "version": "0.7.31",
3
+ "version": "0.7.32",
4
4
  "description": "It really whips the terminal's ass. A Winamp-shaped audio player for your terminal.",
5
5
  "license": "MIT",
6
6
  "type": "module",
package/src/audio.ts CHANGED
@@ -186,16 +186,20 @@ export class Stream {
186
186
  this.decoder = spawn(ff, [
187
187
  ...ffRest,
188
188
  "-hide_banner", "-loglevel", "error",
189
- // Paced to real time when nothing is draining the pipe at real time.
189
+ // Always paced to real time, because playing is a real-time act.
190
190
  //
191
- // With speakers, ffplay pulls samples at the rate a person hears them
192
- // and the decoder is held back by that. Without them -- which is every
193
- // server -- nothing pushes back, ffmpeg decodes as fast as the disk
194
- // allows, and `position` runs away: a film reached its end in a couple
195
- // of minutes. That number is what a watch party is synchronised to, so a
196
- // clock that runs at nineteen times normal speed is not a small
197
- // cosmetic fault; it is the whole feature not working.
198
- ...(this.tools.play === null ? ["-re"] : []),
191
+ // Decoding is meant to keep pace with listening, and `position` is what
192
+ // a watch party synchronises to. Left unpaced it runs at whatever speed
193
+ // the disk manages -- a film reached its end in a couple of minutes, and
194
+ // every viewer was handed a position the server had already raced past.
195
+ //
196
+ // This was first written as "pace only when there is no player", which
197
+ // looked right and was not: a server has an ffplay binary sitting there
198
+ // that cannot open an audio device, so it exits at once and drains
199
+ // nothing, while its mere existence said pacing was somebody else's job.
200
+ // Whether a machine can make a sound is not a thing to infer from a file
201
+ // being on disk. Measured with that condition in place: still 13.8x.
202
+ "-re",
199
203
  ...(from > 0 ? ["-ss", String(from)] : []),
200
204
  "-i", track.path,
201
205
  "-f", "f32le", "-ac", String(CHANNELS), "-ar", String(RATE), "-",
package/web/dist/sw.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /* nixamp service worker — generated, do not edit */
2
- const CACHE = "nixamp-1788974890049";
2
+ const CACHE = "nixamp-1788975380974";
3
3
  const PRECACHE = [
4
4
  "/",
5
5
  "/apple-touch-icon.png",