Linux command
pw-cat 命令
文件
复制后可按需替换文件名、目录或参数。
常用示例
Play
pw-cat -p [path/to/file.wav]
Example
pw-cat -q [8] -p [path/to/file.wav]
Record
pw-cat -r --volume [1.25] [path/to/file.wav]
Example
pw-cat -r --rate [48000] [path/to/file.wav]
Example
pw-cat -h
说明
pw-cat plays and records audio files through PipeWire. It provides a simple command-line interface for audio playback and recording similar to pacat for PulseAudio. The tool supports various audio formats and can connect to specific PipeWire nodes. It's useful for testing audio setup and simple recording tasks.
参数
- -p, --playback
- Play audio file
- -r, --record
- Record to audio file
- -q, --quality _level_
- Resampler quality (0-15, default 4)
- --volume _level_
- Volume level (1.0 = 100%)
- --rate _hz_
- Sample rate in Hz
- --channels _num_
- Number of channels
- --target _target_
- Target node to connect to
FAQ
What is the pw-cat command used for?
pw-cat plays and records audio files through PipeWire. It provides a simple command-line interface for audio playback and recording similar to pacat for PulseAudio. The tool supports various audio formats and can connect to specific PipeWire nodes. It's useful for testing audio setup and simple recording tasks.
How do I run a basic pw-cat example?
Run `pw-cat -p [path/to/file.wav]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -p, --playback do in pw-cat?
Play audio file