mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-02 09:01:50 -05:00
audioconvert: set monitor port buffer size correctly
Also use quantum_limit samples on the monitor ports. Fixes #2677
This commit is contained in:
parent
900621ba9e
commit
46c8c9ec03
1 changed files with 3 additions and 3 deletions
|
|
@ -1724,20 +1724,20 @@ impl_node_port_enum_params(void *object, int seq,
|
|||
case SPA_PARAM_Buffers:
|
||||
{
|
||||
uint32_t size;
|
||||
struct dir *dir;
|
||||
|
||||
if (!port->have_format)
|
||||
return -EIO;
|
||||
if (result.index > 0)
|
||||
return 0;
|
||||
|
||||
dir = &this->dir[direction];
|
||||
if (dir->mode == SPA_PARAM_PORT_CONFIG_MODE_dsp) {
|
||||
if (PORT_IS_DSP(this, direction, port_id)) {
|
||||
/* DSP ports always use the quantum_limit as the buffer
|
||||
* size. */
|
||||
size = this->quantum_limit;
|
||||
} else {
|
||||
uint32_t irate, orate;
|
||||
struct dir *dir = &this->dir[direction];
|
||||
|
||||
/* Convert ports are scaled so that they can always
|
||||
* provide one quantum of data */
|
||||
irate = dir->format.info.raw.rate;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue