25#ifndef SPA_DEBUG_FORMAT_H
26#define SPA_DEBUG_FORMAT_H
41#include <spa/param/type-info.h>
46 uint32_t type,
void *body, uint32_t size)
58 snprintf(tmp,
sizeof(tmp),
"%d", *(int32_t*)body);
121 uint32_t type,
void *body, uint32_t size)
134 const char *media_type;
135 const char *media_subtype;
137 uint32_t mtype, mstype;
158 uint32_t i,
type, size, n_vals, choice;
178 key = ti ? ti->name : NULL;
188 const char *ssep, *esep, *sep;
208 for (i = 1; i < n_vals; i++) {
static int spa_debug_format(int indent, const struct spa_type_info *info, const struct spa_pod *format)
Definition: debug/format.h:226
#define spa_debugn(_fmt,...)
Definition: spa/include/spa/debug/context.h:47
#define spa_debugc(_c, _fmt,...)
Definition: spa/include/spa/debug/context.h:57
static const struct spa_type_info * spa_debug_type_find(const struct spa_type_info *info, uint32_t type)
Definition: types.h:46
static int spa_debugc_format(struct spa_debug_context *ctx, int indent, const struct spa_type_info *info, const struct spa_pod *format)
Definition: debug/format.h:136
static const char * spa_debug_type_find_name(const struct spa_type_info *info, uint32_t type)
Definition: types.h:73
static const char * spa_debug_type_short_name(const char *name)
Definition: types.h:65
static const char * spa_debug_type_find_short_name(const struct spa_type_info *info, uint32_t type)
Definition: types.h:80
static int spa_debug_format_value(const struct spa_type_info *info, uint32_t type, void *body, uint32_t size)
Definition: debug/format.h:125
static int spa_debug_strbuf_format_value(struct spa_strbuf *buffer, const struct spa_type_info *info, uint32_t type, void *body, uint32_t size)
Definition: debug/format.h:50
static const struct spa_type_info spa_type_media_subtype[]
Definition: format-types.h:74
static int spa_format_parse(const struct spa_pod *format, uint32_t *media_type, uint32_t *media_subtype)
Definition: format-utils.h:47
static const struct spa_type_info spa_type_format[]
Definition: format-types.h:148
static const struct spa_type_info spa_type_media_type[]
Definition: format-types.h:58
@ SPA_FORMAT_mediaType
media type (Id enum spa_media_type)
Definition: param/format.h:112
@ SPA_FORMAT_mediaSubtype
media subtype (Id enum spa_media_subtype)
Definition: param/format.h:113
#define SPA_POD_OBJECT_FOREACH(obj, iter)
Definition: iter.h:128
#define SPA_POD_BODY(pod)
Definition: pod/pod.h:59
#define SPA_POD_TYPE(pod)
Definition: pod/pod.h:48
static struct spa_pod * spa_pod_get_values(const struct spa_pod *pod, uint32_t *n_vals, uint32_t *choice)
Definition: iter.h:367
#define SPA_POD_ARRAY_BODY_FOREACH(body, _size, iter)
Definition: iter.h:99
@ SPA_CHOICE_Step
range with step: default, min, max, step
Definition: pod/pod.h:169
@ SPA_CHOICE_None
no choice, first value is current
Definition: pod/pod.h:167
@ SPA_CHOICE_Flags
flags: default, possible flags,...
Definition: pod/pod.h:171
@ SPA_CHOICE_Range
range: default, min, max
Definition: pod/pod.h:168
@ SPA_CHOICE_Enum
list: default, alternative,...
Definition: pod/pod.h:170
static int spa_strbuf_append(struct spa_strbuf *buf, const char *fmt,...)
Definition: string.h:398
static void spa_strbuf_init(struct spa_strbuf *buf, char *buffer, size_t maxsize)
Definition: string.h:390
static const struct spa_type_info spa_types[]
Definition: utils/type-info.h:62
@ SPA_TYPE_Int
Definition: spa/include/spa/utils/type.h:54
@ SPA_TYPE_Rectangle
Definition: spa/include/spa/utils/type.h:60
@ SPA_TYPE_Long
Definition: spa/include/spa/utils/type.h:55
@ SPA_TYPE_Bool
Definition: spa/include/spa/utils/type.h:52
@ SPA_TYPE_Bytes
Definition: spa/include/spa/utils/type.h:59
@ SPA_TYPE_Bitmap
Definition: spa/include/spa/utils/type.h:62
@ SPA_TYPE_Object
Definition: spa/include/spa/utils/type.h:65
@ SPA_TYPE_Float
Definition: spa/include/spa/utils/type.h:56
@ SPA_TYPE_Fraction
Definition: spa/include/spa/utils/type.h:61
@ _SPA_TYPE_LAST
not part of ABI
Definition: spa/include/spa/utils/type.h:71
@ SPA_TYPE_Double
Definition: spa/include/spa/utils/type.h:57
@ SPA_TYPE_Id
Definition: spa/include/spa/utils/type.h:53
@ SPA_TYPE_Array
Definition: spa/include/spa/utils/type.h:63
@ SPA_TYPE_String
Definition: spa/include/spa/utils/type.h:58
#define SPA_PTROFF(ptr_, offset_, type_)
Return the address (buffer + offset) as pointer of type.
Definition: defs.h:210
Definition: spa/include/spa/debug/context.h:53
uint32_t num
Definition: defs.h:140
uint32_t denom
Definition: defs.h:141
Definition: pod/pod.h:141
struct spa_pod child
Definition: pod/pod.h:142
Definition: pod/pod.h:203
Definition: pod/pod.h:228
uint32_t key
key of property, list of valid keys depends on the object type
Definition: pod/pod.h:229
struct spa_pod value
Definition: pod/pod.h:246
uint32_t type
Definition: pod/pod.h:65
uint32_t size
Definition: pod/pod.h:64
uint32_t width
Definition: defs.h:119
uint32_t height
Definition: defs.h:120
char * buffer
Definition: string.h:385
Definition: spa/include/spa/utils/type.h:162
uint32_t type
Definition: spa/include/spa/utils/type.h:163
const struct spa_type_info * values
Definition: spa/include/spa/utils/type.h:166