mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-02 09:01:50 -05:00
monitor: use dynamic types
Make the monitor item a POD object and use dynamic types.
This commit is contained in:
parent
c44a7c9735
commit
7270986c3a
14 changed files with 360 additions and 248 deletions
|
|
@ -195,6 +195,7 @@ struct pod_type_name {
|
|||
{ "float", "Float" },
|
||||
{ "double", "Double" },
|
||||
{ "string", "String" },
|
||||
{ "pointer", "Pointer" },
|
||||
{ "rectangle", "Rectangle" },
|
||||
{ "fraction", "Fraction" },
|
||||
{ "bitmask", "Bitmask" },
|
||||
|
|
@ -231,6 +232,13 @@ print_pod_value (uint32_t size, uint32_t type, void *body, int prefix)
|
|||
case SPA_POD_TYPE_STRING:
|
||||
printf ("%-*sString \"%s\"\n", prefix, "", (char *) body);
|
||||
break;
|
||||
case SPA_POD_TYPE_POINTER:
|
||||
{
|
||||
SpaPODPointerBody *b = body;
|
||||
printf ("%-*sPointer %s %p\n", prefix, "",
|
||||
spa_id_map_get_uri (spa_id_map_get_default(), b->type), b->value);
|
||||
break;
|
||||
}
|
||||
case SPA_POD_TYPE_RECTANGLE:
|
||||
{
|
||||
SpaRectangle *r = body;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue