From 016287f8f218234f94a3de6d8cec839f4bb81562 Mon Sep 17 00:00:00 2001 From: columbarius Date: Sun, 6 Dec 2020 23:54:26 +0100 Subject: [PATCH] filter: create mappable_dataTypes bitmask --- src/pipewire/filter.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/pipewire/filter.c b/src/pipewire/filter.c index 7bacc7fb4..ca5e25cdf 100644 --- a/src/pipewire/filter.c +++ b/src/pipewire/filter.c @@ -53,6 +53,8 @@ static float empty[MAX_SAMPLES]; static bool mlock_warned = false; +static uint32_t mappable_dataTypes = (1<n_datas; j++) { struct spa_data *d = &buffers[i]->datas[j]; - if (d->type == SPA_DATA_MemFd) { + if ((mappable_dataTypes & (1<type)) > 0) { if ((res = map_data(impl, d, prot)) < 0) return res; SPA_FLAG_SET(b->flags, BUFFER_FLAG_MAPPED);