+ +
2da5fe7 OpenAVX v0.2.0 - High-performance open-standard IP audio and video transport suite
saifmukhtar · 2026-11-24
c · 55 lines · 1.3 KB · SPDX: MIT
main
1 /* Simple Plugin API */
2 /* SPDX-FileCopyrightText: Copyright © 2018 Wim Taymans */
3 /* SPDX-License-Identifier: MIT */
4  
5 #ifndef SPA_DEBUG_NODE_H
6 #define SPA_DEBUG_NODE_H
7  
8 #include <spa/node/node.h>
9 #include <spa/debug/context.h>
10 #include <spa/debug/dict.h>
11  
12 #ifdef __cplusplus
13 extern "C" {
14 #endif
15  
16 /**
17 * \addtogroup spa_debug
18 * \{
19 */
20  
21 #ifndef SPA_API_DEBUG_NODE
22 #ifdef SPA_API_IMPL
23 #define SPA_API_DEBUG_NODE SPA_API_IMPL
24 #else
25 #define SPA_API_DEBUG_NODE static inline
26 #endif
27 #endif
28  
29 SPA_API_DEBUG_NODE int spa_debugc_port_info(struct spa_debug_context *ctx, int indent, const struct spa_port_info *info)
30 {
31 spa_debugc(ctx, "%*s" "struct spa_port_info %p:", indent, "", info);
32 spa_debugc(ctx, "%*s" " flags: \t%08" PRIx64, indent, "", info->flags);
33 spa_debugc(ctx, "%*s" " rate: \t%d/%d", indent, "", info->rate.num, info->rate.denom);
34 spa_debugc(ctx, "%*s" " props:", indent, "");
35 if (info->props)
36 spa_debugc_dict(ctx, indent + 2, info->props);
37 else
38 spa_debugc(ctx, "%*s" " none", indent, "");
39 return 0;
40 }
41  
42 SPA_API_DEBUG_NODE int spa_debug_port_info(int indent, const struct spa_port_info *info)
43 {
44 return spa_debugc_port_info(NULL, indent, info);
45 }
46 /**
47 * \}
48 */
49  
50  
51 #ifdef __cplusplus
52 } /* extern "C" */
53 #endif
54  
55 #endif /* SPA_DEBUG_NODE_H */