psst icon indicating copy to clipboard operation
psst copied to clipboard

Windows CPAL Panic

Open DusterTheFirst opened this issue 2 years ago • 2 comments

Describe the bug When attempting to play a song, a the song does not play and nothing seems to happen. Running the gui from the console, one can see a panic message as soon as the playback is requested.

Panic

thread 'cpal_wasapi_out' panicked at 'index out of bounds: the len is 1 but the index is 1', psst-core\src\audio\source.rs:70:13
stack backtrace:
   0:     0x7ff67c6ee27f - <unknown>
   1:     0x7ff67c70745a - <unknown>
   2:     0x7ff67c6e6398 - <unknown>
   3:     0x7ff67c6f0b56 - <unknown>
   4:     0x7ff67c6f0535 - <unknown>
   5:     0x7ff67c6f11b5 - <unknown>
   6:     0x7ff67c6f0d9b - <unknown>
   7:     0x7ff67c6eeba7 - <unknown>
   8:     0x7ff67c6f0cf9 - <unknown>
   9:     0x7ff67c731810 - <unknown>
  10:     0x7ff67c7317d7 - <unknown>
  11:     0x7ff67c4a11dd - <unknown>
  12:     0x7ff67c4535f0 - <unknown>
  13:     0x7ff67c5e4405 - <unknown>
  14:     0x7ff67c460adb - <unknown>
  15:     0x7ff67c49ae36 - <unknown>
  16:     0x7ff67c6f4cbc - <unknown>
  17:     0x7ffcb46e7034 - BaseThreadInitThunk
  18:     0x7ffcb4ca2651 - RtlUserThreadStart

Environment

  • OS:

    • Edition: Windows 10 Enterprise
    • Version: 21H2
    • OS build: 19044.1503
    • Experience: Windows Feature Experience Pack 120.2212.3030.0
  • Version: https://nightly.link/jpochyla/psst/actions/runs/1748008154/Psst.exe.zip

DusterTheFirst avatar Feb 09 '22 08:02 DusterTheFirst

Hi, your audio output has only one channel (mono), and Psst is doing only very rudimentary channel mapping. Either way, I doubt you actually want to listen to music on mono. Is your setup indeed limited in this way, or is the output selection logic wrong?

jpochyla avatar Mar 12 '22 22:03 jpochyla

My audio output is not mono. The output logic most probably is selecting the wrong output format.

DusterTheFirst avatar Mar 13 '22 08:03 DusterTheFirst