monitor: use dynamic types

Make the monitor item a POD object and use dynamic types.
This commit is contained in:
Wim Taymans 2017-03-23 08:54:04 +01:00
parent c44a7c9735
commit 7270986c3a
14 changed files with 360 additions and 248 deletions

View file

@ -45,6 +45,7 @@ typedef enum {
SPA_POD_TYPE_DOUBLE,
SPA_POD_TYPE_STRING,
SPA_POD_TYPE_BYTES,
SPA_POD_TYPE_POINTER,
SPA_POD_TYPE_RECTANGLE,
SPA_POD_TYPE_FRACTION,
SPA_POD_TYPE_BITMASK,
@ -94,6 +95,16 @@ typedef struct {
/* value here */
} SpaPODBytes;
typedef struct {
uint32_t type;
void *value;
} SpaPODPointerBody;
typedef struct {
SpaPOD pod;
SpaPODPointerBody body;
} SpaPODPointer;
typedef struct {
SpaPOD pod;
SpaRectangle value;