github.com/noriah/catnip@v1.8.5/README.md (about)

     1  # catnip
     2  
     3  [![love][withlove]][noriah-dev]
     4  [![made-with-go][withgo]][go-dev]
     5  [![betamax-was-a-thing][betamax]][betawhat]
     6  
     7  > terminal audio visualizer for linux/unix/macOS/windows*
     8  
     9  <p align="center">
    10  	<a href="https://www.youtube.com/watch?v=S0LJCGOsq-4">
    11  		<img src="../media/preview0.gif" />
    12  	</a>
    13  </p>
    14  ^ click for a fun video
    15  
    16  [![A visualization of catnip over time](https://img.youtube.com/vi/sU3fkOB5HZ8/0.jpg)](https://youtu.be/sU3fkOB5HZ8)
    17  
    18  ## it supports audio backends
    19  - ALSA (linux FFmpeg)
    20  - AVFoundation (macOS FFmpeg)
    21  - DirectShow (windblows FFmpeg)
    22  - Pipewire (pw-cat)
    23  - PortAudio (linux/macOS/windblows (maybe))
    24  - PulseAudio (parec/FFmpeg)
    25  
    26  ## it depends on
    27  
    28  - go modules
    29  	- github.com/nsf/termbox-go
    30  	- github.com/integrii/flaggy
    31  	- github.com/pkg/errors
    32  	- github.com/noisetorch/pulseaudio
    33  	- gonum.org/v1/gonum
    34  
    35  - binaries
    36  	- ffmpeg (required for FFmpeg backends)
    37  	- parec (required for PulseAudio backend with parec)
    38    - pw-cat, pw-link (required for Pipewire backend)
    39  
    40  - c libraries (optional, requires CGO - `CGO_ENABLED=1`)
    41  	- fftw (fftw3) (enable with `-tags fftw`)
    42  	- portaudio (portaudio-2.0) (enable with `-tags portaudio`)
    43  
    44  ## get it
    45  
    46  ```sh
    47  # get source
    48  git clone https://github.com/noriah/catnip.git
    49  
    50  # cd to dir
    51  cd catnip
    52  
    53  # build and install catnip
    54  go install ./cmd/catnip
    55  
    56  # with portaudio
    57  go install ./cmd/catnip -tags portaudio
    58  
    59  # with fftw3
    60  go install ./cmd/catnip -tags fftw
    61  
    62  # with both portaudio and fftw3
    63  go install ./cmd/catnip -tags portaudio,fftw
    64  ```
    65  
    66  ## run it
    67  
    68  - use `catnip list-backends` to show available backends
    69  - use `catnip -b {backend} list-devices` to show available devices
    70  - use `catnip -b {backend} -d {device}` to run - use the full device name
    71  - use `catnip -h` for information on several more customizations
    72  
    73  ## question it
    74  ### catnip?
    75  [long story, short explanation][speakers]
    76  
    77  [update][speakers-2]
    78  
    79  <!-- Links -->
    80  [noriah-dev]: https://noriah.dev
    81  [go-dev]: https://go.dev
    82  [betawhat]: https://google.com/search?q=betamax
    83  [speakers]: https://github.com/noriah/catnip/commit/b1dc3840fa0ed583eba40dbaaa2c0c34c425e26e
    84  [speakers-2]: https://github.com/noriah/catnip/commit/d3c13fb16742184d7c506a567b938045f3be1c1a
    85  
    86  <!-- Images -->
    87  [withlove]: https://forthebadge.com/images/badges/built-with-love.svg
    88  [withgo]: https://forthebadge.com/images/badges/made-with-go.svg
    89  [betamax]: https://forthebadge.com/images/badges/compatibility-betamax.svg
    90  [preview-0]: https://i.imgur.com/TfMrNpe.gifv