43 | | /* |
---|
44 | | * Buffer specification |
---|
45 | | */ |
---|
46 | | typedef struct _freebob_stream_spec freebob_stream_spec_t; |
---|
47 | | typedef struct _freebob_stream_info freebob_stream_info_t; |
---|
48 | | typedef struct _freebob_connection_spec freebob_connection_spec_t; |
---|
49 | | typedef struct _freebob_connection_info freebob_connection_info_t; |
---|
50 | | typedef struct _freebob_supported_stream_format_spec freebob_supported_stream_format_spec_t; |
---|
51 | | typedef struct _freebob_supported_stream_format_info freebob_supported_stream_format_info_t; |
---|
52 | | |
---|
53 | | /* |
---|
54 | | * Stream specification |
---|
55 | | */ |
---|
56 | | struct _freebob_stream_spec { |
---|
57 | | int location; |
---|
58 | | int position; |
---|
59 | | int format; |
---|
60 | | int type; |
---|
61 | | int destination_port; |
---|
62 | | char name[FREEBOB_MAX_NAME_LEN]; |
---|
63 | | }; |
---|
64 | | |
---|
65 | | struct _freebob_stream_info { |
---|
66 | | int nb_streams; |
---|
67 | | freebob_stream_spec_t** streams; |
---|
68 | | }; |
---|
69 | | |
---|
70 | | /* |
---|
71 | | * Connection specification |
---|
72 | | */ |
---|
73 | | struct _freebob_connection_spec { |
---|
74 | | int id; |
---|
75 | | int port; |
---|
76 | | int node; |
---|
77 | | int plug; |
---|
78 | | int dimension; /* due to the midi stuff, the dimension isn't equal */ |
---|
79 | | /* to the number of streams */ |
---|
80 | | int samplerate; /* this should be equal for all connections when */ |
---|
81 | | /* using jack. maybe not when using other api's */ |
---|
82 | | int iso_channel; |
---|
83 | | enum freebob_direction direction; |
---|
84 | | int is_master; |
---|
85 | | freebob_stream_info_t* stream_info; |
---|
86 | | }; |
---|
87 | | |
---|
88 | | /* |
---|
89 | | * topology info |
---|
90 | | */ |
---|
91 | | struct _freebob_connection_info { |
---|
92 | | int direction; |
---|
93 | | int nb_connections; |
---|
94 | | freebob_connection_spec_t** connections; |
---|
95 | | }; |
---|
96 | | |
---|
97 | | /* |
---|
98 | | * Supported stream formats |
---|
99 | | */ |
---|
100 | | struct _freebob_supported_stream_format_spec { |
---|
101 | | int samplerate; |
---|
102 | | int nb_audio_channels; |
---|
103 | | int nb_midi_channels; |
---|
104 | | }; |
---|
105 | | |
---|
106 | | struct _freebob_supported_stream_format_info { |
---|
107 | | int direction; |
---|
108 | | int nb_formats; |
---|
109 | | freebob_supported_stream_format_spec_t** formats; |
---|
110 | | }; |
---|
111 | | |
---|
112 | | |
---|
126 | | |
---|
127 | | freebob_connection_info_t* |
---|
128 | | freebob_get_connection_info( freebob_handle_t freebob_handle, |
---|
129 | | int node_id, |
---|
130 | | enum freebob_direction direction ); |
---|
131 | | |
---|
132 | | freebob_supported_stream_format_info_t* |
---|
133 | | freebob_get_supported_stream_format_info( freebob_handle_t freebob_handle, |
---|
134 | | int node_id, |
---|
135 | | enum freebob_direction direction ); |
---|
136 | | |
---|
137 | | void |
---|
138 | | freebob_free_connection_info( freebob_connection_info_t* connection_info ); |
---|
139 | | void |
---|
140 | | freebob_free_connection_spec( freebob_connection_spec_t* connection_spec ); |
---|
141 | | void |
---|
142 | | freebob_free_stream_info( freebob_stream_info_t* stream_info ); |
---|
143 | | void |
---|
144 | | freebob_free_stream_spec( freebob_stream_spec_t* stream_spec ); |
---|
145 | | void |
---|
146 | | freebob_free_supported_stream_format_info( freebob_supported_stream_format_info_t* stream_info ); |
---|
147 | | void |
---|
148 | | freebob_free_supported_stream_format_spec( freebob_supported_stream_format_spec_t* stream_spec ); |
---|
149 | | |
---|
150 | | |
---|
151 | | |
---|
152 | | void |
---|
153 | | freebob_print_connection_info( freebob_connection_info_t* connection_info ); |
---|
154 | | void |
---|
155 | | freebob_print_supported_stream_format_info( freebob_supported_stream_format_info_t* stream_info ); |
---|
156 | | |
---|