mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
pulse-server: use channelmap
Convert to an from pulse enum to id in the message layer so that we can always just deal with native spa types. Use the channelmap in stream-restore Parse the channelmap from properties.
This commit is contained in:
parent
2b95afeddc
commit
f95f278067
5 changed files with 108 additions and 49 deletions
|
|
@ -35,6 +35,7 @@ struct volume {
|
|||
|
||||
struct volume_info {
|
||||
struct volume volume;
|
||||
struct channel_map map;
|
||||
bool mute;
|
||||
float level;
|
||||
float base;
|
||||
|
|
@ -87,6 +88,10 @@ static int volume_parse_param(const struct spa_pod *param, struct volume_info *i
|
|||
info->steps = 0x10000u * step;
|
||||
break;
|
||||
}
|
||||
case SPA_PROP_channelMap:
|
||||
info->map.channels = spa_pod_copy_array(&prop->value, SPA_TYPE_Id,
|
||||
info->map.map, SPA_AUDIO_MAX_CHANNELS);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue