Changeset 4621:c20151c5eb6f in roaraudio
- Timestamp:
- 11/23/10 15:34:24 (13 years ago)
- Branch:
- default
- Phase:
- public
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
include/libroar/stream.h
r4583 r4621 55 55 }; 56 56 57 int roar_stream_connect (struct roar_connection * con, struct roar_stream * s, int dir); 57 int roar_stream_connect (struct roar_connection * con, struct roar_stream * s, int dir); 58 int roar_stream_connect2 (struct roar_connection * con, struct roar_stream * s, int dir, int mixer); 58 59 59 60 int roar_stream_new (struct roar_stream * s, unsigned int rate, unsigned int channels, unsigned int bits, unsigned int codec); -
libroar/stream.c
r4583 r4621 36 36 #include "libroar.h" 37 37 38 int roar_stream_connect (struct roar_connection * con, struct roar_stream * s, int dir) { 38 int roar_stream_connect (struct roar_connection * con, struct roar_stream * s, int dir) { 39 return roar_stream_connect2(con, s, dir, -1); 40 } 41 42 int roar_stream_connect2 (struct roar_connection * con, struct roar_stream * s, int dir, int mixer) { 39 43 struct roar_libroar_config * config = roar_libroar_get_config(); 40 44 struct roar_stream ms; … … 47 51 48 52 m.cmd = ROAR_CMD_NEW_STREAM; 49 m.stream = -1;53 m.stream = mixer; 50 54 m.pos = 0; 51 55 -
roard/req.c
r4614 r4621 137 137 int req_on_new_stream (int client, struct roar_message * mes, char ** data, uint32_t flags[2]) { 138 138 int stream; 139 struct roar_stream * s; 139 struct roar_stream_server * ss; 140 struct roar_stream * s; 140 141 struct roar_stream * source_stream; 141 142 struct roar_audio_info * info; … … 149 150 150 151 ROAR_DBG("req_on_new_stream(client=%i, ...): getting stream...", client); 151 if ( streams_get _clientobj(stream, &s) == -1 ) {152 if ( streams_get(stream, &ss) == -1 ) { 152 153 streams_delete(stream); 153 154 return -1; 154 155 } 156 157 s = ROAR_STREAM(ss); 155 158 156 159 ROAR_DBG("req_on_new_stream(client=%i, ...): set client of stream...", client); … … 173 176 // int streams_set_dir (int id, int dir, int defaults) 174 177 if ( streams_set_dir(stream, ROAR_STREAM(s)->dir, 1) == -1 ) { 178 streams_delete(stream); 179 return -1; 180 } 181 182 if ( mes->stream != -1 && mes->stream != ss->mixer_stream ) { 175 183 streams_delete(stream); 176 184 return -1;
Note: See TracChangeset
for help on using the changeset viewer.