mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-01 22:58:50 -04:00
mixer: increase mixer ports from 128 to 512
Don't allocate the mixer arrays on the stack but include in the implementation structure.
This commit is contained in:
parent
b9cf2638b3
commit
8cfa5ccd79
3 changed files with 20 additions and 11 deletions
|
|
@ -29,7 +29,7 @@ static struct spa_log_topic *log_topic = &SPA_LOG_TOPIC(0, "spa.audiomixer");
|
|||
#define DEFAULT_CHANNELS 2
|
||||
|
||||
#define MAX_BUFFERS 64
|
||||
#define MAX_PORTS 128
|
||||
#define MAX_PORTS 512
|
||||
#define MAX_CHANNELS 64
|
||||
#define MAX_ALIGN MIX_OPS_MAX_ALIGN
|
||||
|
||||
|
|
@ -103,6 +103,9 @@ struct impl {
|
|||
struct port *in_ports[MAX_PORTS];
|
||||
struct port out_ports[1];
|
||||
|
||||
struct buffer *mix_buffers[MAX_PORTS];
|
||||
const void *mix_datas[MAX_PORTS];
|
||||
|
||||
int n_formats;
|
||||
struct spa_audio_info format;
|
||||
|
||||
|
|
@ -737,9 +740,9 @@ static int impl_node_process(void *object)
|
|||
outio->buffer_id = SPA_ID_INVALID;
|
||||
}
|
||||
|
||||
buffers = alloca(MAX_PORTS * sizeof(struct buffer *));
|
||||
datas = alloca(MAX_PORTS * sizeof(void *));
|
||||
n_buffers = 0;
|
||||
buffers = this->mix_buffers;
|
||||
datas = this->mix_datas;
|
||||
n_buffers = 0;
|
||||
|
||||
maxsize = UINT32_MAX;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue