GithubHelp home page GithubHelp logo

Comments (7)

second2050 avatar second2050 commented on June 3, 2024 1

I just did a system update, pipewire-pulse in particular got an update, and it's working again as it should.
My guess is that this was a bug introduced by Pipewire and not Panon, therefore I will close this issues for the time being.

from panon.

rbn42 avatar rbn42 commented on June 3, 2024

How did you know it only uses the default audio device? Is it shown in pgrep -af panon

from panon.

second2050 avatar second2050 commented on June 3, 2024

Okay my bad, I said default audio device because it seemed like it only used the default.

Output of pgrep if set to:
"Monitor of Current device":

14936 python3 -m panon.backend.client ws://127.0.0.1:34729 --backend=soundcard --device-index=smart --fps=75 --reduce-bass --bass-resolution-level=4 --enable-spectrum-data

"Monitor of EMU20K2 [SoundBlaster X-Fi Titanium Series]…":

15515 python3 -m panon.backend.client ws://127.0.0.1:34729 --backend=soundcard --device-index=alsa_output.pci-0000_05_00.0.analog-stereo.monitor --fps=75 --reduce-bass --bass-resolution-level=4 --enable-spectrum-data

"Monitor of Family 17h (Models 00h-0fh) HD Audio Controller…":

15606 python3 -m panon.backend.client ws://127.0.0.1:34729 --backend=soundcard --device-index=alsa_output.pci-0000_0b_00.3.analog-stereo.monitor --fps=75 --reduce-bass --bass-resolution-level=4 --enable-spectrum-data

In all cases it shows the input of my microphone instead of the what's playing on these devices though.

from panon.

rbn42 avatar rbn42 commented on June 3, 2024

Please install python-soundcard, and try this standalone python script. I want to know could this script record audio data from your other devices, or only from your microphone.

import soundcard as sc
_id="alsa_output.pci-0000_0b_00.3.analog-stereo.monitor"
mic=sc.get_microphone(_id)
stream = mic.recorder(44100,2,44100)
stream.__enter__()
while True:
  data=stream.record(44100)
  if sum(data)==0:
    print('muted',sum(data))
  else:
    print('activated',sum(data))

from panon.

second2050 avatar second2050 commented on June 3, 2024

Output of the script:

Traceback (most recent call last):
  File "/home/second2050/rbn42-test.py", line 3, in <module>
    mic=sc.get_microphone(_id)
  File "/usr/lib/python3.9/site-packages/soundcard/pulseaudio.py", line 317, in get_microphone
    return _Microphone(id=_match_soundcard(id, microphones, include_loopback)['id'])
  File "/usr/lib/python3.9/site-packages/soundcard/pulseaudio.py", line 345, in _match_soundcard
    raise IndexError('no soundcard with id {}'.format(id))
IndexError: no soundcard with id alsa_output.pci-0000_0b_00.3.analog-stereo.monitor

from panon.

rbn42 avatar rbn42 commented on June 3, 2024

Oh, sorry, I made a mistake at line 3. please try this script again

import soundcard as sc
_id="alsa_output.pci-0000_0b_00.3.analog-stereo.monitor"
mic=sc.get_microphone(_id,exclude_monitors=False)
stream = mic.recorder(44100,2,44100)
stream.__enter__()
while True:
  data=stream.record(44100)
  if sum(data)==0:
    print('muted',sum(data))
  else:
    print('activated',sum(data))

from panon.

second2050 avatar second2050 commented on June 3, 2024

Output of the new script was:

Traceback (most recent call last):
  File "/home/second2050/rbn42-test.py", line 8, in <module>
    if sum(data)==0:
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()

from panon.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.