Skip to main content

Python bindings for cava audio visualizer

Project description

python-libcava

CAVA audio visualizer bindings for python using FIFO

python-libcava should be thread-safe. However this hasn't been thoroughly tested.

Usage

# Print the pillars for 5 seconds
from libcava import CAVA
from time import sleep

def simple_callback(sample: list[float]):
    # sample: (0.0,1.0,...)
    print(sample)

cava = CAVA(
    bars = 10, # The amount of bars ("pillars") per sample
    callback = simple_callback # Callback function that will receive samples ranging 0-1 
)

cava.start()
sleep(3)
cava.close() # Close the FIFO listener

Adding extra config to [general]

cava = CAVA(
    config="sensitivity = 0"
    # Will be added under [general]
)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

python_libcava-1.0.0.tar.gz (17.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

python_libcava-1.0.0-py3-none-any.whl (16.5 kB view details)

Uploaded Python 3

File details

Details for the file python_libcava-1.0.0.tar.gz.

File metadata

  • Download URL: python_libcava-1.0.0.tar.gz
  • Upload date:
  • Size: 17.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for python_libcava-1.0.0.tar.gz
Algorithm Hash digest
SHA256 534b65d4c2fdc0b9a826747ee333682097ca6c7b113d3f39de3730c1c983d21f
MD5 138d2cf85091a4afe247104bd5971fba
BLAKE2b-256 9fa4202677c1eaa1873f061f0989cad9695b8334f1205129f2853c6d0983ad41

See more details on using hashes here.

File details

Details for the file python_libcava-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: python_libcava-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 16.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for python_libcava-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 25747ce99b36d2913478d8012d004698f73d0ad75c34fec41f54d285ad67752d
MD5 cc9c7d70aab98e098647226016def4a2
BLAKE2b-256 4cc83c40f82d557c1777bc53762133f15a114185c6a8aef31fc441eaed766786

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page