PipeWire  0.3.65
format-types.h
Go to the documentation of this file.
1 /* Simple Plugin API
2  *
3  * Copyright © 2018 Wim Taymans
4  *
5  * Permission is hereby granted, free of charge, to any person obtaining a
6  * copy of this software and associated documentation files (the "Software"),
7  * to deal in the Software without restriction, including without limitation
8  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
9  * and/or sell copies of the Software, and to permit persons to whom the
10  * Software is furnished to do so, subject to the following conditions:
11  *
12  * The above copyright notice and this permission notice (including the next
13  * paragraph) shall be included in all copies or substantial portions of the
14  * Software.
15  *
16  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
19  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
21  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
22  * DEALINGS IN THE SOFTWARE.
23  */
24 
25 #ifndef SPA_PARAM_FORMAT_TYPES_H
26 #define SPA_PARAM_FORMAT_TYPES_H
27 
28 #ifdef __cplusplus
29 extern "C" {
30 #endif
31 
37 #include <spa/param/format.h>
38 #include <spa/param/param-types.h>
39 
40 #include <spa/param/audio/type-info.h>
41 #include <spa/param/video/type-info.h>
42 
43 #define SPA_TYPE_INFO_Format SPA_TYPE_INFO_PARAM_BASE "Format"
44 #define SPA_TYPE_INFO_FORMAT_BASE SPA_TYPE_INFO_Format ":"
45 
46 #define SPA_TYPE_INFO_MediaType SPA_TYPE_INFO_ENUM_BASE "MediaType"
47 #define SPA_TYPE_INFO_MEDIA_TYPE_BASE SPA_TYPE_INFO_MediaType ":"
48 
49 static const struct spa_type_info spa_type_media_type[] = {
57  { 0, 0, NULL, NULL },
58 };
59 
60 #define SPA_TYPE_INFO_MediaSubtype SPA_TYPE_INFO_ENUM_BASE "MediaSubtype"
61 #define SPA_TYPE_INFO_MEDIA_SUBTYPE_BASE SPA_TYPE_INFO_MediaSubtype ":"
62 
63 static const struct spa_type_info spa_type_media_subtype[] = {
65  /* generic subtypes */
70  /* audio subtypes */
86  /* video subtypes */
100  /* image subtypes */
102  /* stream subtypes */
104  /* application subtypes */
106  { 0, 0, NULL, NULL },
107 };
108 
109 #define SPA_TYPE_INFO_FormatAudio SPA_TYPE_INFO_FORMAT_BASE "Audio"
110 #define SPA_TYPE_INFO_FORMAT_AUDIO_BASE SPA_TYPE_INFO_FormatAudio ":"
111 
112 #define SPA_TYPE_INFO_FORMAT_AUDIO_AAC SPA_TYPE_INFO_FORMAT_AUDIO_BASE "AAC"
113 #define SPA_TYPE_INFO_FORMAT_AUDIO_AAC_BASE SPA_TYPE_INFO_FORMAT_AUDIO_AAC ":"
114 #define SPA_TYPE_INFO_FORMAT_AUDIO_WMA SPA_TYPE_INFO_FORMAT_AUDIO_BASE "WMA"
115 #define SPA_TYPE_INFO_FORMAT_AUDIO_WMA_BASE SPA_TYPE_INFO_FORMAT_AUDIO_WMA ":"
116 #define SPA_TYPE_INFO_FORMAT_AUDIO_AMR SPA_TYPE_INFO_FORMAT_AUDIO_BASE "AMR"
117 #define SPA_TYPE_INFO_FORMAT_AUDIO_AMR_BASE SPA_TYPE_INFO_FORMAT_AUDIO_AMR ":"
118 
119 #define SPA_TYPE_INFO_FormatVideo SPA_TYPE_INFO_FORMAT_BASE "Video"
120 #define SPA_TYPE_INFO_FORMAT_VIDEO_BASE SPA_TYPE_INFO_FormatVideo ":"
122 #define SPA_TYPE_INFO_FORMAT_VIDEO_H264 SPA_TYPE_INFO_FORMAT_VIDEO_BASE "H264"
123 #define SPA_TYPE_INFO_FORMAT_VIDEO_H264_BASE SPA_TYPE_INFO_FORMAT_VIDEO_H264 ":"
124 
125 static const struct spa_type_info spa_type_format[] = {
127 
143  spa_type_audio_iec958_codec },
150 
152  spa_type_audio_aac_stream_format },
154  spa_type_audio_wma_profile },
156  spa_type_audio_amr_band_mode },
157 
177 
180  { 0, 0, NULL, NULL },
181 };
182 
187 #ifdef __cplusplus
188 } /* extern "C" */
189 #endif
190 
191 #endif /* SPA_PARAM_FORMAT_TYPES_H */
Definition: param/format.h:89
Interleave bytes (Int)
Definition: param/format.h:126
Definition: param/format.h:65
static const struct spa_type_info spa_type_audio_format[]
Definition: audio/raw-types.h:50
(Id enum spa_video_multiview_flags)
Definition: param/format.h:149
static const struct spa_type_info spa_type_audio_flags[]
Definition: audio/raw-types.h:163
Definition: param/format.h:59
Definition: param/format.h:96
Definition: param/format.h:84
Definition: param/format.h:110
bit rate (Int)
Definition: param/format.h:127
since 0.3.65
Definition: param/format.h:78
media type (Id enum spa_media_type)
Definition: param/format.h:112
/Id enum spa_video_color_matrix)
Definition: param/format.h:152
S/PDIF.
Definition: param/format.h:61
Definition: param/format.h:46
#define SPA_TYPE_INFO_FORMAT_AUDIO_WMA_BASE
Definition: format-types.h:132
/Id enum spa_video_color_range)
Definition: param/format.h:151
codec used (IEC958) (Id enum spa_audio_iec958_codec)
Definition: param/format.h:123
Definition: param/format.h:81
/Id enum spa_video_transfer_function)
Definition: param/format.h:153
Definition: param/format.h:70
optional flags (Int)
Definition: param/format.h:118
size (Rectangle)
Definition: param/format.h:142
Definition: param/format.h:71
static const struct spa_type_info spa_type_param_bitorder[]
Definition: param-types.h:101
Definition: param/format.h:92
Definition: spa/include/spa/utils/type.h:54
#define SPA_TYPE_INFO_FORMAT_AUDIO_BASE
Definition: format-types.h:123
#define SPA_TYPE_INFO_FORMAT_VIDEO_BASE
Definition: format-types.h:141
bit order (Id enum spa_param_bitorder)
Definition: param/format.h:125
(Int)
Definition: param/format.h:156
#define SPA_TYPE_INFO_FORMAT_BASE
Definition: format-types.h:51
Definition: param/format.h:60
Definition: spa/include/spa/utils/type.h:61
static const struct spa_type_info spa_type_media_type[]
Definition: format-types.h:58
Definition: param/format.h:85
#define SPA_TYPE_INFO_MEDIA_SUBTYPE_BASE
Definition: format-types.h:72
AAC stream format, (Id enum spa_audio_aac_stream_format)
Definition: param/format.h:130
Definition: spa/include/spa/utils/type.h:162
(Id enum spa_video_interlace_mode)
Definition: param/format.h:146
spa/param/param-types.h
static const struct spa_type_info spa_type_prop_channel_map[]
Definition: param-types.h:86
Definition: param/format.h:48
static const struct spa_type_info spa_type_video_format[]
Definition: video/raw-types.h:49
media subtype (Id enum spa_media_subtype)
Definition: param/format.h:113
Definition: param/format.h:64
number of views (Int)
Definition: param/format.h:145
Definition: param/format.h:47
frame rate (Fraction)
Definition: param/format.h:143
static const struct spa_type_info spa_type_format[]
Definition: format-types.h:148
Definition: param/format.h:52
Definition: param/format.h:66
Definition: param/format.h:51
static const struct spa_type_info spa_type_video_interlace_mode[]
Definition: video/raw-types.h:159
format modifier (Long) use only with DMA-BUF and omit for other buffer types
Definition: param/format.h:140
Definition: param/format.h:57
(Int)
Definition: param/format.h:155
AMR band mode (Id enum spa_audio_amr_band_mode)
Definition: param/format.h:134
Definition: param/format.h:74
Definition: param/format.h:50
#define SPA_TYPE_INFO_MEDIA_TYPE_BASE
Definition: format-types.h:56
Definition: param/format.h:67
Definition: param/format.h:88
video format (Id enum spa_video_format)
Definition: param/format.h:139
Definition: param/format.h:101
channel positions (Id enum spa_audio_position)
Definition: param/format.h:121
Definition: param/format.h:75
Definition: param/format.h:86
audio data block alignment (Int)
Definition: param/format.h:128
#define SPA_TYPE_INFO_FORMAT_AUDIO_AMR_BASE
Definition: format-types.h:136
sample rate (Int)
Definition: param/format.h:119
number of audio channels (Int)
Definition: param/format.h:120
(Id enum spa_h264_alignment)
Definition: param/format.h:158
static const struct spa_type_info spa_type_param[]
Definition: param-types.h:52
static const struct spa_type_info spa_type_media_subtype[]
Definition: format-types.h:74
Definition: spa/include/spa/utils/type.h:55
audio format, (Id enum spa_audio_format)
Definition: param/format.h:117
since 0.3.65
Definition: param/format.h:77
Definition: param/format.h:68
Definition: param/format.h:91
(Rectangle)
Definition: param/format.h:147
Definition: param/format.h:82
(Id enum spa_video_multiview_mode)
Definition: param/format.h:148
#define SPA_TYPE_INFO_FORMAT_AUDIO_AAC_BASE
Definition: format-types.h:128
WMA profile (Id enum spa_audio_wma_profile)
Definition: param/format.h:132
Definition: param/format.h:76
(Id enum spa_h264_stream_format)
Definition: param/format.h:157
Definition: param/format.h:49
spa/param/format.h
maximum frame rate (Fraction)
Definition: param/format.h:144
/Id enum spa_video_chroma_site)
Definition: param/format.h:150
/Id enum spa_video_color_primaries)
Definition: param/format.h:154
Definition: param/format.h:83
control stream, data contains spa_pod_sequence with control info.
Definition: param/format.h:104
Definition: param/format.h:87
Definition: param/format.h:58
Definition: param/format.h:73
Definition: spa/include/spa/utils/type.h:63
Definition: param/format.h:93
Definition: spa/include/spa/utils/type.h:60
Definition: param/format.h:69
#define SPA_TYPE_INFO_FORMAT_VIDEO_H264_BASE
Definition: format-types.h:146
Definition: spa/include/spa/utils/type.h:53
Definition: param/format.h:90
Definition: param/format.h:72