Changeset 4664:fd2cbe7b3893 in roaraudio
- Timestamp:
- 12/15/10 02:26:07 (13 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
roarclients/roarcatvio.c
r3812 r4664 47 47 int bits = ROAR_BITS_DEFAULT; 48 48 int channels = ROAR_CHANNELS_DEFAULT; 49 int codec = ROAR_CODEC_DEFAULT;49 int codec = -1; 50 50 char * server = NULL; 51 51 char * k; … … 55 55 struct roar_vio_defaults def; 56 56 int file_opened = 0; 57 const char * content_type; 57 58 58 59 if ( roar_vio_open_fh(&file, ROAR_STDIN) == -1 ) … … 90 91 return 1; 91 92 } 93 94 if ( codec == -1 ) { 95 if ( roar_vio_ctl(&file, ROAR_VIO_CTL_GET_MIMETYPE, &content_type) != -1 ) { 96 codec = roar_mime2codec(content_type); 97 } 98 } 92 99 } else { 93 100 fprintf(stderr, "Error: unknown argument: %s\n", k); … … 96 103 } 97 104 } 105 106 if ( codec == -1 ) 107 codec = ROAR_CODEC_DEFAULT; 98 108 99 109 if ( roar_vio_simple_stream(&stream, rate, channels, bits, codec, server, ROAR_DIR_PLAY, name) == -1 ) {
Note: See TracChangeset
for help on using the changeset viewer.